diff --git a/src/main/java/net/minecraft/server/ConsoleLogManager.java b/src/main/java/net/minecraft/server/ConsoleLogManager.java index 806df662f1..6a03e90a20 100644 --- a/src/main/java/net/minecraft/server/ConsoleLogManager.java +++ b/src/main/java/net/minecraft/server/ConsoleLogManager.java @@ -43,7 +43,7 @@ public class ConsoleLogManager { int count = ((Integer)server.options.valueOf("log-count")).intValue(); boolean append = ((Boolean)server.options.valueOf("log-append")).booleanValue(); FileHandler filehandler = new FileHandler(pattern, limit, count, append); - // CraftBukkit start + // CraftBukkit end filehandler.setFormatter(consolelogformatter); a.addHandler(filehandler); diff --git a/src/main/java/net/minecraft/server/EntityFireball.java b/src/main/java/net/minecraft/server/EntityFireball.java index 667bf22173..3e44ace490 100644 --- a/src/main/java/net/minecraft/server/EntityFireball.java +++ b/src/main/java/net/minecraft/server/EntityFireball.java @@ -46,7 +46,7 @@ public class EntityFireball extends Entity { this.setPosition(this.locX, this.locY, this.locZ); this.height = 0.0F; this.motX = this.motY = this.motZ = 0.0D; - // CraftBukkit start (added setDirection method) + // CraftBukkit start - (added setDirection method) this.setDirection(d0, d1, d2); } @@ -60,6 +60,7 @@ public class EntityFireball extends Entity { this.dirY = d1 / d3 * 0.1D; this.dirZ = d2 / d3 * 0.1D; } + // CraftBukkit end public void w_() { super.w_(); diff --git a/src/main/java/net/minecraft/server/EntityMinecart.java b/src/main/java/net/minecraft/server/EntityMinecart.java index 951b972d05..98f7dae84a 100644 --- a/src/main/java/net/minecraft/server/EntityMinecart.java +++ b/src/main/java/net/minecraft/server/EntityMinecart.java @@ -513,7 +513,7 @@ public class EntityMinecart extends Entity implements IInventory { this.motX *= this.derailedX; this.motY *= this.derailedY; this.motZ *= this.derailedZ; - // CraftBukkit start + // CraftBukkit end } this.move(this.motX, this.motY, this.motZ); @@ -522,7 +522,7 @@ public class EntityMinecart extends Entity implements IInventory { this.motX *= this.flyingX; this.motY *= this.flyingY; this.motZ *= this.flyingZ; - // CraftBukkit start + // CraftBukkit end } } diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java index 94d2facf80..e01b529c97 100644 --- a/src/main/java/net/minecraft/server/EntityPlayer.java +++ b/src/main/java/net/minecraft/server/EntityPlayer.java @@ -173,7 +173,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting { this.b.serverConfigurationManager.sendAll(new Packet3Chat(event.getDeathMessage())); } - // CraftBukkit - we clean the player's inventory after the EntityDeathEvent is called so plugins can get the exact state of the inventory. + // CraftBukkit start - we clean the player's inventory after the EntityDeathEvent is called so plugins can get the exact state of the inventory. for (int i = 0; i < this.inventory.items.length; ++i) { this.inventory.items[i] = null; } diff --git a/src/main/java/net/minecraft/server/EntityWolf.java b/src/main/java/net/minecraft/server/EntityWolf.java index c0ead7dd13..ad91308cc8 100644 --- a/src/main/java/net/minecraft/server/EntityWolf.java +++ b/src/main/java/net/minecraft/server/EntityWolf.java @@ -364,7 +364,7 @@ public class EntityWolf extends EntityAnimal { } if (!this.world.isStatic) { - // CraftBukkit - added event call and isCancelled check. + // CraftBukkit start - added event call and isCancelled check. if (this.random.nextInt(3) == 0 && !CraftEventFactory.callEntityTameEvent(this, entityhuman).isCancelled()) { // CraftBukkit end this.setTamed(true); diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java index fe59b98896..1209c884bc 100644 --- a/src/main/java/net/minecraft/server/ItemStack.java +++ b/src/main/java/net/minecraft/server/ItemStack.java @@ -39,7 +39,7 @@ public final class ItemStack { this.setData(k); // CraftBukkit } - // CraftBukkit - used to create a new ItemStack, specifying the enchantments at time of creation. + // CraftBukkit start - used to create a new ItemStack, specifying the enchantments at time of creation. public ItemStack(int id, int count, int data, NBTTagList enchantments) { this(id, count, data); // taken from .addEnchantment diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java index e37b56dec3..a2831995a2 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -206,7 +206,6 @@ public class MinecraftServer implements Runnable, ICommandListener, IMinecraftSe j = WorldSettings.a(j); log.info("Default game type: " + j); - // CraftBukkit start (+ removed worldsettings and servernbtmanager) int worldCount = 3; @@ -223,13 +222,12 @@ public class MinecraftServer implements Runnable, ICommandListener, IMinecraftSe } if (k == 2) { - // CraftBukkit start (+ don't do this in server.properties, do it in bukkit.yml) + // CraftBukkit - (+ don't do this in server.properties, do it in bukkit.yml) if (this.server.getAllowEnd()) { dimension = 1; } else { continue; } - // CraftBukkit end } String worldType = Environment.getEnvironment(dimension).toString().toLowerCase(); diff --git a/src/main/java/net/minecraft/server/ServerConfigurationManager.java b/src/main/java/net/minecraft/server/ServerConfigurationManager.java index 0213adc89c..0673c19b9f 100644 --- a/src/main/java/net/minecraft/server/ServerConfigurationManager.java +++ b/src/main/java/net/minecraft/server/ServerConfigurationManager.java @@ -111,7 +111,7 @@ public class ServerConfigurationManager { } public void c(EntityPlayer entityplayer) { - // CraftBukkit + // CraftBukkit start cserver.detectListNameConflict(entityplayer); this.sendAll(new Packet201PlayerInfo(entityplayer.listName, true, 1000)); // CraftBukkit end @@ -223,6 +223,7 @@ public class ServerConfigurationManager { } public EntityPlayer moveToWorld(EntityPlayer entityplayer, int i, boolean flag, Location location) { + // CraftBukkit end this.server.getTracker(entityplayer.dimension).untrackPlayer(entityplayer); // this.server.getTracker(entityplayer.dimension).untrackEntity(entityplayer); // CraftBukkit this.getPlayerManager(entityplayer.dimension).removePlayer(entityplayer); diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java index f45457ada1..e3f1573ab7 100644 --- a/src/main/java/net/minecraft/server/World.java +++ b/src/main/java/net/minecraft/server/World.java @@ -2421,11 +2421,9 @@ public class World implements IBlockAccess { Entity entity = null; for (int i = 0; i < list.size(); ++i) { entity = (Entity) list.get(i); - // CraftBukkit start - fixed an NPE if (entity == null) { continue; } - // CraftBukkit end this.entityList.add(entity); // CraftBukkit end this.c((Entity) list.get(i));