Contents
Class EntityTrackerSystems.Visible
java.lang.Object
com.hypixel.hytale.server.core.modules.entity.tracker.EntityTrackerSystems.Visible
- All Implemented Interfaces:
Component<EntityStore>, Cloneable
- Enclosing class:
EntityTrackerSystems
This component tracks what
EntityTrackerSystems.EntityViewer's can currently see this entity.-
Field Summary
FieldsModifier and TypeFieldDescriptionTheEntityTrackerSystems.EntityViewer's this entity is newly visible to.TheEntityTrackerSystems.EntityViewer's this entity was visible to last tick.TheEntityTrackerSystems.EntityViewer's this entity is visible to.Fields inherited from interface Component
EMPTY_ARRAY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddViewerParallel(Ref<EntityStore> ref, EntityTrackerSystems.EntityViewer entityViewerComponent) This method is specially implemented to allow addingEntityTrackerSystems.EntityViewer's from parallel tasks.clone()Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Component
cloneSerializable
-
Field Details
-
previousVisibleTo
TheEntityTrackerSystems.EntityViewer's this entity was visible to last tick. -
visibleTo
TheEntityTrackerSystems.EntityViewer's this entity is visible to. -
newlyVisibleTo
TheEntityTrackerSystems.EntityViewer's this entity is newly visible to.
-
-
Constructor Details
-
Visible
public Visible()
-
-
Method Details
-
getComponentType
- Returns:
- the component type for the
EntityTrackerSystems.Visiblecomponent.
-
clone
- Specified by:
clonein interfaceComponent<EntityStore>- Returns:
- a clone instance of the original component instance.
-
addViewerParallel
public void addViewerParallel(@Nonnull Ref<EntityStore> ref, @Nonnull EntityTrackerSystems.EntityViewer entityViewerComponent) This method is specially implemented to allow addingEntityTrackerSystems.EntityViewer's from parallel tasks.We do it this way so that we don't need to incur the cost of concurrent data structures or locks when the data is used read-only, which is safe to do across threads.
- Parameters:
ref- The ref for the viewer.entityViewerComponent- The entity viewer component.
-