aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/RDGE/src/core/script/engine.js
diff options
context:
space:
mode:
authorValerio Virgillito2012-03-13 11:15:34 -0700
committerValerio Virgillito2012-03-13 11:15:34 -0700
commitf6b958360d82854bdaf51848e7fd715d1f633179 (patch)
tree80f6c08bb730089bdd3f26310df8d2363f9ba863 /js/helper-classes/RDGE/src/core/script/engine.js
parentc24f58c10231c30d3a8a4c9fb9a4f395dd746180 (diff)
parent4d7b86f55c504ee4e8c2460cf6b60cb9a2cf18f0 (diff)
downloadninja-f6b958360d82854bdaf51848e7fd715d1f633179.tar.gz
Merge pull request #105 from joseeight/FileIO-Build-Candidate
File I/O adding webGL/canvas data functionality
Diffstat (limited to 'js/helper-classes/RDGE/src/core/script/engine.js')
-rwxr-xr-xjs/helper-classes/RDGE/src/core/script/engine.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/js/helper-classes/RDGE/src/core/script/engine.js b/js/helper-classes/RDGE/src/core/script/engine.js
index 5bc9305c..f5724665 100755
--- a/js/helper-classes/RDGE/src/core/script/engine.js
+++ b/js/helper-classes/RDGE/src/core/script/engine.js
@@ -89,6 +89,8 @@ stateManager = function()
89g_enableBenchmarks = true; 89g_enableBenchmarks = true;
90function Engine() 90function Engine()
91{ 91{
92 this._assetPath = "assets/";
93
92 // map of scene graphs to names 94 // map of scene graphs to names
93 this.sceneMap = []; 95 this.sceneMap = [];
94 96
@@ -228,6 +230,19 @@ function Engine()
228 contextManager.currentCtx = savedCtx; 230 contextManager.currentCtx = savedCtx;
229 231
230 } 232 }
233
234 this.remapAssetFolder = function( url )
235 {
236 var searchStr = "assets/";
237 var index = url.indexOf( searchStr );
238 var rtnPath = url;
239 if (index >= 0)
240 {
241 rtnPath = url.substr( index + searchStr.length );
242 rtnPath = this._assetPath + rtnPath;
243 }
244 return rtnPath;
245 }
231 246
232} 247}
233 248