Skip to main content

excalibur

Index

Classes

Enumerations

Functions

Interfaces

Namespaces

References

Type Aliases

Variables

References

ActionCompleteEvent

ActionStartEvent

Re-exports ActionStartEvent

ActivateEvent

Re-exports ActivateEvent

Appender

Re-exports Appender

Axes

Re-exports Axes

Buttons

Re-exports Buttons

CapturePointerConfig

CollisionEndEvent

CollisionPostSolveEvent

CollisionPreSolveEvent

CollisionStartEvent

ConsoleAppender

Re-exports ConsoleAppender

ContactEndEvent

Re-exports ContactEndEvent

ContactStartEvent

DeactivateEvent

Re-exports DeactivateEvent

EasingFunction

Re-exports EasingFunction

EasingFunctions

Re-exports EasingFunctions

EnterTriggerEvent

EnterViewPortEvent

EventTypes

Re-exports EventTypes

ExitTriggerEvent

Re-exports ExitTriggerEvent

ExitViewPortEvent

GameEvent

Re-exports GameEvent

GameStartEvent

Re-exports GameStartEvent

GameStopEvent

Re-exports GameStopEvent

Gamepad

Re-exports Gamepad

GamepadAxisEvent

Re-exports GamepadAxisEvent

GamepadButtonEvent

GamepadConnectEvent

GamepadDisconnectEvent

Gamepads

Re-exports Gamepads

HiddenEvent

Re-exports HiddenEvent

InitializeEvent

Re-exports InitializeEvent

KeyEvent

Re-exports KeyEvent

Keyboard

Re-exports Keyboard

KeyboardInitOptions

Keys

Re-exports Keys

KillEvent

Re-exports KillEvent

LogLevel

Re-exports LogLevel

Logger

Re-exports Logger

MaybeObserver

Re-exports MaybeObserver

Message

Re-exports Message

NativeMouseEvent

Re-exports NativeMouseEvent

NativePointerButton

NativePointerEvent

NativeTouchEvent

Re-exports NativeTouchEvent

NativeWheelEvent

Re-exports NativeWheelEvent

Observable

Re-exports Observable

Observer

Re-exports Observer

PointerButton

Re-exports PointerButton

PointerComponent

Re-exports PointerComponent

PointerEvent

Re-exports PointerEvent

PointerEventReceiver

PointerInitOptions

PointerScope

Re-exports PointerScope

PointerSystem

Re-exports PointerSystem

PointerType

Re-exports PointerType

PostCollisionEvent

PostDebugDrawEvent

PostDrawEvent

Re-exports PostDrawEvent

PostFrameEvent

Re-exports PostFrameEvent

PostKillEvent

Re-exports PostKillEvent

PostTransformDrawEvent

PostUpdateEvent

Re-exports PostUpdateEvent

PreCollisionEvent

PreDebugDrawEvent

PreDrawEvent

Re-exports PreDrawEvent

PreFrameEvent

Re-exports PreFrameEvent

PreKillEvent

Re-exports PreKillEvent

PreTransformDrawEvent

PreUpdateEvent

Re-exports PreUpdateEvent

ScreenAppender

Re-exports ScreenAppender

ScreenAppenderOptions

VisibleEvent

Re-exports VisibleEvent

WheelDeltaMode

Re-exports WheelDeltaMode

WheelEvent

Re-exports WheelEvent

activate

Re-exports activate

axis

Re-exports axis

button

Re-exports button

cancel

Re-exports cancel

collisionend

Re-exports collisionend

collisionstart

Re-exports collisionstart

connect

Re-exports connect

deactivate

Re-exports deactivate

disconnect

Re-exports disconnect

down

Re-exports down

enter

Re-exports enter

entertrigger

Re-exports entertrigger

enterviewport

Re-exports enterviewport

exittrigger

Re-exports exittrigger

exitviewport

Re-exports exitviewport

hidden

Re-exports hidden

hold

Re-exports hold

initialize

Re-exports initialize

kill

Re-exports kill

leave

Re-exports leave

move

Re-exports move

pointercancel

Re-exports pointercancel

pointerdown

Re-exports pointerdown

pointerdragend

Re-exports pointerdragend

pointerdragenter

Re-exports pointerdragenter

pointerdragleave

Re-exports pointerdragleave

pointerdragmove

Re-exports pointerdragmove

pointerdragstart

Re-exports pointerdragstart

pointerenter

Re-exports pointerenter

pointerleave

Re-exports pointerleave

pointermove

Re-exports pointermove

pointerup

Re-exports pointerup

pointerwheel

Re-exports pointerwheel

postcollision

Re-exports postcollision

postdebugdraw

Re-exports postdebugdraw

postdraw

Re-exports postdraw

postframe

Re-exports postframe

postkill

Re-exports postkill

postupdate

Re-exports postupdate

precollision

Re-exports precollision

predebugdraw

Re-exports predebugdraw

predraw

Re-exports predraw

preframe

Re-exports preframe

prekill

Re-exports prekill

press

Re-exports press

preupdate

Re-exports preupdate

release

Re-exports release

start

Re-exports start

stop

Re-exports stop

subscribe

Re-exports subscribe

unsubscribe

Re-exports unsubscribe

up

Re-exports up

visible

Re-exports visible

wheel

Re-exports wheel

Type Aliases

AnimationEvents

AnimationEvents: { end: Animation; frame: FrameEvent; loop: Animation }

Type declaration

CameraEvents

CameraEvents: { initialize: InitializeEvent<Camera>; postupdate: PostUpdateEvent<Camera>; preupdate: PreUpdateEvent<Camera> }

Type declaration

ComponentCtor

ComponentCtor<TComponent>: new (...args: any[]) => TComponent

Component Constructor Types


Type parameters

Type declaration

    • new (...args: any[]): TComponent
    • Parameters

      • rest...args: any[]

      Returns TComponent

ComponentInstance

ComponentInstance<T>: T extends ComponentCtor<infer R> ? R : never

Type parameters

  • T

Constructor

Constructor<T>: new (...args: any[]) => T

Type parameters

  • T

Type declaration

    • new (...args: any[]): T
    • Parameters

      • rest...args: any[]

      Returns T

CoroutineGenerator

CoroutineGenerator: () => Generator<number | Promise<any> | undefined, void, number>

Type declaration

    • (): Generator<number | Promise<any> | undefined, void, number>
    • Returns Generator<number | Promise<any> | undefined, void, number>

DestinationSize

DestinationSize: { height: number; width: number }

Type declaration

  • height: number
  • width: number

DirectorEvents

DirectorEvents: { navigation: DirectorNavigationEvent; navigationend: DirectorNavigationEvent; navigationstart: DirectorNavigationEvent }

Type declaration

EngineEvents

EngineEvents: { fallbackgraphicscontext: ExcaliburGraphicsContext2DCanvas; hidden: HiddenEvent; initialize: InitializeEvent<Engine>; postdraw: PostDrawEvent; postframe: PostFrameEvent; postupdate: PostUpdateEvent<Engine>; predraw: PreDrawEvent; preframe: PreFrameEvent; preupdate: PreUpdateEvent<Engine>; start: GameStartEvent; stop: GameStopEvent; visible: VisibleEvent }

Type declaration

EntityEvents

EntityEvents: { initialize: InitializeEvent; kill: KillEvent; postupdate: PostUpdateEvent; preupdate: PreUpdateEvent }

Built in events supported by all entities


Type declaration

EventKey

EventKey<T>: string & keyof T

Type parameters

EventMap

EventMap: Record<string, any>

ExResponseType

ExResponseType: | arraybuffer | blob | document | json | text

HTMLImageSource

HTMLImageSource: HTMLImageElement | HTMLCanvasElement

Handler

Handler<EventType>: (event: EventType) => void

Type parameters

  • EventType

Type declaration

    • (event: EventType): void
    • Parameters

      • event: EventType

      Returns void

Id

Id<T>: { type: T; value: number }

Type parameters

  • T: string

Type declaration

  • type: T
  • value: number

LoaderConstructor

LoaderConstructor: new (...args: any[]) => DefaultLoader

Type declaration

LoaderEvents

LoaderEvents: { afterload: void; beforeload: void; loadresourceend: Loadable<any>; loadresourcestart: Loadable<any>; useraction: void }

Type declaration

  • afterload: void
  • beforeload: void
  • loadresourceend: Loadable<any>
  • loadresourcestart: Loadable<any>
  • useraction: void

MaybeKnownComponent

MaybeKnownComponent<Component, TKnownComponents>: Component extends TKnownComponents ? Component : Component | undefined

Type parameters

  • Component
  • TKnownComponents

PossibleStates

PossibleStates<TMachine>: TMachine extends StateMachineDescription ? Extract<keyof TMachine[states], string> : never

Type parameters

  • TMachine

ResourceEvents

ResourceEvents: { complete: any; error: ProgressEvent<XMLHttpRequestEventTarget>; load: ProgressEvent<XMLHttpRequestEventTarget>; loadstart: ProgressEvent<XMLHttpRequestEventTarget>; progress: ProgressEvent<XMLHttpRequestEventTarget> }

Type declaration

  • complete: any
  • error: ProgressEvent<XMLHttpRequestEventTarget>
  • load: ProgressEvent<XMLHttpRequestEventTarget>
  • loadstart: ProgressEvent<XMLHttpRequestEventTarget>
  • progress: ProgressEvent<XMLHttpRequestEventTarget>

SceneConstructor

SceneConstructor: new (...args: any[]) => Scene

Type declaration

    • new (...args: any[]): Scene
    • Parameters

      • rest...args: any[]

      Returns Scene

SceneEvents

SceneEvents: { activate: ActivateEvent; deactivate: DeactivateEvent; initialize: InitializeEvent<Scene>; postdebugdraw: PostDebugDrawEvent; postdraw: PostDrawEvent; postupdate: PostUpdateEvent; predebugdraw: PreDebugDrawEvent; predraw: PreDrawEvent; preload: PreLoadEvent; preupdate: PreUpdateEvent }

Type declaration

SceneMap

SceneMap<TKnownScenes>: Record<TKnownScenes, Scene | SceneConstructor | SceneWithOptions>

Type parameters

  • TKnownScenes: string = any

ScreenEvents

ScreenEvents: { fullscreen: FullScreenChangeEvent; pixelratio: PixelRatioChangeEvent; resize: ScreenResizeEvent }

Built in events supported by all entities


Type declaration

  • fullscreen: FullScreenChangeEvent

    Fires when the browser fullscreen api is successfully engaged or disengaged

  • pixelratio: PixelRatioChangeEvent

    Fires when the pixel ratio changes, useful to know if you've moved to a hidpi screen or back

  • resize: ScreenResizeEvent

    Fires when the screen resizes, useful if you have logic that needs to be aware of resolution/viewport constraints

ScreenUnit

ScreenUnit: pixel | percent

SoundEvents

SoundEvents: { pause: NativeSoundEvent; playbackend: NativeSoundEvent; playbackstart: NativeSoundEvent; processed: NativeSoundProcessedEvent; resume: NativeSoundEvent; stop: NativeSoundEvent; volumechange: NativeSoundEvent }

Type declaration

SourceView

SourceView: { height: number; width: number; x: number; y: number }

Type declaration

  • height: number
  • width: number
  • x: number
  • y: number

TileMapEvents

TileMapEvents: EntityEvents & { postdraw: PostDrawEvent; postupdate: PostUpdateEvent<TileMap>; predraw: PreDrawEvent; preupdate: PreUpdateEvent<TileMap> }

TriggerEvents

TriggerEvents: ActorEvents & { enter: EnterTriggerEvent; exit: ExitTriggerEvent }

UniformTypeNames

UniformTypeNames: uniform1f | uniform1i | uniform2f | uniform2i | uniform3f | uniform3i | uniform4f | uniform4i | uniform1fv | uniform1iv | uniform2fv | uniform2iv | uniform3fv | uniform3iv | uniform4fv | uniform4iv | uniformMatrix2fv | uniformMatrix3fv | uniformMatrix4fv

List of the possible glsl uniform types

WithRoot

WithRoot<TScenes>: TScenes | root

Type parameters

  • TScenes

Variables

AnimationEvents

AnimationEvents: { End: string; Frame: string; Loop: string }

Type declaration

  • End: string
  • Frame: string
  • Loop: string

CameraEvents

CameraEvents: { Initialize: string; PostUpdate: string; PreUpdate: string }

Type declaration

  • Initialize: string
  • PostUpdate: string
  • PreUpdate: string

constClosestLineJumpTable

ClosestLineJumpTable: { CircleCircleClosestLine: any; CircleEdgeClosestLine: any; EdgeEdgeClosestLine: any; PolygonCircleClosestLine: any; PolygonEdgeClosestLine: any; PolygonPolygonClosestLine: any } = ...

Type declaration

constCollisionJumpTable

CollisionJumpTable: { CollideCircleCircle: any; CollideCircleEdge: any; CollideCirclePolygon: any; CollideEdgeEdge: any; CollidePolygonEdge: any; CollidePolygonPolygon: any; FindContactSeparation: any } = ...

Type declaration

constDefaultAntialiasOptions

DefaultAntialiasOptions: Required<AntialiasOptions> = ...

constDefaultPhysicsConfig

DefaultPhysicsConfig: DeepRequired<PhysicsConfig> = ...

constDefaultPixelArtOptions

DefaultPixelArtOptions: Required<AntialiasOptions> = ...

DirectorEvents

DirectorEvents: { Navigation: string; NavigationEnd: string; NavigationStart: string }

Type declaration

  • Navigation: string
  • NavigationEnd: string
  • NavigationStart: string

constEX_VERSION

EX_VERSION: string = process.env.__EX_VERSION

The current Excalibur version string

@description

process.env.__EX_VERSION gets replaced by Webpack on build

EngineEvents

EngineEvents: { FallbackGraphicsContext: fallbackgraphicscontext; Hidden: hidden; Initialize: initialize; PostDraw: postdraw; PostFrame: postframe; PostUpdate: postupdate; PreDraw: predraw; PreFrame: preframe; PreUpdate: preupdate; Start: start; Stop: stop; Visible: visible }

Type declaration

  • readonlyFallbackGraphicsContext: fallbackgraphicscontext
  • readonlyHidden: hidden
  • readonlyInitialize: initialize
  • readonlyPostDraw: postdraw
  • readonlyPostFrame: postframe
  • readonlyPostUpdate: postupdate
  • readonlyPreDraw: predraw
  • readonlyPreFrame: preframe
  • readonlyPreUpdate: preupdate
  • readonlyStart: start
  • readonlyStop: stop
  • readonlyVisible: visible

EntityEvents

EntityEvents: { Initialize: initialize; Kill: kill; PostUpdate: postupdate; PreUpdate: preupdate }

Type declaration

  • readonlyInitialize: initialize
  • readonlyKill: kill
  • readonlyPostUpdate: postupdate
  • readonlyPreUpdate: preupdate

constHorizontalFirst

HorizontalFirst: ContactBias = ...

Horizontal First contact solve bias Used by the [[ArcadeSolver]] to sort contacts

LoaderEvents

LoaderEvents: { AfterLoad: string; BeforeLoad: string; LoadResourceEnd: string; LoadResourceStart: string; UserAction: string }

Type declaration

  • AfterLoad: string
  • BeforeLoad: string
  • LoadResourceEnd: string
  • LoadResourceStart: string
  • UserAction: string

constNone

None: ContactBias = ...

None value, [[ArcadeSolver]] sorts contacts using distance by default

ResourceEvents

ResourceEvents: { Complete: string; Error: string; Load: string; LoadStart: string; Progress: string }

Type declaration

  • Complete: string
  • Error: string
  • Load: string
  • LoadStart: string
  • Progress: string

SceneEvents

SceneEvents: { Activate: string; Deactivate: string; Initialize: string; PostDebugDraw: string; PostDraw: string; PostUpdate: string; PreDebugDraw: string; PreDraw: string; PreLoad: string; PreUpdate: string }

Type declaration

  • Activate: string
  • Deactivate: string
  • Initialize: string
  • PostDebugDraw: string
  • PostDraw: string
  • PostUpdate: string
  • PreDebugDraw: string
  • PreDraw: string
  • PreLoad: string
  • PreUpdate: string

ScreenEvents

ScreenEvents: { FullScreenChange: fullscreen; PixelRatioChange: pixelratio; ScreenResize: resize }

Type declaration

  • readonlyFullScreenChange: fullscreen
  • readonlyPixelRatioChange: pixelratio
  • readonlyScreenResize: resize

SoundEvents

SoundEvents: { Pause: string; PlaybackEnd: string; PlaybackStart: string; Processed: string; Resume: string; Stop: string; VolumeChange: string }

Type declaration

  • Pause: string
  • PlaybackEnd: string
  • PlaybackStart: string
  • Processed: string
  • Resume: string
  • Stop: string
  • VolumeChange: string

constSystemPriority

SystemPriority: { Average: 0; Higher: -5; Highest: number; Lower: 5; Lowest: number } = ...

Higher priorities run earlier than others in the system update


Type declaration

  • readonlyAverage: 0
  • readonlyHigher: -5
  • readonlyHighest: number
  • readonlyLower: 5
  • readonlyLowest: number

TileMapEvents

TileMapEvents: { PostDraw: string; PostUpdate: string; PreDraw: string; PreUpdate: string }

Type declaration

  • PostDraw: string
  • PostUpdate: string
  • PreDraw: string
  • PreUpdate: string

TriggerEvents

TriggerEvents: { EnterTrigger: string; ExitTrigger: string }

Type declaration

  • EnterTrigger: string
  • ExitTrigger: string

constTwoPI

TwoPI: number = ...

Two PI constant

constVerticalFirst

VerticalFirst: ContactBias = ...

Vertical First contact solve bias Used by the [[ArcadeSolver]] to sort contacts

constmaxMessages

maxMessages: 5 = 5

constpixelSnapEpsilon

pixelSnapEpsilon: 0.0001 = 0.0001