Interface that describes a custom camera strategy for tracking targets

Type Parameters

  • T

Hierarchy

  • CameraStrategy

Implemented by

Properties

Properties

action: ((target: T, camera: Camera, engine: Engine, delta: number) => Vector)

Type declaration

    • (target: T, camera: Camera, engine: Engine, delta: number): Vector
    • Camera strategies perform an action to calculate a new focus returned out of the strategy

      Parameters

      • target: T

        The target object to apply this camera strategy (if any)

      • camera: Camera

        The current camera implementation in excalibur running the game

      • engine: Engine

        The current engine running the game

      • delta: number

        The elapsed time in milliseconds since the last frame

      Returns Vector

target: T

Target of the camera strategy that will be passed to the action