Class EntityEvent.CanUpdate

  • Enclosing class:
    EntityEvent

    public static class EntityEvent.CanUpdate
    extends EntityEvent
    CanUpdate is fired when an Entity is being created.
    This event is fired whenever vanilla Minecraft determines that an entity
    cannot update in World#updateEntityWithOptionalForce(net.minecraft.entity.Entity, boolean)

    canUpdate contains the boolean value of whether this entity can update.
    If the modder decides that this Entity can be updated, they may change canUpdate to true,
    and the entity with then be updated.

    This event is not Cancelable.

    This event is fired on the MinecraftForge.EVENT_BUS.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private boolean canUpdate  
    • Constructor Summary

      Constructors 
      Constructor Description
      CanUpdate​(Entity entity)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean getCanUpdate()  
      void setCanUpdate​(boolean canUpdate)  
      • Methods inherited from class net.minecraftforge.eventbus.api.Event

        getListenerList, getParentListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult, setup
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • canUpdate

        private boolean canUpdate
    • Constructor Detail

      • CanUpdate

        public CanUpdate​(Entity entity)
    • Method Detail

      • getCanUpdate

        public boolean getCanUpdate()
      • setCanUpdate

        public void setCanUpdate​(boolean canUpdate)