public final class ServerEntityWorldChangeEvents extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
ServerEntityWorldChangeEvents.AfterEntityChange |
static interface |
ServerEntityWorldChangeEvents.AfterPlayerChange |
Modifier and Type | Field and Description |
---|---|
static Event<ServerEntityWorldChangeEvents.AfterEntityChange> |
AFTER_ENTITY_CHANGE_WORLD
An event which is called after an entity has been moved to a different world.
|
static Event<ServerEntityWorldChangeEvents.AfterPlayerChange> |
AFTER_PLAYER_CHANGE_WORLD
An event which is called after a player has been moved to a different world.
|
public static final Event<ServerEntityWorldChangeEvents.AfterEntityChange> AFTER_ENTITY_CHANGE_WORLD
All entities are copied to the destination and the old entity removed.
This event does not apply to the ServerPlayerEntity
since players are physically moved to the new world instead of being copied over.
A mod may use this event for reference cleanup if it is tracking an entity's current world.
AFTER_PLAYER_CHANGE_WORLD
public static final Event<ServerEntityWorldChangeEvents.AfterPlayerChange> AFTER_PLAYER_CHANGE_WORLD
This is similar to AFTER_ENTITY_CHANGE_WORLD
but is only called for players.
This is because the player is physically moved to the new world instead of being recreated at the destination.
AFTER_ENTITY_CHANGE_WORLD