game_actor_animation_track_vec2_track.js
import ActorAnimationTrack from "./actor_animation_track.js";
import Vec2Gradient from "../../../../util/gradient/vec2_gradient.js";
/**
* @module Vec2Track
* @fileoverview Contains Vec2Track class.
*/
/**
* @class Vec2Track
* @extends ActorAnimationTrack
* @abstract
* Base class for manipulating actor attributes of the Vec2 type.
*/
class Vec2Track extends ActorAnimationTrack {
/**
* Create a new Vec2 track.
* @param {Object.<number, number|Vec2>} values Values at time intervals
* @param {boolean} smooth Whether the track should start and end smoothly/gradually (false by default)
* @constructor
*/
constructor(values = {}, smooth = false) {
super();
this._gradient = new Vec2Gradient(values, smooth);
}
}
export default Vec2Track;