refactored Server and Lobby

This commit is contained in:
Jeena 2014-03-01 14:07:03 +01:00
parent 42475c9b38
commit d83376d5c7
26 changed files with 29 additions and 29 deletions

View file

@ -0,0 +1,25 @@
define([
"Game/Core/Loader/Level",
"Game/Config/Settings",
"fs"
],
function (Parent, Settings, fs) {
function Level (uid, engine, gameObjects) {
Parent.call(this, uid, engine, gameObjects);
}
Level.prototype = Object.create(Parent.prototype);
Level.prototype.loadLevelDataFromPath = function (path, callback) {
// overwriting parent
fs.readFile(path, "utf8", function (err, data) {
if (err) throw err;
callback(JSON.parse(data));
});
}
return Level;
});