From d7191e4f715823fa66286f1bed021deb849f27d3 Mon Sep 17 00:00:00 2001 From: Anuken Date: Mon, 22 Apr 2024 08:43:25 -0400 Subject: [PATCH] Fixed #9769 --- core/src/mindustry/world/blocks/defense/turrets/ItemTurret.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/mindustry/world/blocks/defense/turrets/ItemTurret.java b/core/src/mindustry/world/blocks/defense/turrets/ItemTurret.java index 1a709dc5a8..14aa007d35 100644 --- a/core/src/mindustry/world/blocks/defense/turrets/ItemTurret.java +++ b/core/src/mindustry/world/blocks/defense/turrets/ItemTurret.java @@ -80,7 +80,7 @@ public class ItemTurret extends Turret{ @Override public float efficiency(Building build){ //valid when it can shoot - return build instanceof ItemTurretBuild it && it.hasAmmo() ? 1f : 0f; + return build instanceof ItemTurretBuild it && it.ammo.size > 0 && (it.ammo.peek().amount >= ammoPerShot || it.cheating()) ? 1f : 0f; } @Override