From ad6a454ed939ec02042f2b6432de2878889c86d4 Mon Sep 17 00:00:00 2001 From: Robert Skalko Date: Thu, 2 Jan 2025 21:49:40 +0100 Subject: [PATCH] 6.0.2 --- CHANGELOG.txt | 4 ++-- UPDATE/v.6.0.txt - Shortcut.lnk | Bin 0 -> 1144 bytes changelogs/v.6.0.txt | 5 +++++ gradle.properties | 2 +- .../damage_hooks/util/AttackInformation.java | 6 ++++++ .../itemstack/CommonTooltips.java | 16 ++++++++-------- .../item_classes/GearTooltipUtils.java | 2 +- .../saveclasses/jewel/JewelItemData.java | 2 +- .../uncommon/effectdatas/DamageEvent.java | 2 +- 9 files changed, 25 insertions(+), 14 deletions(-) create mode 100644 UPDATE/v.6.0.txt - Shortcut.lnk diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 248dd8e57..fe08dc570 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,4 +1,4 @@ Changelog of recent updates: https://github.com/RobertSkalko/Mine-And-Slash-Rework/blob/1.20-Forge/changelogs/v.6.0.txt -v.6.0.1 -- fixed 1 hp mobs \ No newline at end of file +v.6.0.2 +- fixed sweeping \ No newline at end of file diff --git a/UPDATE/v.6.0.txt - Shortcut.lnk b/UPDATE/v.6.0.txt - Shortcut.lnk new file mode 100644 index 0000000000000000000000000000000000000000..db39fb3590cb669467819517b3b1899e45266fbb GIT binary patch literal 1144 zcmbVLUr1A76hB+5w4x?htYvu_EQ8whE@-77Y;4mdPNhwqmuq?1Zu{ffMjN(=GUzE# z=?~OP7!s{|P|6@B?2m8di>w9d7=jV>V8OD7AS&pb>-_UD3jE-A&iT%FzTY|beCIX+ zfTCQ95@1S}P=5zXfI(Xudhh-&{@6zQ!#j;wJEsAoeY+Yzc zGmEuB^}V?gILvWFd!gD|E35{s8E3&LZ&V!zkEy|Vve|C1^r5R6Ny(yN-9Hh&}&@I2|O`t;W(Z=mi!`2o8~eB!ajB+7J~8YBXsBf|eUW{n&)a z4E{)}Q3E#F8H`8zzY+Zc!`H{0f);~FaJp1}*I@CG)HeWWH zJMyjT~U~puD`1leX$rpB#VMeU{7_`5HpdufHyoc&; zWy+p?fT@00j_h6=I{^F7|fBOREM!$;bAbvyBeM91k64_I_P*U_bilcaW#= zVvPAZbmf};>C2htXUwYGr+onh6o#@{}0aP`yY_w|PSik-P DSo!X5 literal 0 HcmV?d00001 diff --git a/changelogs/v.6.0.txt b/changelogs/v.6.0.txt index cb1d5c4c5..719182a8d 100644 --- a/changelogs/v.6.0.txt +++ b/changelogs/v.6.0.txt @@ -37,3 +37,8 @@ Other: - loot chests can no longer be salvaged - merged clefal's PR to reduce talent tree lag +v.6.0.1 +- fixed 1 hp mobs + +v.6.0.2 +- fixed sweeping \ No newline at end of file diff --git a/gradle.properties b/gradle.properties index c6c0aa601..b02d96ed2 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,7 +2,7 @@ org.gradle.jvmargs=-Xmx2G # --- COMMON GRADLE START --- # Mod Properties -mod_version=6.0.1 +mod_version=6.0.2 # Minecraft Versions minecraft_version=1.20.1 forgeversion=47.1.43 diff --git a/src/main/java/com/robertx22/mine_and_slash/event_hooks/damage_hooks/util/AttackInformation.java b/src/main/java/com/robertx22/mine_and_slash/event_hooks/damage_hooks/util/AttackInformation.java index 530655821..316c39be8 100644 --- a/src/main/java/com/robertx22/mine_and_slash/event_hooks/damage_hooks/util/AttackInformation.java +++ b/src/main/java/com/robertx22/mine_and_slash/event_hooks/damage_hooks/util/AttackInformation.java @@ -60,6 +60,12 @@ public void setAmount(float f) { } } + // setting it to super tiny number still allows the bit of damage to go through + // this makes sweeping edge work + public void setToMinimalNonZero() { + this.setAmount(0.0000001F); + } + public LivingEntity getTargetEntity() { return targetEntity; } diff --git a/src/main/java/com/robertx22/mine_and_slash/itemstack/CommonTooltips.java b/src/main/java/com/robertx22/mine_and_slash/itemstack/CommonTooltips.java index c3d46ef94..95b12dba7 100644 --- a/src/main/java/com/robertx22/mine_and_slash/itemstack/CommonTooltips.java +++ b/src/main/java/com/robertx22/mine_and_slash/itemstack/CommonTooltips.java @@ -1,6 +1,5 @@ package com.robertx22.mine_and_slash.itemstack; -import com.google.common.collect.ImmutableList; import com.robertx22.mine_and_slash.gui.texts.textblocks.AdditionalBlock; import com.robertx22.mine_and_slash.uncommon.localization.Itemtips; import com.robertx22.mine_and_slash.uncommon.localization.Words; @@ -14,14 +13,15 @@ public class CommonTooltips { - public static AdditionalBlock potentialCorruptionAndQuality(ExileStack exStack) { + public static AdditionalBlock potentialCorruptionAndQuality(ExileStack exStack, boolean doQuality) { - return new AdditionalBlock( - ImmutableList.of( - exStack.isCorrupted() ? Component.literal("").append(Itemtips.POTENTIAL.locName(exStack.get(StackKeys.POTENTIAL).getOrCreate().potential).withStyle(ChatFormatting.DARK_GRAY, ChatFormatting.STRIKETHROUGH)).append(Component.literal(" ")).append(Words.Corrupted.locName().withStyle(ChatFormatting.RED)) : Itemtips.POTENTIAL.locName(exStack.get(StackKeys.POTENTIAL).getOrCreate().potential).withStyle(ChatFormatting.GOLD), - Itemtips.QUALITY.locName(exStack.get(StackKeys.CUSTOM).getOrCreate().data.get(CustomItemData.KEYS.QUALITY)).withStyle(ChatFormatting.GOLD) - ) - ).showWhen(() -> Screen.hasShiftDown()); + List list = new ArrayList<>(); + list.add(exStack.isCorrupted() ? Component.literal("").append(Itemtips.POTENTIAL.locName(exStack.get(StackKeys.POTENTIAL).getOrCreate().potential).withStyle(ChatFormatting.DARK_GRAY, ChatFormatting.STRIKETHROUGH)).append(Component.literal(" ")).append(Words.Corrupted.locName().withStyle(ChatFormatting.RED)) : Itemtips.POTENTIAL.locName(exStack.get(StackKeys.POTENTIAL).getOrCreate().potential).withStyle(ChatFormatting.GOLD)); + + if (doQuality) { + Itemtips.QUALITY.locName(exStack.get(StackKeys.CUSTOM).getOrCreate().data.get(CustomItemData.KEYS.QUALITY)).withStyle(ChatFormatting.GOLD); + } + return new AdditionalBlock(list).showWhen(() -> Screen.hasShiftDown()); } public static AdditionalBlock craftedItem(ExileStack exStack) { diff --git a/src/main/java/com/robertx22/mine_and_slash/saveclasses/item_classes/GearTooltipUtils.java b/src/main/java/com/robertx22/mine_and_slash/saveclasses/item_classes/GearTooltipUtils.java index e74b07693..7aa94dda2 100644 --- a/src/main/java/com/robertx22/mine_and_slash/saveclasses/item_classes/GearTooltipUtils.java +++ b/src/main/java/com/robertx22/mine_and_slash/saveclasses/item_classes/GearTooltipUtils.java @@ -242,7 +242,7 @@ public List getAvailableComponents() { return list; } }) - .accept(CommonTooltips.potentialCorruptionAndQuality(exStack)) + .accept(CommonTooltips.potentialCorruptionAndQuality(exStack, true)) .accept(CommonTooltips.craftedItem(exStack)) .accept(new AdditionalBlock(() -> { int cost = (int) Energy.getInstance().scale(ModType.FLAT, gear.GetBaseGearType().getGearSlot().weapon_data.energy_cost_per_swing, data.getLevel()); diff --git a/src/main/java/com/robertx22/mine_and_slash/saveclasses/jewel/JewelItemData.java b/src/main/java/com/robertx22/mine_and_slash/saveclasses/jewel/JewelItemData.java index 2a0e8dad6..8a60b913b 100644 --- a/src/main/java/com/robertx22/mine_and_slash/saveclasses/jewel/JewelItemData.java +++ b/src/main/java/com/robertx22/mine_and_slash/saveclasses/jewel/JewelItemData.java @@ -164,7 +164,7 @@ public List getAvailableComponents() { .accept(new OperationTipBlock().setShift().setAlt()); - tip.accept(CommonTooltips.potentialCorruptionAndQuality(ex)); + tip.accept(CommonTooltips.potentialCorruptionAndQuality(ex, false)); tip.accept(new ClickToOpenGuiBlock()); diff --git a/src/main/java/com/robertx22/mine_and_slash/uncommon/effectdatas/DamageEvent.java b/src/main/java/com/robertx22/mine_and_slash/uncommon/effectdatas/DamageEvent.java index e7a24e19f..3afa5ee4e 100644 --- a/src/main/java/com/robertx22/mine_and_slash/uncommon/effectdatas/DamageEvent.java +++ b/src/main/java/com/robertx22/mine_and_slash/uncommon/effectdatas/DamageEvent.java @@ -529,7 +529,7 @@ protected void activate() { } if (attackInfo != null) { if (CompatConfig.get().DAMAGE_COMPATIBILITY().overridesDamage) { - attackInfo.setAmount(0); + attackInfo.setToMinimalNonZero(); } } if (stopFriendlyFire()) {