ActionManager

Action Manager manages all events to be triggered on a given mesh or the global scene. A single scene can have many Action Managers to handle predefined actions on specific meshes.

Hierarchy

  • ActionManager

Index

Constructors

constructor

Properties

actions

actions: Action[]

hasPickTriggers

hasPickTriggers: boolean

Does this action manager has pick triggers

returns

whether or not it has pick triggers

hasPointerTriggers

hasPointerTriggers: boolean

Does this action manager has pointer triggers

returns

whether or not it has pointer triggers

hoverCursor

hoverCursor: string

Static HasPickTriggers

HasPickTriggers: boolean

Does exist one action manager with at least one pick trigger

returns

whether or not it exists one action manager with one pick trigger

Static HasTriggers

HasTriggers: boolean

Does exist one action manager with at least one trigger

returns

whether or not it exists one action manager with one trigger

Static NothingTrigger

NothingTrigger: number

Static OnCenterPickTrigger

OnCenterPickTrigger: number

Static OnDoublePickTrigger

OnDoublePickTrigger: number

Static OnEveryFrameTrigger

OnEveryFrameTrigger: number

Static OnIntersectionEnterTrigger

OnIntersectionEnterTrigger: number

Static OnIntersectionExitTrigger

OnIntersectionExitTrigger: number

Static OnKeyDownTrigger

OnKeyDownTrigger: number

Static OnKeyUpTrigger

OnKeyUpTrigger: number

Static OnLeftPickTrigger

OnLeftPickTrigger: number

Static OnLongPressTrigger

OnLongPressTrigger: number

Static OnPickDownTrigger

OnPickDownTrigger: number

Static OnPickOutTrigger

OnPickOutTrigger: number

Static OnPickTrigger

OnPickTrigger: number

Static OnPickUpTrigger

OnPickUpTrigger: number

Static OnPointerOutTrigger

OnPointerOutTrigger: number

Static OnPointerOverTrigger

OnPointerOverTrigger: number

Static OnRightPickTrigger

OnRightPickTrigger: number

Static Triggers

Triggers: object

Type declaration

  • [key: string]: number

Methods

dispose

  • dispose(): void
  • Returns void

getScene

hasSpecificTrigger

  • hasSpecificTrigger(trigger: number, parameterPredicate?: function): boolean
  • Does this action manager handles actions of a given trigger

    Parameters

    • trigger: number

      defines the trigger to be tested

    • Optional parameterPredicate: function

      defines an optional predicate to filter triggers by parameter

        • (parameter: any): boolean
        • Parameters

          • parameter: any

          Returns boolean

    Returns boolean

    whether the trigger is handled

hasSpecificTriggers

  • hasSpecificTriggers(triggers: number[]): boolean
  • Does this action manager handles actions of any of the given triggers

    Parameters

    • triggers: number[]

      the triggers to be tested

    Returns boolean

    whether one (or more) of the triggers is handeled

processTrigger

  • processTrigger(trigger: number, evt?: ActionEvent): void
  • Process a specific trigger

    Parameters

    • trigger: number

      the trigger to process

    • Optional evt: ActionEvent

      the event details to be processed

    Returns void

registerAction

  • Registers an action to this action manager

    Parameters

    • action: Action

      the action to be registered

    Returns Nullable<Action>

    the action amended (prepared) after registration

serialize

  • serialize(name: string): any
  • Parameters

    • name: string

    Returns any

unregisterAction

  • unregisterAction(action: Action): Boolean
  • Unregisters an action to this action manager

    Parameters

    • action: Action

      The action to be unregistered

    Returns Boolean

    whether the action has been unregistered

Static GetTriggerName

  • GetTriggerName(trigger: number): string
  • Parameters

    • trigger: number

    Returns string

Static HasSpecificTrigger

  • HasSpecificTrigger(trigger: number): boolean
  • Does exist one action manager that handles actions of a given trigger

    Parameters

    • trigger: number

      the trigger to be tested

    Returns boolean

    whether the trigger is handeled by at least one action manager

Static Parse

Generated using TypeDoc