mirror of
https://github.com/PaperMC/Paper.git
synced 2026-11-25 10:29:41 -05:00
Massive renaming update in nms. If you bypassed Bukkit, you will likely break.
Also minimized all the nms diffs and generic cleanups all around.
This commit is contained in:
1 parent
9e5dba8306
commit
a98c7ba2c7
126 files changed
+1329
-1772
No files matched your search
@@ -1,10 +1,8 @@
|
||||
package net.minecraft.server;
|
||||
|
||||
// CraftBukkit start
|
||||
import org.bukkit.craftbukkit.CraftServer;
|
||||
import org.bukkit.craftbukkit.entity.CraftEntity;
|
||||
import org.bukkit.event.entity.EntityTargetEvent;
|
||||
import org.bukkit.event.entity.EntityTargetEvent.TargetReason;
|
||||
// CraftBukkit end
|
||||
|
||||
public class EntitySpider extends EntityMonster {
|
||||
@@ -30,7 +28,7 @@ public class EntitySpider extends EntityMonster {
|
||||
if (f < 0.5F) {
|
||||
double d0 = 16.0D;
|
||||
|
||||
return this.world.a(this, d0);
|
||||
return this.world.findNearbyPlayer(this, d0);
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
@@ -53,9 +51,8 @@ public class EntitySpider extends EntityMonster {
|
||||
|
||||
if (f1 > 0.5F && this.random.nextInt(100) == 0) {
|
||||
// CraftBukkit start
|
||||
CraftServer server = ((WorldServer) this.world).getServer();
|
||||
EntityTargetEvent event = new EntityTargetEvent(this.getBukkitEntity(), null, TargetReason.FORGOT_TARGET);
|
||||
server.getPluginManager().callEvent(event);
|
||||
EntityTargetEvent event = new EntityTargetEvent(this.getBukkitEntity(), null, EntityTargetEvent.TargetReason.FORGOT_TARGET);
|
||||
this.world.getServer().getPluginManager().callEvent(event);
|
||||
|
||||
if (!event.isCancelled()) {
|
||||
if (event.getTarget() == null) {
|
||||
|
||||
Reference in new issue
Block a user