From 28b47371f47bc98ebd00aec4cc8ba3477f5d54ba Mon Sep 17 00:00:00 2001 From: 17146 <1714673995@qq.com> Date: Sat, 3 Aug 2024 22:52:28 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=BC=A4=E5=AE=B3=E7=9A=84?= =?UTF-8?q?=E6=B3=A8=E5=86=8C=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../superbwarfare/init/ModDamageTypes.java | 28 +++++++++---------- .../tags/damage_type/bypasses_armor.json | 8 +++--- .../tags/damage_type/bypasses_effects.json | 8 +++--- .../damage_type/bypasses_enchantments.json | 8 +++--- .../tags/damage_type/bypasses_resistance.json | 8 +++--- ...pass.json => arrow_in_brain_absolute.json} | 0 ...ypass.json => arrow_in_knee_absolute.json} | 0 ...fire_bypass.json => gunfire_absolute.json} | 0 ...ss.json => gunfire_headshot_absolute.json} | 0 9 files changed, 29 insertions(+), 31 deletions(-) rename src/main/resources/data/superbwarfare/damage_type/{arrow_in_brain_bypass.json => arrow_in_brain_absolute.json} (100%) rename src/main/resources/data/superbwarfare/damage_type/{arrow_in_knee_bypass.json => arrow_in_knee_absolute.json} (100%) rename src/main/resources/data/superbwarfare/damage_type/{gunfire_bypass.json => gunfire_absolute.json} (100%) rename src/main/resources/data/superbwarfare/damage_type/{gunfire_headshot_bypass.json => gunfire_headshot_absolute.json} (100%) diff --git a/src/main/java/net/mcreator/superbwarfare/init/ModDamageTypes.java b/src/main/java/net/mcreator/superbwarfare/init/ModDamageTypes.java index 569ae9024..7e0969b36 100644 --- a/src/main/java/net/mcreator/superbwarfare/init/ModDamageTypes.java +++ b/src/main/java/net/mcreator/superbwarfare/init/ModDamageTypes.java @@ -17,21 +17,19 @@ import javax.annotation.Nullable; @SuppressWarnings("OptionalGetWithoutIsPresent") public class ModDamageTypes { public static final ResourceKey GUN_FIRE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire")); - public static final ResourceKey GUN_FIRE_BYPASS = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_bypass")); + public static final ResourceKey GUN_FIRE_ABSOLUTE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_absolute")); + public static final ResourceKey GUN_FIRE_HEADSHOT = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_headshot")); + public static final ResourceKey GUN_FIRE_HEADSHOT_ABSOLUTE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_headshot_absolute")); public static final ResourceKey ARROW_IN_KNEE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_knee")); + public static final ResourceKey ARROW_IN_KNEE_ABSOLUTE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_knee_absolute")); public static final ResourceKey ARROW_IN_BRAIN = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_brain")); + public static final ResourceKey ARROW_IN_BRAIN_ABSOLUTE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_brain_absolute")); public static final ResourceKey MINE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "mine")); public static final ResourceKey BEAST = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "beast")); public static final ResourceKey SHOCK = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "shock")); public static final ResourceKey PROJECTILE_BOOM = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "projectile_boom")); public static final ResourceKey CANNON_FIRE = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "cannon_fire")); - - public static final ResourceKey GUN_FIRE_HEADSHOT = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_headshot")); - public static final ResourceKey GUN_FIRE_HEADSHOT_BYPASS = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "gunfire_headshot_bypass")); - public static final ResourceKey ARROW_IN_KNEE_BYPASS = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_knee_bypass")); - public static final ResourceKey ARROW_IN_BRAIN_BYPASS = ResourceKey.create(Registries.DAMAGE_TYPE, new ResourceLocation(ModUtils.MODID, "arrow_in_brain_bypass")); - public static DamageSource causeGunFireDamage(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(GUN_FIRE), directEntity, attacker); } @@ -64,20 +62,20 @@ public class ModDamageTypes { return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(CANNON_FIRE), directEntity, attacker); } - public static DamageSource causeGunFireDamageBypass(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { - return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(GUN_FIRE_BYPASS), directEntity, attacker); + public static DamageSource causeGunFireAbsoluteDamage(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { + return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(GUN_FIRE_ABSOLUTE), directEntity, attacker); } - public static DamageSource causeGunFireHeadshotDamageBypass(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { - return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(GUN_FIRE_HEADSHOT_BYPASS), directEntity, attacker); + public static DamageSource causeGunFireHeadshotAbsoluteDamage(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { + return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(GUN_FIRE_HEADSHOT_ABSOLUTE), directEntity, attacker); } - public static DamageSource causeArrowInKneeDamageBypass(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { - return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(ARROW_IN_KNEE_BYPASS), directEntity, attacker); + public static DamageSource causeArrowInKneeAbsoluteDamage(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { + return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(ARROW_IN_KNEE_ABSOLUTE), directEntity, attacker); } - public static DamageSource causeArrowInBrainDamageBypass(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { - return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(ARROW_IN_BRAIN_BYPASS), directEntity, attacker); + public static DamageSource causeArrowInBrainAbsoluteDamage(RegistryAccess registryAccess, @Nullable Entity directEntity, @Nullable Entity attacker) { + return new DamageMessages(registryAccess.registry(Registries.DAMAGE_TYPE).get().getHolderOrThrow(ARROW_IN_BRAIN_ABSOLUTE), directEntity, attacker); } private static class DamageMessages extends DamageSource { diff --git a/src/main/resources/data/minecraft/tags/damage_type/bypasses_armor.json b/src/main/resources/data/minecraft/tags/damage_type/bypasses_armor.json index 95a3cfd46..f5febb66c 100644 --- a/src/main/resources/data/minecraft/tags/damage_type/bypasses_armor.json +++ b/src/main/resources/data/minecraft/tags/damage_type/bypasses_armor.json @@ -1,10 +1,10 @@ { "replace": false, "values": [ - "superbwarfare:gunfire_bypass", - "superbwarfare:gunfire_headshot_bypass", - "superbwarfare:arrow_in_knee_bypass", - "superbwarfare:arrow_in_brain_bypass", + "superbwarfare:gunfire_absolute", + "superbwarfare:gunfire_headshot_absolute", + "superbwarfare:arrow_in_knee_absolute", + "superbwarfare:arrow_in_brain_absolute", "superbwarfare:shock", "superbwarfare:cannon_fire" ] diff --git a/src/main/resources/data/minecraft/tags/damage_type/bypasses_effects.json b/src/main/resources/data/minecraft/tags/damage_type/bypasses_effects.json index 829842e29..ec40dfff4 100644 --- a/src/main/resources/data/minecraft/tags/damage_type/bypasses_effects.json +++ b/src/main/resources/data/minecraft/tags/damage_type/bypasses_effects.json @@ -1,10 +1,10 @@ { "replace": false, "values": [ - "superbwarfare:gunfire_bypass", - "superbwarfare:gunfire_headshot_bypass", - "superbwarfare:arrow_in_knee_bypass", - "superbwarfare:arrow_in_brain_bypass", + "superbwarfare:gunfire_absolute", + "superbwarfare:gunfire_headshot_absolute", + "superbwarfare:arrow_in_knee_absolute", + "superbwarfare:arrow_in_brain_absolute", "superbwarfare:shock" ] } \ No newline at end of file diff --git a/src/main/resources/data/minecraft/tags/damage_type/bypasses_enchantments.json b/src/main/resources/data/minecraft/tags/damage_type/bypasses_enchantments.json index 95a3cfd46..f5febb66c 100644 --- a/src/main/resources/data/minecraft/tags/damage_type/bypasses_enchantments.json +++ b/src/main/resources/data/minecraft/tags/damage_type/bypasses_enchantments.json @@ -1,10 +1,10 @@ { "replace": false, "values": [ - "superbwarfare:gunfire_bypass", - "superbwarfare:gunfire_headshot_bypass", - "superbwarfare:arrow_in_knee_bypass", - "superbwarfare:arrow_in_brain_bypass", + "superbwarfare:gunfire_absolute", + "superbwarfare:gunfire_headshot_absolute", + "superbwarfare:arrow_in_knee_absolute", + "superbwarfare:arrow_in_brain_absolute", "superbwarfare:shock", "superbwarfare:cannon_fire" ] diff --git a/src/main/resources/data/minecraft/tags/damage_type/bypasses_resistance.json b/src/main/resources/data/minecraft/tags/damage_type/bypasses_resistance.json index 95a3cfd46..f5febb66c 100644 --- a/src/main/resources/data/minecraft/tags/damage_type/bypasses_resistance.json +++ b/src/main/resources/data/minecraft/tags/damage_type/bypasses_resistance.json @@ -1,10 +1,10 @@ { "replace": false, "values": [ - "superbwarfare:gunfire_bypass", - "superbwarfare:gunfire_headshot_bypass", - "superbwarfare:arrow_in_knee_bypass", - "superbwarfare:arrow_in_brain_bypass", + "superbwarfare:gunfire_absolute", + "superbwarfare:gunfire_headshot_absolute", + "superbwarfare:arrow_in_knee_absolute", + "superbwarfare:arrow_in_brain_absolute", "superbwarfare:shock", "superbwarfare:cannon_fire" ] diff --git a/src/main/resources/data/superbwarfare/damage_type/arrow_in_brain_bypass.json b/src/main/resources/data/superbwarfare/damage_type/arrow_in_brain_absolute.json similarity index 100% rename from src/main/resources/data/superbwarfare/damage_type/arrow_in_brain_bypass.json rename to src/main/resources/data/superbwarfare/damage_type/arrow_in_brain_absolute.json diff --git a/src/main/resources/data/superbwarfare/damage_type/arrow_in_knee_bypass.json b/src/main/resources/data/superbwarfare/damage_type/arrow_in_knee_absolute.json similarity index 100% rename from src/main/resources/data/superbwarfare/damage_type/arrow_in_knee_bypass.json rename to src/main/resources/data/superbwarfare/damage_type/arrow_in_knee_absolute.json diff --git a/src/main/resources/data/superbwarfare/damage_type/gunfire_bypass.json b/src/main/resources/data/superbwarfare/damage_type/gunfire_absolute.json similarity index 100% rename from src/main/resources/data/superbwarfare/damage_type/gunfire_bypass.json rename to src/main/resources/data/superbwarfare/damage_type/gunfire_absolute.json diff --git a/src/main/resources/data/superbwarfare/damage_type/gunfire_headshot_bypass.json b/src/main/resources/data/superbwarfare/damage_type/gunfire_headshot_absolute.json similarity index 100% rename from src/main/resources/data/superbwarfare/damage_type/gunfire_headshot_bypass.json rename to src/main/resources/data/superbwarfare/damage_type/gunfire_headshot_absolute.json