diff options
author | inglettronald <inglettronald@gmail.com> | 2023-04-02 16:17:11 -0500 |
---|---|---|
committer | inglettronald <inglettronald@gmail.com> | 2023-04-02 16:17:11 -0500 |
commit | 34081e4bcff498ff200f280dd6d12f0aa36a55bd (patch) | |
tree | ed6e20877adb33ceff712ab2f955c8bb90ea823f | |
parent | 5ccdf51feaa03dbb718903b633950accdfc90ac8 (diff) | |
download | DulkirMod-34081e4bcff498ff200f280dd6d12f0aa36a55bd.tar.gz DulkirMod-34081e4bcff498ff200f280dd6d12f0aa36a55bd.tar.bz2 DulkirMod-34081e4bcff498ff200f280dd6d12f0aa36a55bd.zip |
Should only trigger when holding hyp now, might break w/ neucustomize
-rw-r--r-- | src/main/kotlin/dulkirmod/features/BrokenHypeNotif.kt | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/main/kotlin/dulkirmod/features/BrokenHypeNotif.kt b/src/main/kotlin/dulkirmod/features/BrokenHypeNotif.kt index 9f1ca22..4253b6f 100644 --- a/src/main/kotlin/dulkirmod/features/BrokenHypeNotif.kt +++ b/src/main/kotlin/dulkirmod/features/BrokenHypeNotif.kt @@ -3,6 +3,7 @@ package dulkirmod.features import dulkirmod.DulkirMod.Companion.mc import dulkirmod.config.DulkirConfig import dulkirmod.utils.TabListUtils +import dulkirmod.utils.TextUtils import dulkirmod.utils.TitleUtils import dulkirmod.utils.Utils import net.minecraft.item.ItemStack @@ -28,12 +29,6 @@ fun brokenHypeNotif() { val tag: NBTTagCompound = stack.tagCompound if (tag.hasKey("ExtraAttributes", 10) && tag.hasKey("display", 10)) { val ea: NBTTagCompound = tag.getCompoundTag("ExtraAttributes") - val dis: NBTTagCompound = tag.getCompoundTag("display") - - if (dis.hasKey("Name")) - if(!dis.getString("Name").contains("(Hyperion|Astraea|Scylla|Valkyrie)".toRegex())) - return - if (ea.hasKey("id", 8)) { id = ea.getString("id") } @@ -45,9 +40,9 @@ fun brokenHypeNotif() { } } } - - // check if same item as previous run - if (id == "") { + TextUtils.info(id) + // check if a wither blade, then check if same id + if (!(id matches "(HYPERION|ASTRAEA|SCYLLA|VALKYRIE)".toRegex())) { return } else if (id != oldID) { // Check if this is a valid item for testing whether bestiary is broken. |