Campaign production fixes

This commit is contained in:
Anuken
2020-11-28 15:08:53 -05:00
parent 9ca3cd49b8
commit b8cb17c0c5
3 changed files with 54 additions and 24 deletions

View File

@@ -76,6 +76,8 @@ abstract class MinerComp implements Itemsc, Posc, Teamc, Rotc, Drawc{
if(mineTimer >= 50f + item.hardness*15f){
mineTimer = 0;
if(state.rules.sector != null && team() == state.rules.defaultTeam) state.rules.sector.info.handleProduction(item, 1);
if(core != null && within(core, mineTransferRange) && core.acceptStack(item, 1, this) == 1 && offloadImmediately()){
//add item to inventory before it is transferred
if(item() == item) addItem(item);