if (mode.is("Matrix/RW")) {
matrixMode();
private void matrixMode() {
for (PlayerEntity entity : mc.world.getPlayers()) {
if (entity == mc.player) continue;
UUID playerUUID = entity.getUniqueID();
boolean hasBoots = entity.inventory.armorInventory.get(0).getItem() != Items.AIR;
boolean hasLeggings = entity.inventory.armorInventory.get(1).getItem() != Items.AIR;
boolean hasChestplate = entity.inventory.armorInventory.get(2).getItem() != Items.AIR;
boolean hasHelmet = entity.inventory.armorInventory.get(3).getItem() != Items.AIR;
boolean bootsEnchantable = entity.inventory.armorInventory.get(0).isEnchantable();
boolean leggingsEnchantable = entity.inventory.armorInventory.get(1).isEnchantable();
boolean chestplateEnchantable = entity.inventory.armorInventory.get(2).isEnchantable();
boolean helmetEnchantable = entity.inventory.armorInventory.get(3).isEnchantable();
boolean emptyOffhand = entity.getHeldItemOffhand().getItem() == Items.AIR;
boolean hasLeatherOrIron = isLeatherOrIronArmor(entity);
boolean hasMainHandItem = entity.getHeldItemMainhand().getItem() != Items.AIR;
boolean notDamaged = isArmorNotDamaged(entity);
boolean fullHunger = entity.getFoodStats().getFoodLevel() == 20;
boolean isBot = hasBoots && hasLeggings && hasChestplate && hasHelmet &&
bootsEnchantable && leggingsEnchantable && chestplateEnchantable && helmetEnchantable &&
emptyOffhand && hasLeatherOrIron && hasMainHandItem && notDamaged && fullHunger;
updateBotStatus(playerUUID, isBot);
}
}