Class LivingSpawnEvent
- java.lang.Object
-
- net.minecraftforge.eventbus.api.Event
-
- net.minecraftforge.event.entity.EntityEvent
-
- net.minecraftforge.event.entity.living.LivingEvent
-
- net.minecraftforge.event.entity.living.LivingSpawnEvent
-
- Direct Known Subclasses:
LivingSpawnEvent.AllowDespawn,LivingSpawnEvent.CheckSpawn,LivingSpawnEvent.SpecialSpawn
public class LivingSpawnEvent extends LivingEvent
LivingSpawnEvent is fired for any events associated with Living Entities spawn status.
If a method utilizes thisEventas its parameter, the method will receive every child event of this class.
worldcontains the world in which this living Entity is being spawned.
xcontains the x-coordinate this entity is being spawned at.
ycontains the y-coordinate this entity is being spawned at.
zcontains the z-coordinate this entity is being spawned at.
All children of this event are fired on theMinecraftForge.EVENT_BUS.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classLivingSpawnEvent.AllowDespawnFired each tick for despawnable mobs to allow control over despawning.static classLivingSpawnEvent.CheckSpawnFires before mob spawn events.static classLivingSpawnEvent.SpecialSpawnSpecialSpawn is fired when an Entity is to be spawned.
This allows you to do special inializers in the new entity.
This event is fired via theForgeEventFactory#doSpecialSpawn(EntityLiving, World, float, float, float).
This event isCancelable.
If this event is canceled, the Entity is not spawned.
This event does not have a result.-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.living.LivingEvent
LivingEvent.LivingJumpEvent, LivingEvent.LivingUpdateEvent, LivingEvent.LivingVisibilityEvent
-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.EntityEvent
EntityEvent.CanUpdate, EntityEvent.EnteringChunk, EntityEvent.EntityConstructing, EntityEvent.Size
-
-
Constructor Summary
Constructors Constructor Description LivingSpawnEvent(MobEntity entity, IWorld world, double x, double y, double z)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IWorldgetWorld()doublegetX()doublegetY()doublegetZ()-
Methods inherited from class net.minecraftforge.event.entity.living.LivingEvent
getEntityLiving
-
Methods inherited from class net.minecraftforge.event.entity.EntityEvent
getEntity
-
-