summaryrefslogtreecommitdiff
path: root/src/game.js
diff options
context:
space:
mode:
authorphat_sumo <ethanjpayne1@gmail.com>2022-04-02 18:48:00 -0600
committerphat_sumo <ethanjpayne1@gmail.com>2022-04-02 18:48:00 -0600
commitcf4dbf91ddb980c051ee2905367143d433c376a5 (patch)
tree9b4697850979774ba8056ac792230bfb7b8a2073 /src/game.js
parentaef3c05bc7f3feba7832078aa1cb4bd96c52c1dd (diff)
downloadbbiy-cf4dbf91ddb980c051ee2905367143d433c376a5.tar.gz
bbiy-cf4dbf91ddb980c051ee2905367143d433c376a5.zip
the mess that is pushable
Diffstat (limited to 'src/game.js')
-rw-r--r--src/game.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/game.js b/src/game.js
index 04aa4fc..07ea67b 100644
--- a/src/game.js
+++ b/src/game.js
@@ -29,6 +29,7 @@ game.initialize = () => {
Array(400).fill(null).forEach((_, i) => {
const bigBlue = game.createBigBlue();
bigBlue.addComponent(game.components.GridPosition({x: Math.floor(Math.random() * 15), y: Math.floor(Math.random() * 13)}));
+ bigBlue.addComponent(game.components.Pushable());
game.entities[bigBlue.id] = bigBlue;
});
@@ -36,6 +37,7 @@ game.initialize = () => {
game.rock.addComponent(game.components.Position({x: 200, y: 200}));
game.rock.addComponent(game.components.GridPosition({x: 0, y: 0}));
game.rock.addComponent(game.components.Controllable({controls: ['left', 'right', 'up', 'down']}));
+ game.rock.addComponent(game.components.Pushable());
game.entities[game.rock.id] = game.rock;
lastTimeStamp = performance.now()