r3-legacy/src/game-lib-d3-api-spline.js

27 lines
520 B
JavaScript

/**
* API Spline
* @param id String
* @param name String
* @param vertices GameLib.API.Vector3[]
* @constructor
*/
GameLib.D3.API.Spline = function(
id,
name,
vertices
) {
if (GameLib.Utils.UndefinedOrNull(id)) {
id = GameLib.Utils.RandomId();
}
this.id = id;
if (GameLib.Utils.UndefinedOrNull(name)) {
name = 'spline-unnamed';
}
this.name = name;
if (GameLib.Utils.UndefinedOrNull(vertices)) {
vertices = [];
}
this.vertices = vertices;
};