3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-11-16 04:50:05 +01:00

CraftBukkit comment fixes

Dieser Commit ist enthalten in:
Wesley Wolfe 2012-09-14 00:03:47 -05:00 committet von EvilSeph
Ursprung 4b1f6aff3f
Commit cebc8cffec
10 geänderte Dateien mit 16 neuen und 20 gelöschten Zeilen

Datei anzeigen

@ -3,10 +3,7 @@ package net.minecraft.server;
import java.util.List;
import java.util.Random;
// CraftBukkit start
import org.bukkit.event.block.BlockRedstoneEvent;
import org.bukkit.event.entity.EntityInteractEvent;
// CraftBukkit end
import org.bukkit.event.entity.EntityInteractEvent; // CraftBukkit
public class BlockTripwire extends Block {

Datei anzeigen

@ -165,7 +165,7 @@ public class ChunkSection {
this.b = cntb;
this.c = cntc;
}
private void old_e() {
// CraftBukkit end
this.b = 0;

Datei anzeigen

@ -4,7 +4,6 @@ package net.minecraft.server;
import org.bukkit.entity.Ageable;
import org.bukkit.entity.EntityType;
import org.bukkit.entity.Player;
import org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason;
import org.bukkit.event.player.PlayerEggThrowEvent;
// CraftBukkit end
@ -49,7 +48,7 @@ public class EntityEgg extends EntityProjectile {
if (hatching) {
for (int k = 0; k < numHatching; k++) {
org.bukkit.entity.Entity entity = world.getWorld().spawn(new org.bukkit.Location(world.getWorld(), this.locX, this.locY, this.locZ, this.yaw, 0.0F), hatchingType.getEntityClass(), SpawnReason.EGG);
org.bukkit.entity.Entity entity = world.getWorld().spawn(new org.bukkit.Location(world.getWorld(), this.locX, this.locY, this.locZ, this.yaw, 0.0F), hatchingType.getEntityClass(), org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.EGG);
if (entity instanceof Ageable) {
((Ageable) entity).setBaby();
}

Datei anzeigen

@ -2,7 +2,6 @@ package net.minecraft.server;
// CraftBukkit start
import org.bukkit.Bukkit;
import org.bukkit.craftbukkit.entity.CraftPlayer;
import org.bukkit.event.entity.EntityDamageByEntityEvent;
import org.bukkit.event.player.PlayerTeleportEvent;
// CraftBukkit end
@ -32,7 +31,7 @@ public class EntityEnderPearl extends EntityProjectile {
if (!entityplayer.netServerHandler.disconnected && entityplayer.world == this.world) {
// CraftBukkit start
CraftPlayer player = entityplayer.getBukkitEntity();
org.bukkit.craftbukkit.entity.CraftPlayer player = entityplayer.getBukkitEntity();
org.bukkit.Location location = getBukkitEntity().getLocation();
location.setPitch(player.getLocation().getPitch());
location.setYaw(player.getLocation().getYaw());

Datei anzeigen

@ -1,5 +1,7 @@
package net.minecraft.server;
import org.bukkit.craftbukkit.event.CraftEventFactory; // CraftBukkit
public class EntityPig extends EntityAnimal {
public EntityPig(World world) {
@ -82,7 +84,7 @@ public class EntityPig extends EntityAnimal {
}
}
org.bukkit.craftbukkit.event.CraftEventFactory.callEntityDeathEvent(this, loot);
CraftEventFactory.callEntityDeathEvent(this, loot);
// CraftBukkit end
}
@ -103,7 +105,7 @@ public class EntityPig extends EntityAnimal {
EntityPigZombie entitypigzombie = new EntityPigZombie(this.world);
// CraftBukkit start
if (org.bukkit.craftbukkit.event.CraftEventFactory.callPigZapEvent(this, entitylightning, entitypigzombie).isCancelled()) {
if (CraftEventFactory.callPigZapEvent(this, entitylightning, entitypigzombie).isCancelled()) {
return;
}
// CraftBukkit end

Datei anzeigen

@ -170,7 +170,7 @@ public abstract class MinecraftServer implements Runnable, IMojangStatistics, IC
world = new DemoWorldServer(this, new ServerNBTManager(server.getWorldContainer(), s1, true), s1, dimension, this.methodProfiler);
} else {
// CraftBukkit
world = new WorldServer(this, new ServerNBTManager(server.getWorldContainer(), s1, true), s1, dimension, worldsettings, this.methodProfiler, org.bukkit.World.Environment.getEnvironment(dimension), gen);
world = new WorldServer(this, new ServerNBTManager(server.getWorldContainer(), s1, true), s1, dimension, worldsettings, this.methodProfiler, Environment.getEnvironment(dimension), gen);
}
} else {
String dim = "DIM" + dimension;
@ -204,7 +204,7 @@ public abstract class MinecraftServer implements Runnable, IMojangStatistics, IC
this.c(name);
// CraftBukkit
world = new SecondaryWorldServer(this, new ServerNBTManager(server.getWorldContainer(), name, true), name, dimension, worldsettings, this.worlds.get(0), this.methodProfiler, org.bukkit.World.Environment.getEnvironment(dimension), gen);
world = new SecondaryWorldServer(this, new ServerNBTManager(server.getWorldContainer(), name, true), name, dimension, worldsettings, this.worlds.get(0), this.methodProfiler, Environment.getEnvironment(dimension), gen);
}
if (gen != null) {

Datei anzeigen

@ -847,7 +847,7 @@ public class NetServerHandler extends NetHandler {
((EntityPlayer) recipient).sendMessage(s);
}
} else {
for (org.bukkit.entity.Player recipient : event.getRecipients()) {
for (Player recipient : event.getRecipients()) {
recipient.sendMessage(s);
}
}

Datei anzeigen

@ -23,10 +23,11 @@ public abstract class Packet {
public boolean lowPriority = false;
// CraftBukkit start - calculate packet ID once - used a bunch of times
private int packetID;
public Packet() {
packetID = ((Integer) a.get(this.getClass())).intValue();
} // CraftBukkit end
}
// CraftBukkit end
static void a(int i, boolean flag, boolean flag1, Class oclass) {
if (l.b(i)) {

Datei anzeigen

@ -2,8 +2,6 @@ package net.minecraft.server;
import java.util.Iterator;
import org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason; // CraftBukkit
public class TileEntityMobSpawner extends TileEntity {
public int spawnDelay = -1;
@ -71,7 +69,7 @@ public class TileEntityMobSpawner extends TileEntity {
entity.setPositionRotation(d3, d4, d5, this.world.random.nextFloat() * 360.0F, 0.0F);
if (entityliving == null || entityliving.canSpawn()) {
this.a(entity);
this.world.addEntity(entity, SpawnReason.SPAWNER); // CraftBukkit
this.world.addEntity(entity, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.SPAWNER); // CraftBukkit
this.world.triggerEffect(2004, this.x, this.y, this.z, 0);
if (entityliving != null) {
entityliving.aK();

Datei anzeigen

@ -51,7 +51,7 @@ public class Vec3DPool {
++this.d;
return vec3d;
}
// CraftBukkit start - offer back vector (can save LOTS of unneeded bloat) - works about 90% of the time
public void release(Vec3D v) {
if (this.alloclist == v) {