Class PlayerSpatialSystem

All Implemented Interfaces:
ISystem<EntityStore>, QuerySystem<EntityStore>, TickableSystem<EntityStore>

public class PlayerSpatialSystem extends SpatialSystem<EntityStore>
A spatial system for player entities, which provides the position via the players transform component
  • Field Details

    • QUERY

      @Nonnull public static final Query<EntityStore> QUERY
      The query used by this system
  • Constructor Details

  • Method Details

    • getQuery

      public Query<EntityStore> getQuery()
    • getPosition

      @Nonnull public org.joml.Vector3d getPosition(@Nonnull ArchetypeChunk<EntityStore> archetypeChunk, int index)
      Description copied from class: SpatialSystem
      Called to fetch a position for an entity in the given archetype chunk at the specified index.
      Specified by:
      getPosition in class SpatialSystem<EntityStore>
      Parameters:
      archetypeChunk - The archetype chunk containing the entity.
      index - The index of the entity within the archetype chunk.
      Returns:
      the position of the entity, or null if the entity does not have a position.