diff options
author | hwc487 | 2012-06-28 11:44:15 -0700 |
---|---|---|
committer | hwc487 | 2012-06-28 11:44:15 -0700 |
commit | 22cbc9644b79df60b3f6336f9563debd47fb3ea1 (patch) | |
tree | f32687a920a039e0f048fab74627e0dc4ad6a8f1 /js/lib/rdge/materials/plasma-material.js | |
parent | 2ebf3e3ea24d0d580575dfa13d31588dac1de445 (diff) | |
download | ninja-22cbc9644b79df60b3f6336f9563debd47fb3ea1.tar.gz |
Added capability to split a mesh into multiiple parts to avoid buffer overflow situations.
Diffstat (limited to 'js/lib/rdge/materials/plasma-material.js')
-rw-r--r-- | js/lib/rdge/materials/plasma-material.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/js/lib/rdge/materials/plasma-material.js b/js/lib/rdge/materials/plasma-material.js index 10c29c99..fe64db93 100644 --- a/js/lib/rdge/materials/plasma-material.js +++ b/js/lib/rdge/materials/plasma-material.js | |||
@@ -80,6 +80,18 @@ var PlasmaMaterial = function PlasmaMaterial() { | |||
80 | this._shader['default'].u_time.set( [this._time] ); | 80 | this._shader['default'].u_time.set( [this._time] ); |
81 | this._time += this._dTime; | 81 | this._time += this._dTime; |
82 | }; | 82 | }; |
83 | |||
84 | this.resetToDefault = function() | ||
85 | { | ||
86 | this._propValues[ this._propNames[0] ] = this._wave; | ||
87 | this._propValues[ this._propNames[1] ] = this._wave1; | ||
88 | this._propValues[ this._propNames[2] ] = this._wave2; | ||
89 | this._propValues[ this._propNames[3] ] = this._speed; | ||
90 | |||
91 | var nProps = this._propNames.length; | ||
92 | for (var i=0; i<nProps; i++) | ||
93 | this.setProperty( this._propNames[i], this._propValues[this._propNames[i]] ); | ||
94 | }; | ||
83 | }; | 95 | }; |
84 | 96 | ||
85 | /////////////////////////////////////////////////////////////////////////////////////// | 97 | /////////////////////////////////////////////////////////////////////////////////////// |