diff options
Diffstat (limited to 'js/lib/rdge/materials/square-tunnel-material.js')
-rw-r--r-- | js/lib/rdge/materials/square-tunnel-material.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/js/lib/rdge/materials/square-tunnel-material.js b/js/lib/rdge/materials/square-tunnel-material.js index 73df4073..f81602f0 100644 --- a/js/lib/rdge/materials/square-tunnel-material.js +++ b/js/lib/rdge/materials/square-tunnel-material.js | |||
@@ -5,6 +5,7 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
5 | </copyright> */ | 5 | </copyright> */ |
6 | 6 | ||
7 | var PulseMaterial = require("js/lib/rdge/materials/pulse-material").PulseMaterial; | 7 | var PulseMaterial = require("js/lib/rdge/materials/pulse-material").PulseMaterial; |
8 | var Texture = require("js/lib/rdge/texture").Texture; | ||
8 | 9 | ||
9 | var SquareTunnelMaterial = function SquareTunnelMaterial() { | 10 | var SquareTunnelMaterial = function SquareTunnelMaterial() { |
10 | /////////////////////////////////////////////////////////////////////// | 11 | /////////////////////////////////////////////////////////////////////// |
@@ -62,6 +63,10 @@ var SquareTunnelMaterial = function SquareTunnelMaterial() { | |||
62 | this._shader['default'].u_time.set([this._time]); | 63 | this._shader['default'].u_time.set([this._time]); |
63 | } | 64 | } |
64 | 65 | ||
66 | // set up the texture | ||
67 | var texMapName = this._propValues[this._propNames[0]]; | ||
68 | this._glTex = new Texture( world, texMapName ); | ||
69 | |||
65 | // set the shader values in the shader | 70 | // set the shader values in the shader |
66 | this.updateTexture(); | 71 | this.updateTexture(); |
67 | this.setResolution([world.getViewportWidth(), world.getViewportHeight()]); | 72 | this.setResolution([world.getViewportWidth(), world.getViewportHeight()]); |