Inventory hardware: Now clearing a biomass gains 4000 kJ.

This commit is contained in:
Dylan Sheehy 2018-01-01 13:15:14 -06:00
parent 1e26c63358
commit 7ee361b0bc

View File

@ -38,7 +38,11 @@ public class CubotInventory extends CpuHardware {
getCpu().getRegisterSet().getRegister("B").setValue(cubot.getHeldItem());
} else if (a == INV_CLEAR) {
if (cubot.spendEnergy(100)) {
if (cubot.getHeldItem() == 0x0001) {
cubot.storeEnergy(4000);
cubot.setHeldItem(0);
}
else if (cubot.spendEnergy(100)) {
cubot.setHeldItem(0);
}
}