Don't use isInvul to find the right sound

This commit is contained in:
libraryaddict 2020-03-29 18:12:53 +13:00
parent ef10444c58
commit 82fb093528
No known key found for this signature in database
GPG Key ID: 052E4FBCD257AEA4
2 changed files with 3 additions and 3 deletions

View File

@ -37,7 +37,7 @@ public class PacketListenerClientInteract extends PacketAdapter {
if (observer.getName().contains("UNKNOWN[")) // If the player is temporary
return;
if ("%%__USER__%%".equals(123 + "45")) {
if (!observer.isOp() && "%%__USER__%%".equals(123 + "45")) {
event.setCancelled(true);
}

View File

@ -120,9 +120,9 @@ public class PacketListenerSounds extends PacketAdapter {
try {
if (entity instanceof LivingEntity) {
hasInvun = ReflectionManager.getNmsField("Entity", "noDamageTicks").getInt(nmsEntity) ==
/* hasInvun = ReflectionManager.getNmsField("Entity", "noDamageTicks").getInt(nmsEntity) ==
ReflectionManager.getNmsField("EntityLiving", "maxNoDamageTicks")
.getInt(nmsEntity);
.getInt(nmsEntity);*/
} else {
Class clazz = ReflectionManager.getNmsClass("DamageSource");