From 916cc4f00a40720c17b1a61ed3dea566fbce453c Mon Sep 17 00:00:00 2001 From: -=yb4f310 Date: Sat, 30 Dec 2017 19:27:07 +0100 Subject: [PATCH] gui array query by constructor fix --- src/game-lib-system-gui.js | 2 +- src/game-lib-system-input.js | 8 ++++---- src/game-lib-system-storage.js | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/game-lib-system-gui.js b/src/game-lib-system-gui.js index e0316f5..bbbca2f 100644 --- a/src/game-lib-system-gui.js +++ b/src/game-lib-system-gui.js @@ -593,7 +593,7 @@ GameLib.System.GUI.prototype.buildArrayManagerControl = function( var idObject = {}; - var selectionObject = GameLib.EntityManager.Instance.queryComponents(constructors).reduce( + var selectionObject = GameLib.EntityManager.Instance.queryComponentsByConstructor(constructors).reduce( function(result, component) { result[component.name] = component; idObject[component.id] = component; diff --git a/src/game-lib-system-input.js b/src/game-lib-system-input.js index 9e4a680..f006416 100644 --- a/src/game-lib-system-input.js +++ b/src/game-lib-system-input.js @@ -150,7 +150,7 @@ GameLib.System.Input.prototype.instanceCreated = function(data) { if (data.component instanceof GameLib.Controls.D3.Editor) { if (this.editorControls.length > 0) { - console.log('ignoring multiple editor controls') + console.log('Ignoring multiple editor controls') } else { this.editorControls.push(data.component); this.registerEditorControls(); @@ -159,7 +159,7 @@ GameLib.System.Input.prototype.instanceCreated = function(data) { if (data.component instanceof GameLib.Controls.Touch) { if (this.touchControls.length > 0) { - console.log('ignoring multiple touch controls') + console.log('Ignoring multiple touch controls') } else { this.touchControls.push(data.component); this.registerTouchControls(); @@ -168,7 +168,7 @@ GameLib.System.Input.prototype.instanceCreated = function(data) { if (data.component instanceof GameLib.Controls.Keyboard) { if (this.keyboardControls.length > 0 || this.editorControls.length > 0) { - console.log('ignoring multiple keyboard controls') + console.log('Ignoring multiple keyboard controls') } else { this.keyboardControls.push(data.component); this.registerKeyboardControls(); @@ -177,7 +177,7 @@ GameLib.System.Input.prototype.instanceCreated = function(data) { if (data.component instanceof GameLib.Controls.Mouse) { if (this.mouseControls.length > 0) { - console.log('ignoring multiple mouse controls') + console.log('Ignoring multiple mouse controls') } else { this.mouseControls.push(data.component); this.registerMouseControls(); diff --git a/src/game-lib-system-storage.js b/src/game-lib-system-storage.js index 541c4d2..ae1bef5 100644 --- a/src/game-lib-system-storage.js +++ b/src/game-lib-system-storage.js @@ -636,7 +636,7 @@ GameLib.System.Storage.prototype.xhrLoad = function( return; } - console.log("Loading...", 'success'); + console.log('Loading from ' + url); var xhr = new XMLHttpRequest(); xhr.open("GET", url);