Expose the Entity Counter to allow plugins to use valid and non-conflicting Entity Ids
This commit is contained in:
@@ -168,5 +168,12 @@ public interface UnsafeValues {
|
||||
byte[] serializeItem(ItemStack item);
|
||||
|
||||
ItemStack deserializeItem(byte[] data);
|
||||
|
||||
/**
|
||||
* Creates and returns the next EntityId available.
|
||||
* <p>
|
||||
* Use this when sending custom packets, so that there are no collisions on the client or server.
|
||||
*/
|
||||
public int nextEntityId();
|
||||
// Paper end
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user