Default transition duration used by TransitionContainer#_play when no explicit duration is provided (milliseconds).
Desired transition type to use for transitions when no explicit type is provided.
Flag indicating whether this container is reserved for an external workflow. When true, core scene transitions should not use this container.
Flag indicating whether a transition animation is currently running. Prevents overlapping calls to TransitionContainer#_play.
Promise that resolves when the current transition finishes or is cancelled. Reused to return the same promise on repeated TransitionContainer#_play calls.
InternalCapture the currently displayed scene into a render texture and show it.
If black is true, uses a solid black frame instead of capturing the scene.
Optionaloptions: { black?: boolean; clearColor?: number[] } = {}Capture options.
Optionalblack?: booleanWhen true, uses a black frame instead of capturing.
OptionalclearColor?: number[]RGBA clear color in the 0-1 range.
The render texture of the current scene, or null if black.
InternalCapture the next rendered frame of the new scene into a render texture.
Internally waits for the next postrender so all canvas groups and caches are fully updated before capturing.
The filter class and filter type are resolved from CONFIG.Canvas.sceneTransitions.
Optionaloptions: { clearColor?: number[]; transitionType?: string } = {}Capture options.
OptionalclearColor?: number[]RGBA clear color in the 0-1 range.
OptionaltransitionType?: stringTransition type id to use for this capture. Defaults to TransitionContainer#defaultTransitionType.
Promise resolving to the captured render texture.
Run the transition animation from the captured "from" texture to the "to" texture. If a transition is already running, returns the existing promise. If no filter has been prepared, resolves immediately.
Optionalopts: { duration?: number; easing?: Function } = {}Animation options.
Optionalduration?: numberDuration in milliseconds.
Optionaleasing?: FunctionEasing function mapping [0,1] to [0,1].
Promise that resolves when the transition completes.
Reset the internal state of the transition container.
Cancel any currently running transition and await its termination.
Run a full transition around a given canvas operation. Encapsulates captureCurrentScene => operation/scene switch => captureNextScene => play.
If both options.operation and options.nextScene are provided, the operation runs first, then the Scene is switched.
If neither options.operation nor options.nextScene are provided, a simple demo transition is performed from a black frame to the currently rendered Scene.
Optionaloperation: Function = {}Async function performing canvas changes.
Promise that resolves when the transition completes.
await canvas.transition.run({
operation: async () => {
await canvas.animatePan({
x: 2000,
y: 1500,
scale: 1.25,
duration: 0
});
},
duration: 800,
transitionType: "dots"
});
Persistent overlay dedicated to scene transitions.