Skip to content

Commit

Permalink
don't allow magnet upgrade to work in spectator mode
Browse files Browse the repository at this point in the history
  • Loading branch information
desht committed Sep 7, 2024
1 parent 7095cc4 commit 378d821
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
@@ -69,7 +69,7 @@ public EquipmentSlot getEquipmentSlot() {
public void tick(ICommonArmorHandler commonArmorHandler, boolean enabled) {
Player player = commonArmorHandler.getPlayer();

if (player.level().isClientSide || !enabled
if (player.level().isClientSide || player.isSpectator() || !enabled
|| (player.level().getGameTime() & 0x3) != 0
|| !commonArmorHandler.hasMinPressure(EquipmentSlot.CHEST))
return;

0 comments on commit 378d821

Please sign in to comment.