Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/bru-gas-masks' into bru-gas-masks
Browse files Browse the repository at this point in the history
  • Loading branch information
grema committed Jan 13, 2025
2 parents ffe7663 + 8bde6d6 commit 82f7570
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,6 @@ public double tryTick(ItemStack stack, EntityPlayer player) {
ItemStack chest = player.getItemStackFromSlot(CHEST);
if (chest.getItem() instanceof SuSyArmorItem item) {
if (item.getItem(chest).getArmorLogic() instanceof AdvancedBreathingApparatus tank && tank.tier == tier) {
if (tank.getOxygen(chest) <= 0) {
return 0.0625;
} else {
tank.changeOxygen(chest, -1.);
}
tank.handleDamage(chest, player);

int piecesCount = 0;
Expand All @@ -88,6 +83,12 @@ public double tryTick(ItemStack stack, EntityPlayer player) {
piecesCount++;
}
}

if (tank.getOxygen(chest) <= 0) {
return 0.0625;
} else {
tank.changeOxygen(chest, -1.);
}
switch (piecesCount) {
case 0:
return 0.5;
Expand Down

0 comments on commit 82f7570

Please sign in to comment.