[NOT A BUG] Game.rooms['sim'].storage.storeCapacity = 0 (when its not)
-
NOTE: The issue was the controller was set to level 1. Setting the controller to level 4 fixed this.
-----
In the simulator create a storage tank (defaults to 500k energy and 300k minerals) .. should be 200k left in capacity.
I have tried with console and the following code (both return 0)
function findStorageNeedsEnergy(thisRoom) {
if (thisRoom.storage &&
(_.sum(thisRoom.storage.store) < thisRoom.storage.storeCapacity)) {
return thisRoom.storage;
}
}
-
Make sure the controller level is >= 4. Else the storage will be set to 0.
Level < 4 - http://i.imgur.com/64YAk1F.png
Level >= 4 - http://i.imgur.com/LxyVWlf.png
-
That was it .. Thanks. Missed that!
-
No problem! Good luck on your adventure!