Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EntityComponentStateDeletionHidingFacade

Wraps an EntityComponentStateImpl and filters out all the deleted entities and components making it appear that they do not exist

Hierarchy

  • EntityComponentStateDeletionHidingFacade

Implements

Index

Constructors

constructor

Properties

Private state

state: any

Methods

createEntity

deleteComponent

  • deleteComponent<T>(componentType: new () => T, ownerId: EntityId): void

deleteEntity

  • deleteEntity(entityId: EntityId): void

getAspect

  • getAspect<T, U>(componentTypeT: new () => T, componentTypeU: new () => U): Iterable<[Component<T>, Component<U>]>
  • getAspect<T, U, V>(componentTypeT: new () => T, componentTypeU: new () => U, componentTypeV: new () => V): Iterable<[Component<T>, Component<U>, Component<V>]>

getComponent

  • getComponent<T>(componentType: new () => T, ownerId: EntityId): undefined | Component<T>
  • Returns a Component of the supplied type if the given entity owns one

    Type parameters

    Parameters

    • componentType: new () => T
        • new (): T
        • Returns T

    • ownerId: EntityId

    Returns undefined | Component<T>

getComponents

  • getComponents<T>(componentType: new () => T): Iterable<Component<T>>

getEntity

getEntityComponentDb

releaseDeletedState

  • releaseDeletedState(): void

serialize

setComponent

  • Sets the component data of the given owner. If entity already has component of this type, it overwrites existing component If entity does not exist, it will return undefined.

    Type parameters

    Parameters

    Returns undefined | Component<T>

withDeletedStateHidden

Generated using TypeDoc