Contents
Class EntityEventView
java.lang.Object
com.hypixel.hytale.server.npc.blackboard.view.event.EventView<EntityEventView, EntityEventType, EntityEventNotification>
com.hypixel.hytale.server.npc.blackboard.view.event.entity.EntityEventView
- All Implemented Interfaces:
IBlackboardView<EntityEventView>
public class EntityEventView
extends EventView<EntityEventView, EntityEventType, EntityEventNotification>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetUpdatedView(Ref<EntityStore> ref, ComponentAccessor<EntityStore> componentAccessor) Returns the updated view if the current is outdatedvoidinitialiseEntity(Ref<EntityStore> ref, BlackboardSubscription subscription) Initializes the given entity with any data relevant to the view.voidonEntityUseEntity(Ref<EntityStore> ref, UseEntityEvent.Post event) Called by the blackboard resource when an entity uses another entity.voidprocessAttackedEvent(Ref<EntityStore> targetRef, Ref<EntityStore> attackerRef, ComponentAccessor<EntityStore> componentAccessor, EntityEventType eventType) Methods inherited from class EventView
cleanup, forEach, getSetCount, isOutdated, onWorldRemoved
-
Constructor Details
-
EntityEventView
-
-
Method Details
-
getUpdatedView
public EntityEventView getUpdatedView(@Nonnull Ref<EntityStore> ref, @Nonnull ComponentAccessor<EntityStore> componentAccessor) Description copied from interface:IBlackboardViewReturns the updated view if the current is outdated- Parameters:
ref- The NPC seeking a viewcomponentAccessor- TheComponentAccessorfor component access- Returns:
- the updated view
-
initialiseEntity
public void initialiseEntity(@Nonnull Ref<EntityStore> ref, @Nonnull BlackboardSubscription subscription) Description copied from interface:IBlackboardViewInitializes the given entity with any data relevant to the view.- Parameters:
ref- The entity referencesubscription- TheBlackboardSubscriptionholding the entity's subscribed sets
-
onEntityUseEntity
Called by the blackboard resource when an entity uses another entity.- Parameters:
ref- The entity reference of the instigating entity.event- The use entity event.
-
processAttackedEvent
public void processAttackedEvent(@Nonnull Ref<EntityStore> targetRef, @Nonnull Ref<EntityStore> attackerRef, @Nonnull ComponentAccessor<EntityStore> componentAccessor, @Nonnull EntityEventType eventType)
-