Class EntityHolderEventSystem<ECS_TYPE, EventType extends EcsEvent>

java.lang.Object
com.hypixel.hytale.component.system.EventSystem<EventType>
com.hypixel.hytale.component.system.EntityHolderEventSystem<ECS_TYPE, EventType>
Type Parameters:
ECS_TYPE - the type of the ECS store
EventType - the type of event this system handles
All Implemented Interfaces:
ISystem<ECS_TYPE>, QuerySystem<ECS_TYPE>
Direct Known Subclasses:
InventorySystems.ActiveSlotChangedEntityHolderEventSystem, InventorySystems.ActiveSlotChangedToolsHolderEventSystem, ItemContainerSystems.OnCarriedHolder, ItemContainerSystems.OnReplacedHolder

public abstract class EntityHolderEventSystem<ECS_TYPE, EventType extends EcsEvent> extends EventSystem<EventType> implements QuerySystem<ECS_TYPE>
A system that processes events of a specific type for entity chunks.
  • Method Details

    • handle

      public abstract void handle(@Nonnull Holder<ECS_TYPE> holder, @Nonnull Store<ECS_TYPE> store, @Nonnull CommandBuffer<ECS_TYPE> commandBuffer, @Nonnull EventType event)
      An overrideable method called to handle an event for a specific holder.
      Parameters:
      holder - The holder containing the entity being processed
      store - The ECS store.
      commandBuffer - The command buffer for queuing ECS commands.
      event - The event to be handled.
    • handleInternal

      public void handleInternal(@Nonnull Holder<ECS_TYPE> holder, @Nonnull Store<ECS_TYPE> store, @Nonnull CommandBuffer<ECS_TYPE> commandBuffer, @Nonnull EventType event)
      Called to handle an event for a holder, unless the event is cancelled.
      Parameters:
      holder - The holder containing the entity being processed
      store - The ECS store.
      commandBuffer - The command buffer for queuing ECS commands.
      event - The event to be handled.