mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 10:37:34 +00:00
implemented gameobject for tiles and doll
This commit is contained in:
parent
fe0d4a66e2
commit
d51c705c1c
15 changed files with 221 additions and 326 deletions
|
|
@ -1,14 +1,19 @@
|
|||
define([
|
||||
"Game/Client/View/DomController",
|
||||
"Game/Config/Settings",
|
||||
"Lib/Utilities/Exception"
|
||||
"Lib/Utilities/Exception",
|
||||
"Game/Core/NotificationCenter"
|
||||
],
|
||||
|
||||
function (DomController, Settings, Exception) {
|
||||
function (DomController, Settings, Exception, NotificationCenter) {
|
||||
|
||||
function AbstractView () {
|
||||
this.me = null;
|
||||
this.canvas = null;
|
||||
|
||||
NotificationCenter.on("view/createMesh", this.createMesh, this);
|
||||
NotificationCenter.on("view/addMesh", this.addMesh, this);
|
||||
NotificationCenter.on("view/updateMesh", this.updateMesh, this);
|
||||
}
|
||||
|
||||
AbstractView.prototype.isWebGlEnabled = function () {
|
||||
|
|
@ -29,10 +34,6 @@ function (DomController, Settings, Exception) {
|
|||
}
|
||||
}
|
||||
|
||||
AbstractView.prototype.addMesh = function(mesh) {
|
||||
throw new Exception('Abstract Function addMesh not overwritten ');
|
||||
};
|
||||
|
||||
AbstractView.prototype.loadPlayerMesh = function(player) {
|
||||
throw new Exception('Abstract Function loadPlayerMesh not overwritten ');
|
||||
};
|
||||
|
|
@ -49,6 +50,14 @@ function (DomController, Settings, Exception) {
|
|||
throw new Exception('Abstract Function createMesh not overwritten ');
|
||||
}
|
||||
|
||||
AbstractView.prototype.addMesh = function(mesh) {
|
||||
throw new Exception('Abstract Function addMesh not overwritten ');
|
||||
};
|
||||
|
||||
AbstractView.prototype.updateMesh = function(mesh, options) {
|
||||
throw new Exception('Abstract Function updateMesh not overwritten ');
|
||||
};
|
||||
|
||||
AbstractView.prototype.setMe = function(player) {
|
||||
this.me = player;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue