lingo3d
Version:
Lingo3D is a React/Vue 3d game development framework that ships with a complete visual editor
56 lines • 1.47 kB
JavaScript
import { waterDefaults, waterSchema } from "../interface/IWater";
import PhysicsObjectManager from "./core/PhysicsObjectManager";
import { ssrExcludeSet } from "../collections/ssrExcludeSet";
import { configWaterSystem } from "../systems/configSystems/configWaterSystem";
class Water extends PhysicsObjectManager {
static componentName = "water";
static defaults = waterDefaults;
static schema = waterSchema;
$water;
_shape = "plane";
get shape() {
return this._shape;
}
set shape(val) {
this._shape = val;
configWaterSystem.add(this);
}
_normalMap;
get normalMap() {
return this._normalMap;
}
set normalMap(val) {
this._normalMap = val;
configWaterSystem.add(this);
}
_resolution = 512;
get resolution() {
return this._resolution;
}
set resolution(val) {
this._resolution = val;
configWaterSystem.add(this);
}
speed = 1;
constructor() {
super();
ssrExcludeSet.add(this.outerObject3d);
this.rotationX = 270;
this.object3d.scale.z = Number.EPSILON;
configWaterSystem.add(this);
}
disposeNode() {
super.disposeNode();
ssrExcludeSet.delete(this.outerObject3d);
}
get depth() {
return 0;
}
set depth(_) { }
get scaleZ() {
return 0;
}
set scaleZ(_) { }
}
export default Water;
//# sourceMappingURL=Water.js.map