Draconic Evolution

Draconic Evolution

77M Downloads

Another Shield Countermeasure (NBT Tag manipulation.)

ruifung opened this issue ยท 1 comments

commented

Judging by the commit in elytra/MagicArsenal@d816711

It looks like it's directly changing the armor's NBT tags to disable shielding.
Just thought you'd like to know. 'Cause I'd say this looks trivial to pull off.

+public class DracEvoCompat {
+	public static void deployCountermeasures(EntityLivingBase target) {
+		for(ItemStack item : target.getArmorInventoryList()) {
+			if (item==null || item.isEmpty()) continue;
+			NBTTagCompound tag = item.getTagCompound();
+			if (tag==null) continue;
+			if (tag.hasKey("ProtectionPoints")) {
+				tag.setFloat("ProtectionPoints", 0);
+			}
+			
+			if (tag.hasKey("ShieldEntropy")) {
+				 tag.setFloat("ShieldEntropy", 0);
+			}
+		}
+	}
+}
commented

Thanks for the report, but there is nothing that can be done about this.