Package net.minecraftforge.event.entity
Class EntityTravelToDimensionEvent
- java.lang.Object
-
- net.minecraftforge.eventbus.api.Event
-
- net.minecraftforge.event.entity.EntityEvent
-
- net.minecraftforge.event.entity.EntityTravelToDimensionEvent
-
public class EntityTravelToDimensionEvent extends EntityEvent
EntityTravelToDimensionEvent is fired before an Entity travels to a dimension.
dimension
contains the id of the dimension the entity is traveling to.
This event isCancelable
.
If this event is canceled, the Entity does not travel to the dimension.
This event does not have a result.Event.HasResult
This event is fired on theMinecraftForge.EVENT_BUS
.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.EntityEvent
EntityEvent.CanUpdate, EntityEvent.EnteringChunk, EntityEvent.EntityConstructing, EntityEvent.Size
-
-
Field Summary
Fields Modifier and Type Field Description private RegistryKey<World>
dimension
-
Constructor Summary
Constructors Constructor Description EntityTravelToDimensionEvent(Entity entity, RegistryKey<World> dimension)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RegistryKey<World>
getDimension()
-
Methods inherited from class net.minecraftforge.event.entity.EntityEvent
getEntity
-
-
-
-
Field Detail
-
dimension
private final RegistryKey<World> dimension
-
-
Constructor Detail
-
EntityTravelToDimensionEvent
public EntityTravelToDimensionEvent(Entity entity, RegistryKey<World> dimension)
-
-
Method Detail
-
getDimension
public RegistryKey<World> getDimension()
-
-