UNPKG

@polygonjs/polygonjs

Version:

node-based WebGL 3D engine https://polygonjs.com

40 lines (39 loc) 1.72 kB
/** * Starts and pauses animations * * */ import { TypedEventNode } from './_Base'; import { NodeParamsConfig } from '../utils/params/ParamsConfig'; import { ModuleName } from '../../poly/registers/modules/Common'; import { EventContext } from '../../../core/event/EventContextType'; export declare enum AnimationEventOutput { START = "start", COMPLETE = "completed" } declare class AnimationEventParamsConfig extends NodeParamsConfig { /** @parm animation node */ animation: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.NODE_PATH>; /** @parm presses to play the animation */ play: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.BUTTON>; /** @parm presses to pause the animation */ pause: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.BUTTON>; /** @param stops previous animations still in progress started by this node */ stopsPreviousAnim: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.BOOLEAN>; } export declare class AnimationEventNode extends TypedEventNode<AnimationEventParamsConfig> { paramsConfig: AnimationEventParamsConfig; static type(): string; requiredModules(): ModuleName[]; private _timelineBuilder; private _timeline; initializeNode(): void; processEvent(event_context: EventContext<Event>): void; static PARAM_CALLBACK_play(node: AnimationEventNode): void; static PARAM_CALLBACK_pause(node: AnimationEventNode): void; private _play; private _pause; private _triggerAnimationStarted; private _triggerAnimationCompleted; } export {};