diff options
Diffstat (limited to 'js/lib/rdge/materials/tunnel-material.js')
-rw-r--r-- | js/lib/rdge/materials/tunnel-material.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/js/lib/rdge/materials/tunnel-material.js b/js/lib/rdge/materials/tunnel-material.js index 0a96e23e..74913aa8 100644 --- a/js/lib/rdge/materials/tunnel-material.js +++ b/js/lib/rdge/materials/tunnel-material.js | |||
@@ -90,6 +90,16 @@ var TunnelMaterial = function TunnelMaterial() { | |||
90 | this.setResolution([world.getViewportWidth(), world.getViewportHeight()]); | 90 | this.setResolution([world.getViewportWidth(), world.getViewportHeight()]); |
91 | this.update(0); | 91 | this.update(0); |
92 | }; | 92 | }; |
93 | |||
94 | this.resetToDefault = function() | ||
95 | { | ||
96 | this._propValues[this._propNames[u_tex0_index]] = this._defaultTexMap.slice(0); | ||
97 | this._propValues[this._propNames[u_speed_index]] = 1.0; | ||
98 | |||
99 | var nProps = this._propNames.length; | ||
100 | for (var i=0; i<nProps; i++) | ||
101 | this.setProperty( this._propNames[i], this._propValues[this._propNames[i]] ); | ||
102 | }; | ||
93 | }; | 103 | }; |
94 | 104 | ||
95 | /////////////////////////////////////////////////////////////////////////////////////// | 105 | /////////////////////////////////////////////////////////////////////////////////////// |