diff --git a/SpigotCore_Main/src/de/steamwar/entity/REntity.java b/SpigotCore_Main/src/de/steamwar/entity/REntity.java index 94c5a90..ddf4f35 100644 --- a/SpigotCore_Main/src/de/steamwar/entity/REntity.java +++ b/SpigotCore_Main/src/de/steamwar/entity/REntity.java @@ -85,6 +85,8 @@ public class REntity { this.itemSlots = entityType == EntityType.PLAYER ? new HashMap<>() : null; + this.noGravity = false; + server.addEntity(this); } @@ -190,7 +192,8 @@ public class REntity { public void setNoGravity(boolean noGravity) { this.noGravity = noGravity; - server.updateEntity(this,getDataWatcherPacket(noGravityDataWatcher,getEntityStatus())); + if(Core.getVersion() > 8) + server.updateEntity(this,getDataWatcherPacket(noGravityDataWatcher,noGravity)); } private static int spawnPacketOffset() { @@ -240,7 +243,7 @@ public class REntity { } if(noGravity) - packetSink.accept(getDataWatcherPacket(noGravityDataWatcher,getEntityStatus())); + packetSink.accept(getDataWatcherPacket(noGravityDataWatcher,this.noGravity)); } void tick() {