Options
All
  • Public
  • Public/Protected
  • All
Menu

This is the purely id-based kernel of state management / indexing

Hierarchy

  • EntityComponentDb

Index

Constructors

constructor

Properties

Private classRegistry

classRegistry: any

Private componentTypeIdToComponents

componentTypeIdToComponents: any

Private componentTypes

componentTypes: any

Private deletedTagTypeInfo

deletedTagTypeInfo: any

Private entityIdGenerator

entityIdGenerator: any

Private entityIdToComponents

entityIdToComponents: any

Methods

createEntity

  • Returns EntityId

deleteComponent

  • Marks a component as deleted, the component is still in the db until it is "released"

    Parameters

    Returns void

deleteEntity

  • deleteEntity(entityId: EntityId): void
  • Marks an entity and all its components as deleted, they are still in the db until they are "released"

    Parameters

    Returns void

getAllComponents

  • Returns Iterable<GenericComponent>

getAllComponentsOfEntity

  • Parameters

    Returns Iterable<GenericComponent>

getAllComponentsOfType

getAllEntities

  • Returns Iterable<EntityId>

getComponent

getNumComponentsOfType

  • getNumComponentsOfType(componentTypeId: ShortTypeId): number
  • Parameters

    Returns number

hasComponent

  • Parameters

    Returns boolean

hasEntity

  • hasEntity(entityId: EntityId): boolean
  • Parameters

    Returns boolean

releaseComponent

  • Release is "final" and releases references, whereas deletion is just a marker.

    Parameters

    Returns void

releaseDeletedState

  • releaseDeletedState(): void
  • Returns void

releaseEntity

  • releaseEntity(entityId: EntityId): void
  • Release is "final" and releases references, whereas deletion is just a marker. Releases the entity and all of its components

    Parameters

    • entityId: EntityId

      The entity to release

    Returns void

serialize

  • Parameters

    Returns void

setComponent

Generated using TypeDoc