@@ -27,12 +27,12 @@
|
||||
|
||||
@Override
|
||||
@@ -83,7 +93,7 @@
|
||||
public void b(WorldServer worldserver) {
|
||||
public void c(WorldServer worldserver) {
|
||||
BehaviorController<EntityVillager> behaviorcontroller = this.getBehaviorController();
|
||||
|
||||
- behaviorcontroller.b(worldserver, (EntityLiving) this);
|
||||
+ behaviorcontroller.b(worldserver, this); // CraftBukkit - decompile error
|
||||
this.bn = behaviorcontroller.h();
|
||||
this.bg = behaviorcontroller.h();
|
||||
this.a(this.getBehaviorController());
|
||||
}
|
||||
@@ -133,7 +143,7 @@
|
||||
@@ -42,10 +42,10 @@
|
||||
- this.getBehaviorController().a((WorldServer) this.world, (EntityLiving) this);
|
||||
+ this.getBehaviorController().a((WorldServer) this.world, this); // CraftBukkit - decompile error
|
||||
this.world.getMethodProfiler().exit();
|
||||
if (this.bM) {
|
||||
this.bM = false;
|
||||
if (this.bF) {
|
||||
this.bF = false;
|
||||
@@ -147,7 +157,7 @@
|
||||
this.bB = false;
|
||||
this.bu = false;
|
||||
}
|
||||
|
||||
- this.addEffect(new MobEffect(MobEffects.REGENERATION, 200, 0));
|
||||
@@ -78,53 +78,44 @@
|
||||
Logger logger = EntityVillager.LOGGER;
|
||||
|
||||
logger.getClass();
|
||||
@@ -695,7 +712,12 @@
|
||||
@@ -700,7 +717,12 @@
|
||||
}
|
||||
|
||||
entitywitch.setPersistent();
|
||||
- this.world.addEntity(entitywitch);
|
||||
- worldserver.addAllEntities(entitywitch);
|
||||
+ // CraftBukkit start
|
||||
+ if (CraftEventFactory.callEntityTransformEvent(this, entitywitch, EntityTransformEvent.TransformReason.LIGHTNING).isCancelled()) {
|
||||
+ return;
|
||||
+ }
|
||||
+ this.world.addEntity(entitywitch, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.LIGHTNING);
|
||||
+ worldserver.addAllEntities(entitywitch, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.LIGHTNING);
|
||||
+ // CraftBukkit end
|
||||
this.fq();
|
||||
this.die();
|
||||
} else {
|
||||
super.onLightningStrike(entitylightning);
|
||||
@@ -812,7 +834,7 @@
|
||||
}
|
||||
|
||||
private void b(long i) {
|
||||
- this.bn.setMemory(MemoryModuleType.GOLEM_LAST_SEEN_TIME, (Object) i);
|
||||
+ this.bn.setMemory(MemoryModuleType.GOLEM_LAST_SEEN_TIME, i); // CraftBukkit - decompile error
|
||||
}
|
||||
|
||||
private boolean c(long i) {
|
||||
@@ -845,7 +867,7 @@
|
||||
@@ -833,7 +855,7 @@
|
||||
|
||||
if (entityirongolem != null) {
|
||||
if (entityirongolem.a((GeneratorAccess) this.world, EnumMobSpawn.MOB_SUMMONED) && entityirongolem.a((IWorldReader) this.world)) {
|
||||
- this.world.addEntity(entityirongolem);
|
||||
+ this.world.addEntity(entityirongolem, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.VILLAGE_DEFENSE); // CraftBukkit
|
||||
if (entityirongolem.a((GeneratorAccess) worldserver, EnumMobSpawn.MOB_SUMMONED) && entityirongolem.a((IWorldReader) worldserver)) {
|
||||
- worldserver.addAllEntities(entityirongolem);
|
||||
+ worldserver.addAllEntities(entityirongolem, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.VILLAGE_DEFENSE); // CraftBukkit
|
||||
return entityirongolem;
|
||||
}
|
||||
|
||||
@@ -923,7 +945,7 @@
|
||||
@@ -911,7 +933,7 @@
|
||||
@Override
|
||||
public void entitySleep(BlockPosition blockposition) {
|
||||
super.entitySleep(blockposition);
|
||||
- this.bn.setMemory(MemoryModuleType.LAST_SLEPT, (Object) this.world.getTime());
|
||||
+ this.bn.setMemory(MemoryModuleType.LAST_SLEPT, this.world.getTime()); // CraftBukkit - decompile error
|
||||
this.bn.removeMemory(MemoryModuleType.WALK_TARGET);
|
||||
this.bn.removeMemory(MemoryModuleType.CANT_REACH_WALK_TARGET_SINCE);
|
||||
- this.bg.setMemory(MemoryModuleType.LAST_SLEPT, (Object) this.world.getTime());
|
||||
+ this.bg.setMemory(MemoryModuleType.LAST_SLEPT, this.world.getTime()); // CraftBukkit - decompile error
|
||||
this.bg.removeMemory(MemoryModuleType.WALK_TARGET);
|
||||
this.bg.removeMemory(MemoryModuleType.CANT_REACH_WALK_TARGET_SINCE);
|
||||
}
|
||||
@@ -931,7 +953,7 @@
|
||||
@@ -919,7 +941,7 @@
|
||||
@Override
|
||||
public void entityWakeup() {
|
||||
super.entityWakeup();
|
||||
- this.bn.setMemory(MemoryModuleType.LAST_WOKEN, (Object) this.world.getTime());
|
||||
+ this.bn.setMemory(MemoryModuleType.LAST_WOKEN, this.world.getTime()); // CraftBukkit - decompile error
|
||||
- this.bg.setMemory(MemoryModuleType.LAST_WOKEN, (Object) this.world.getTime());
|
||||
+ this.bg.setMemory(MemoryModuleType.LAST_WOKEN, this.world.getTime()); // CraftBukkit - decompile error
|
||||
}
|
||||
|
||||
private boolean d(long i) {
|
||||
private boolean b(long i) {
|
||||
|
||||
Reference in New Issue
Block a user