InteractionSystems

public class InteractionSystems

Class InteractionSystems. Provides interactionsystems functionality for the Hytale server.

java.lang.Object > InteractionSystems

Field Summary

ref

final Ref ref

Field ref.

interactionManager

final InteractionManager interactionManager

Field interactionManager.

playerRef

final PlayerRef playerRef

Field playerRef.

syncPackets

final ObjectList syncPackets

Field syncPackets.

playerComponent

final Player playerComponent

Field playerComponent.

playerRefComponent

final PlayerRef playerRefComponent

Field playerRefComponent.

visibleComponentType

final EntityTrackerSystems.Visible visibleComponentType

Field visibleComponentType.

interactionsComponent

final Interactions interactionsComponent

Field interactionsComponent.

componentUpdate

final ComponentUpdate componentUpdate

Field componentUpdate.

interactions

final Object2IntOpenHashMap interactions

Field interactions.

visible

final EntityTrackerSystems.Visible visible

Field visible.

Method Detail

TickInteractionManagerSystem

public public TickInteractionManagerSystem ()

Method TickInteractionManagerSystem.

getQuery

public Query getQuery ()

Method getQuery.

tick

public void tick (final float dt, final int index, @Nonnull final ArchetypeChunk archetypeChunk, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method tick.

Parameters:
final float dt
final int index
@Nonnull final ArchetypeChunk archetypeChunk
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer

SyncInteractionChains

public new SyncInteractionChains (syncPackets.toArray(SyncInteractionChain[]::new)

Method SyncInteractionChains.

Parameters:
syncPackets.toArray(SyncInteractionChain[]::new syncPackets.toArray(SyncInteractionChain[]::new

getGroup

public SystemGroup getGroup ()

Method getGroup.

PlayerAddManagerSystem

public public PlayerAddManagerSystem ()

Method PlayerAddManagerSystem.

onEntityAdd

public void onEntityAdd (@Nonnull final Holder holder, @Nonnull final AddReason reason, @Nonnull final Store store)

Method onEntityAdd.

Parameters:
@Nonnull final Holder holder
@Nonnull final AddReason reason
@Nonnull final Store store

InteractionManager

public new InteractionManager (playerComponent, playerRefComponent, new InteractionSimulationHandler()

Method InteractionManager.

Parameters:
playerComponent playerComponent
playerRefComponent playerRefComponent
new InteractionSimulationHandler(

onEntityRemoved

public void onEntityRemoved (@Nonnull final Holder holder, @Nonnull final RemoveReason reason, @Nonnull final Store store)

Method onEntityRemoved.

Parameters:
@Nonnull final Holder holder
@Nonnull final RemoveReason reason
@Nonnull final Store store

CleanUpSystem

public public CleanUpSystem ()

Method CleanUpSystem.

onEntityAdded

public void onEntityAdded (@Nonnull final Ref ref, @Nonnull final AddReason reason, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method onEntityAdded.

Parameters:
@Nonnull final Ref ref
@Nonnull final AddReason reason
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer

onEntityRemove

public void onEntityRemove (@Nonnull final Ref ref, @Nonnull final RemoveReason reason, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method onEntityRemove.

Parameters:
@Nonnull final Ref ref
@Nonnull final RemoveReason reason
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer

TrackerTickSystem

public public TrackerTickSystem ()

Method TrackerTickSystem.

isParallel

public boolean isParallel (final int archetypeChunkSize, final int taskCount)

Method isParallel.

Parameters:
final int archetypeChunkSize
final int taskCount

if

public else if (!visibleComponentType.newlyVisibleTo.isEmpty()

Method if.

Parameters:
!visibleComponentType.newlyVisibleTo.isEmpty( !visibleComponentType.newlyVisibleTo.isEmpty(

queueUpdatesFor

static void queueUpdatesFor (@Nonnull final Ref ref, @Nonnull final Map, EntityTrackerSystems.EntityViewer> visibleTo, @Nonnull final Interactions component)

Method queueUpdatesFor.

Parameters:
@Nonnull final Ref ref
@Nonnull final Map, EntityTrackerSystems.EntityViewer> visibleTo
@Nonnull final Interactions component

EntityTrackerRemove

public public EntityTrackerRemove (final ComponentType visibleComponentType)

Method EntityTrackerRemove.

Parameters:
final ComponentType visibleComponentType

componentType

public Interactions> componentType ()

Method componentType.

onComponentAdded

public void onComponentAdded (@Nonnull final Ref ref, @Nonnull final Interactions component, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method onComponentAdded.

Parameters:
@Nonnull final Ref ref
@Nonnull final Interactions component
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer

onComponentSet

public void onComponentSet (@Nonnull final Ref ref, final Interactions oldComponent, @Nonnull final Interactions newComponent, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method onComponentSet.

Parameters:
@Nonnull final Ref ref
final Interactions oldComponent
@Nonnull final Interactions newComponent
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer

onComponentRemoved

public void onComponentRemoved (@Nonnull final Ref ref, @Nonnull final Interactions component, @Nonnull final Store store, @Nonnull final CommandBuffer commandBuffer)

Method onComponentRemoved.

Parameters:
@Nonnull final Ref ref
@Nonnull final Interactions component
@Nonnull final Store store
@Nonnull final CommandBuffer commandBuffer