Toreterror changes

Remove cheep item
fix cheep spawning
nightmare sword tooltip
apple cow sheared drop fix
This commit is contained in:
craisinlord committed 2026-07-05 18:35:25 -05:00
1 parent dc2c4cf014
commit 84bf436434
40 files changed
+411 -209

No files matched your search

@@ -1,8 +1,11 @@
package com.craisinlord.antarchy.neoforge;
import com.craisinlord.antarchy.config.AntarchySettings;
import com.craisinlord.antarchy.config.ConfigResetGuard;
import com.craisinlord.antarchy.content.network.HerculesBeetleImpactShakePayload;
import com.craisinlord.antarchy.content.network.HerculesBeetleImpactShakeSync;
import java.nio.file.Path;
import net.neoforged.fml.loading.FMLPaths;
import net.neoforged.neoforge.network.PacketDistributor;
import net.neoforged.fml.ModContainer;
import net.neoforged.fml.config.ModConfig;
@@ -12,6 +15,13 @@ public final class AntarchyConfigModuleNeoforge {
private AntarchyConfigModuleNeoforge() {}
public static void init(ModContainer modContainer) {
Path configDir = FMLPaths.CONFIGDIR.get().resolve("antarchy");
ConfigResetGuard.wipeIfNeeded(
configDir,
configDir.resolve("antarchy_mobs.toml"),
configDir.resolve("antarchy_tools.toml"),
configDir.resolve("antarchy_misc.toml")
);
modContainer.registerConfig(ModConfig.Type.COMMON, AntarchyMobsConfig.SPEC, "antarchy/antarchy_mobs.toml");
modContainer.registerConfig(ModConfig.Type.COMMON, AntarchyToolsConfig.SPEC, "antarchy/antarchy_tools.toml");
modContainer.registerConfig(ModConfig.Type.COMMON, AntarchyMiscConfig.SPEC, "antarchy/antarchy_misc.toml");
@@ -137,6 +137,10 @@ public class AntarchyNeoforge {
AntarchyNeoforgeSounds.BOMBER_WALK,
AntarchyNeoforgeSounds.BOMBER_KNOCK,
AntarchyNeoforgeSounds.BOMBER_EXPLODE,
AntarchyNeoforgeSounds.TORETERROR_IDLE,
AntarchyNeoforgeSounds.TORETERROR_HURT,
AntarchyNeoforgeSounds.TORETERROR_DEATH,
AntarchyNeoforgeSounds.TORETERROR_BOMBER_FIRE,
AntarchyNeoforgeSounds.STINKY_FLY,
AntarchyNeoforgeSounds.CREEPING_HORROR_GROWL,
AntarchyNeoforgeSounds.CREEPING_HORROR_HURT,
@@ -74,7 +74,6 @@ public final class AntarchyNeoForgeEvents {
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::onInvertedEffectExpired);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleUltimateBowDamage);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleUltimateCrossbowDamage);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleNightmareSwordDamage);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleNightmareArmorDoubleDamage);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleScorpionWhipAttackEntity);
NeoForge.EVENT_BUS.addListener(AntarchyNeoForgeEvents::handleScorpionWhipLeftClickBlock);
@@ -672,19 +671,6 @@ public final class AntarchyNeoForgeEvents {
}
static void handleNightmareSwordDamage(LivingIncomingDamageEvent event) {
net.minecraft.world.damagesource.DamageSource source = event.getSource();
if (!(source.getEntity() instanceof Player attacker)) return;
if (!(attacker.getMainHandItem().getItem() instanceof NightmareSwordItem)) return;
float maxHealth = attacker.getMaxHealth();
if (maxHealth <= 0) return;
float missingFraction = (maxHealth - attacker.getHealth()) / maxHealth;
float baseDamage = (float) AntarchySettings.nightmareSwordBaseDamage();
float scalingFactor = (float) AntarchySettings.nightmareSwordScalingFactor();
event.setAmount(baseDamage + missingFraction * scalingFactor * baseDamage);
}
static void handleNightmareArmorDoubleDamage(LivingIncomingDamageEvent event) {
net.minecraft.world.damagesource.DamageSource source = event.getSource();
@@ -144,7 +144,6 @@ public class AntarchyNeoforgeCreativeModeTabs {
event.accept(AntarchyNeoforgeItems.MOLEVORE_NOSE.get());
event.accept(AntarchyNeoforgeItems.MOLEWORM_ITEM.get());
event.accept(AntarchyNeoforgeItems.MUD_PIE.get());
event.accept(AntarchyNeoforgeItems.CHEEP.get());
event.accept(AntarchyNeoforgeItems.LUCID_EYE.get());
event.accept(AntarchyNeoforgeItems.BLOOD_CRYSTAL_SHARD.get());
event.accept(AntarchyNeoforgeItems.BLOOD_CRYSTAL_APPLE.get());
@@ -436,7 +435,7 @@ public class AntarchyNeoforgeCreativeModeTabs {
case "ultimate_bow", "ultimate_crossbow" -> 20;
// 21 - Foods
case "cloud_shark_fin_soup", "mud_pie", "cheep", "rainbow_sugar",
case "cloud_shark_fin_soup", "mud_pie", "rainbow_sugar",
"blood_crystal_apple" -> 21;
// 22 - Crafting ingredients
@@ -303,7 +303,7 @@ public final class AntarchyNeoforgeEntites {
.clientTrackingRange(10)
.build("lurking_terror"));
public static final DeferredHolder<EntityType<?>, EntityType<CheepEntity>> CHEEP = ENTITY_TYPES.register("cheep",
() -> EntityType.Builder.of(CheepEntity::new, MobCategory.WATER_CREATURE)
() -> EntityType.Builder.of(CheepEntity::new, MobCategory.WATER_AMBIENT)
.sized(1.0F, 1.2F)
.clientTrackingRange(8)
.build("cheep"));
@@ -362,12 +362,6 @@ public final class AntarchyNeoforgeItems {
public static final DeferredItem<Item> URANIUM_INGOT = ITEMS.registerSimpleItem("uranium_ingot", new Item.Properties().rarity(Rarity.UNCOMMON).fireResistant());
public static final DeferredItem<Item> TITANIUM_INGOT = ITEMS.registerSimpleItem("titanium_ingot", new Item.Properties().rarity(Rarity.UNCOMMON).fireResistant());
public static final DeferredItem<Item> MOLEVORE_NOSE = ITEMS.registerSimpleItem("molevore_nose", new Item.Properties().rarity(Rarity.RARE));
public static final DeferredItem<Item> CHEEP = ITEMS.register("cheep",
() -> new Item(new Item.Properties()
.food(new FoodProperties.Builder()
.nutrition(2)
.saturationModifier(0.2F)
.build())));
public static final DeferredItem<Item> MOLEWORM_ITEM = ITEMS.register("moleworm",
() -> new Item(new Item.Properties()
.food(new FoodProperties.Builder()
@@ -124,6 +124,10 @@ public final class AntarchyNeoforgeSounds {
public static final DeferredHolder<SoundEvent, SoundEvent> BOMBER_WALK = registerSoundEvent("bomber_walk");
public static final DeferredHolder<SoundEvent, SoundEvent> BOMBER_KNOCK = registerSoundEvent("bomber_knock");
public static final DeferredHolder<SoundEvent, SoundEvent> BOMBER_EXPLODE = registerSoundEvent("bomber_explode");
public static final DeferredHolder<SoundEvent, SoundEvent> TORETERROR_IDLE = registerSoundEvent("toreterror_idle");
public static final DeferredHolder<SoundEvent, SoundEvent> TORETERROR_HURT = registerSoundEvent("toreterror_hurt");
public static final DeferredHolder<SoundEvent, SoundEvent> TORETERROR_DEATH = registerSoundEvent("toreterror_death");
public static final DeferredHolder<SoundEvent, SoundEvent> TORETERROR_BOMBER_FIRE = registerSoundEvent("toreterror_bomber_fire");
public static final DeferredHolder<SoundEvent, SoundEvent> STINKY_FLY = registerSoundEvent("stinky_fly");
public static final DeferredHolder<SoundEvent, SoundEvent> CREEPING_HORROR_GROWL = registerSoundEvent("creeping_horror_growl");
public static final DeferredHolder<SoundEvent, SoundEvent> CREEPING_HORROR_HURT = registerSoundEvent("creeping_horror_hurt");