Hercules beetle assets, dorrie, cheep, start of toreterror sounds, etc
No files matched your search
@@ -273,8 +273,8 @@ public final class AntarchySettings {
|
||||
private static double bedBugAttackLungeHorizontalSpeed = 0.42D;
|
||||
private static double bedBugAttackLungeVerticalSpeed = 0.1D;
|
||||
private static float bedBugHealAmount = 2.0F;
|
||||
private static double jumpyBugHealth = 12.0D;
|
||||
private static double jumpyBugPounceDamage = 2.0D;
|
||||
private static double jumpyBugHealth = 100.0D;
|
||||
private static double jumpyBugPounceDamage = 12.0D;
|
||||
private static double jumpyBugLatchDamage = 1.0D;
|
||||
private static double jumpyBugCamouflageAlpha = 0.18D;
|
||||
private static double brutalflyArmor = 10.0D;
|
||||
@@ -467,6 +467,9 @@ public final class AntarchySettings {
|
||||
private static double creepingHorrorAttackDamage = 6.0D;
|
||||
private static double lurkingTerrorHealth = 15.0D;
|
||||
private static double lurkingTerrorAttackDamage = 6.0D;
|
||||
private static double cheepHealth = 8.0D;
|
||||
private static double cheepAttackDamage = 3.0D;
|
||||
private static double dorrieHealth = 60.0D;
|
||||
|
||||
private AntarchySettings() {
|
||||
}
|
||||
@@ -2390,4 +2393,10 @@ public final class AntarchySettings {
|
||||
public static void setLurkingTerrorHealth(double v) { lurkingTerrorHealth = v; }
|
||||
public static double lurkingTerrorAttackDamage() { return lurkingTerrorAttackDamage; }
|
||||
public static void setLurkingTerrorAttackDamage(double v) { lurkingTerrorAttackDamage = v; }
|
||||
public static double cheepHealth() { return cheepHealth; }
|
||||
public static void setCheepHealth(double v) { cheepHealth = v; }
|
||||
public static double cheepAttackDamage() { return cheepAttackDamage; }
|
||||
public static void setCheepAttackDamage(double v) { cheepAttackDamage = v; }
|
||||
public static double dorrieHealth() { return dorrieHealth; }
|
||||
public static void setDorrieHealth(double v) { dorrieHealth = v; }
|
||||
}
|
||||
@@ -92,6 +92,12 @@ public final class AntarchyObjects {
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<EntityType<StinkBugEntity>> STINK_BUG = (Supplier<EntityType<StinkBugEntity>>) UNBOUND;
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<EntityType<com.craisinlord.antarchy.content.entity.CheepEntity>> CHEEP = (Supplier<EntityType<com.craisinlord.antarchy.content.entity.CheepEntity>>) UNBOUND;
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<EntityType<com.craisinlord.antarchy.content.entity.DorrieEntity>> DORRIE = (Supplier<EntityType<com.craisinlord.antarchy.content.entity.DorrieEntity>>) UNBOUND;
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<net.minecraft.world.item.Item> CHEEP_ITEM = (Supplier<net.minecraft.world.item.Item>) UNBOUND;
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<Block> DUPLICATOR_LOG = (Supplier<Block>) UNBOUND;
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<Block> DUPLICATOR_SAPLING = (Supplier<Block>) UNBOUND;
|
||||
@@ -254,6 +260,8 @@ public final class AntarchyObjects {
|
||||
Supplier<EntityType<CreepingHorrorEntity>> creepingHorror,
|
||||
Supplier<EntityType<LurkingTerrorEntity>> lurkingTerror,
|
||||
Supplier<EntityType<StinkBugEntity>> stinkBug,
|
||||
Supplier<EntityType<com.craisinlord.antarchy.content.entity.CheepEntity>> cheep,
|
||||
Supplier<EntityType<com.craisinlord.antarchy.content.entity.DorrieEntity>> dorrie,
|
||||
Supplier<Block> duplicatorLog,
|
||||
Supplier<Block> duplicatorSapling,
|
||||
Supplier<Block> ductTape,
|
||||
@@ -345,6 +353,8 @@ public final class AntarchyObjects {
|
||||
CREEPING_HORROR = creepingHorror;
|
||||
LURKING_TERROR = lurkingTerror;
|
||||
STINK_BUG = stinkBug;
|
||||
CHEEP = cheep;
|
||||
DORRIE = dorrie;
|
||||
DUPLICATOR_LOG = duplicatorLog;
|
||||
DUPLICATOR_SAPLING = duplicatorSapling;
|
||||
DUCT_TAPE = ductTape;
|
||||
|
||||
@@ -101,7 +101,7 @@ public class CreepingHorrorEggBlock extends Block {
|
||||
return;
|
||||
}
|
||||
|
||||
this.hatchEggs(level, pos, state, random);
|
||||
this.hatchEggs(level, pos, state, random, state.getValue(EGGS));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -141,13 +141,12 @@ public class CreepingHorrorEggBlock extends Block {
|
||||
for (int dz = -radius; dz <= radius; dz++) {
|
||||
if (dx == 0 && dy == 0 && dz == 0) continue;
|
||||
mutable.set(origin.getX() + dx, origin.getY() + dy, origin.getZ() + dz);
|
||||
if (level.random.nextFloat() >= PANIC_HATCH_CHANCE) continue;
|
||||
BlockState nearby = level.getBlockState(mutable);
|
||||
BlockPos immutable = mutable.immutable();
|
||||
if (nearby.getBlock() instanceof CreepingHorrorEggBlock b) {
|
||||
b.hatchEggs(level, immutable, nearby, level.random);
|
||||
b.hatchPanickedEggs(level, immutable, nearby, level.random);
|
||||
} else if (nearby.getBlock() instanceof LurkingTerrorEggBlock b) {
|
||||
b.hatchEggs(level, immutable, nearby, level.random);
|
||||
b.hatchPanickedEggs(level, immutable, nearby, level.random);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -176,11 +175,24 @@ public class CreepingHorrorEggBlock extends Block {
|
||||
return true;
|
||||
}
|
||||
|
||||
void hatchEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random) {
|
||||
void hatchPanickedEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random) {
|
||||
int hatchedEggs = rollPanickedEggs(state.getValue(EGGS), random);
|
||||
if (hatchedEggs <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.hatchEggs(level, pos, state, random, hatchedEggs);
|
||||
}
|
||||
|
||||
void hatchEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random, int eggsToHatch) {
|
||||
if (eggsToHatch >= state.getValue(EGGS)) {
|
||||
level.removeBlock(pos, false);
|
||||
} else {
|
||||
level.setBlock(pos, state.setValue(EGGS, state.getValue(EGGS) - eggsToHatch), 2);
|
||||
}
|
||||
level.playSound(null, pos, SoundEvents.TURTLE_EGG_HATCH, SoundSource.BLOCKS, 0.75F, 0.95F + random.nextFloat() * 0.1F);
|
||||
|
||||
for (int i = 0; i < state.getValue(EGGS); i++) {
|
||||
for (int i = 0; i < eggsToHatch; i++) {
|
||||
CreepingHorrorEntity entity = AntarchyObjects.CREEPING_HORROR.get().create(level);
|
||||
if (entity == null) {
|
||||
continue;
|
||||
@@ -192,6 +204,16 @@ public class CreepingHorrorEggBlock extends Block {
|
||||
}
|
||||
}
|
||||
|
||||
private static int rollPanickedEggs(int eggs, RandomSource random) {
|
||||
int hatchedEggs = 0;
|
||||
for (int i = 0; i < eggs; i++) {
|
||||
if (random.nextFloat() < PANIC_HATCH_CHANCE) {
|
||||
hatchedEggs++;
|
||||
}
|
||||
}
|
||||
return hatchedEggs;
|
||||
}
|
||||
|
||||
private void decreaseEggs(Level level, BlockPos pos, BlockState state) {
|
||||
int eggs = state.getValue(EGGS);
|
||||
if (eggs <= 1) {
|
||||
|
||||
@@ -101,7 +101,7 @@ public class LurkingTerrorEggBlock extends Block {
|
||||
return;
|
||||
}
|
||||
|
||||
this.hatchEggs(level, pos, state, random);
|
||||
this.hatchEggs(level, pos, state, random, state.getValue(EGGS));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -141,13 +141,12 @@ public class LurkingTerrorEggBlock extends Block {
|
||||
for (int dz = -radius; dz <= radius; dz++) {
|
||||
if (dx == 0 && dy == 0 && dz == 0) continue;
|
||||
mutable.set(origin.getX() + dx, origin.getY() + dy, origin.getZ() + dz);
|
||||
if (level.random.nextFloat() >= PANIC_HATCH_CHANCE) continue;
|
||||
BlockState nearby = level.getBlockState(mutable);
|
||||
BlockPos immutable = mutable.immutable();
|
||||
if (nearby.getBlock() instanceof LurkingTerrorEggBlock b) {
|
||||
b.hatchEggs(level, immutable, nearby, level.random);
|
||||
b.hatchPanickedEggs(level, immutable, nearby, level.random);
|
||||
} else if (nearby.getBlock() instanceof CreepingHorrorEggBlock b) {
|
||||
b.hatchEggs(level, immutable, nearby, level.random);
|
||||
b.hatchPanickedEggs(level, immutable, nearby, level.random);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -176,11 +175,24 @@ public class LurkingTerrorEggBlock extends Block {
|
||||
return true;
|
||||
}
|
||||
|
||||
void hatchEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random) {
|
||||
void hatchPanickedEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random) {
|
||||
int hatchedEggs = rollPanickedEggs(state.getValue(EGGS), random);
|
||||
if (hatchedEggs <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.hatchEggs(level, pos, state, random, hatchedEggs);
|
||||
}
|
||||
|
||||
void hatchEggs(ServerLevel level, BlockPos pos, BlockState state, RandomSource random, int eggsToHatch) {
|
||||
if (eggsToHatch >= state.getValue(EGGS)) {
|
||||
level.removeBlock(pos, false);
|
||||
} else {
|
||||
level.setBlock(pos, state.setValue(EGGS, state.getValue(EGGS) - eggsToHatch), 2);
|
||||
}
|
||||
level.playSound(null, pos, SoundEvents.TURTLE_EGG_HATCH, SoundSource.BLOCKS, 0.75F, 0.95F + random.nextFloat() * 0.1F);
|
||||
|
||||
for (int i = 0; i < state.getValue(EGGS); i++) {
|
||||
for (int i = 0; i < eggsToHatch; i++) {
|
||||
LurkingTerrorEntity entity = AntarchyObjects.LURKING_TERROR.get().create(level);
|
||||
if (entity == null) {
|
||||
continue;
|
||||
@@ -192,6 +204,16 @@ public class LurkingTerrorEggBlock extends Block {
|
||||
}
|
||||
}
|
||||
|
||||
private static int rollPanickedEggs(int eggs, RandomSource random) {
|
||||
int hatchedEggs = 0;
|
||||
for (int i = 0; i < eggs; i++) {
|
||||
if (random.nextFloat() < PANIC_HATCH_CHANCE) {
|
||||
hatchedEggs++;
|
||||
}
|
||||
}
|
||||
return hatchedEggs;
|
||||
}
|
||||
|
||||
private void decreaseEggs(Level level, BlockPos pos, BlockState state) {
|
||||
int eggs = state.getValue(EGGS);
|
||||
if (eggs <= 1) {
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.craisinlord.antarchy.content.client.model;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import com.craisinlord.antarchy.content.entity.CheepEntity;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import software.bernie.geckolib.model.GeoModel;
|
||||
|
||||
public class CheepModel extends GeoModel<CheepEntity> {
|
||||
@Override
|
||||
public ResourceLocation getModelResource(CheepEntity animatable) {
|
||||
return ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "geo/cheep.geo.json");
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceLocation getTextureResource(CheepEntity animatable) {
|
||||
return ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "textures/entity/cheep/cheep_magenta.png");
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceLocation getAnimationResource(CheepEntity animatable) {
|
||||
return ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "animations/cheep.animation.json");
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.craisinlord.antarchy.content.client.model;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import software.bernie.geckolib.model.GeoModel;
|
||||
|
||||
public class DorrieModel extends GeoModel<DorrieEntity> {
|
||||
private static final ResourceLocation TEXTURE =
|
||||
ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "textures/entity/dorrie.png");
|
||||
private static final ResourceLocation TEXTURE_SADDLED =
|
||||
ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "textures/entity/dorrie_saddle.png");
|
||||
|
||||
@Override
|
||||
public ResourceLocation getModelResource(DorrieEntity animatable) {
|
||||
return ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "geo/dorrie.geo.json");
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceLocation getTextureResource(DorrieEntity animatable) {
|
||||
return animatable.hasSaddle() ? TEXTURE_SADDLED : TEXTURE;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceLocation getAnimationResource(DorrieEntity animatable) {
|
||||
return ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "animations/dorrie.animation.json");
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package com.craisinlord.antarchy.content.client.renderer;
|
||||
|
||||
import com.craisinlord.antarchy.content.client.model.CheepModel;
|
||||
import com.craisinlord.antarchy.content.entity.CheepEntity;
|
||||
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
||||
import software.bernie.geckolib.renderer.GeoEntityRenderer;
|
||||
|
||||
public class CheepRenderer extends GeoEntityRenderer<CheepEntity> {
|
||||
public CheepRenderer(EntityRendererProvider.Context context) {
|
||||
super(context, new CheepModel());
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package com.craisinlord.antarchy.content.client.renderer;
|
||||
|
||||
import com.craisinlord.antarchy.content.client.model.DorrieModel;
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
||||
import software.bernie.geckolib.renderer.GeoEntityRenderer;
|
||||
|
||||
public class DorrieRenderer extends GeoEntityRenderer<DorrieEntity> {
|
||||
public DorrieRenderer(EntityRendererProvider.Context context) {
|
||||
super(context, new DorrieModel());
|
||||
}
|
||||
}
|
||||
@@ -17,7 +17,7 @@ import software.bernie.geckolib.util.Color;
|
||||
public class JumpyBugRenderer extends GeoEntityRenderer<JumpyBugEntity> {
|
||||
public JumpyBugRenderer(EntityRendererProvider.Context context) {
|
||||
super(context, new JumpyBugModel());
|
||||
this.shadowRadius = 3.0F;
|
||||
this.shadowRadius = 6.0F;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -34,7 +34,7 @@ public class JumpyBugRenderer extends GeoEntityRenderer<JumpyBugEntity> {
|
||||
@Override
|
||||
public void preRender(PoseStack poseStack, JumpyBugEntity animatable, BakedGeoModel model, @Nullable MultiBufferSource bufferSource, @Nullable VertexConsumer buffer, boolean isReRender, float partialTick, int packedLight, int packedOverlay, int colour) {
|
||||
super.preRender(poseStack, animatable, model, bufferSource, buffer, isReRender, partialTick, packedLight, packedOverlay, colour);
|
||||
this.shadowRadius = animatable.isCamouflaged() ? 1.0F : 3.0F;
|
||||
this.shadowRadius = animatable.isCamouflaged() ? 1.0F : 6.0F;
|
||||
|
||||
if (animatable.isClingingToCeiling()) {
|
||||
poseStack.translate(0.0F, animatable.getBbHeight() + 0.05F, 0.0F);
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
package com.craisinlord.antarchy.content.client.screen;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import com.craisinlord.antarchy.content.menu.DorrieMenu;
|
||||
import com.mojang.blaze3d.systems.RenderSystem;
|
||||
import net.minecraft.client.gui.GuiGraphics;
|
||||
import net.minecraft.client.gui.screens.inventory.AbstractContainerScreen;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.world.entity.player.Inventory;
|
||||
|
||||
public class DorrieScreen extends AbstractContainerScreen<DorrieMenu> {
|
||||
// A 176 × 130 texture: saddle slot area at top, player inventory below.
|
||||
// Art file: assets/antarchy/textures/gui/container/dorrie.png
|
||||
private static final ResourceLocation TEXTURE =
|
||||
ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "textures/gui/container/dorrie.png");
|
||||
|
||||
public static final int TEXTURE_WIDTH = 176;
|
||||
public static final int TEXTURE_HEIGHT = 130;
|
||||
|
||||
public DorrieScreen(DorrieMenu menu, Inventory playerInventory, Component title) {
|
||||
super(menu, playerInventory, title);
|
||||
this.imageWidth = TEXTURE_WIDTH;
|
||||
this.imageHeight = TEXTURE_HEIGHT;
|
||||
this.inventoryLabelY = this.imageHeight - 94;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void renderBg(GuiGraphics guiGraphics, float partialTick, int mouseX, int mouseY) {
|
||||
RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
guiGraphics.blit(TEXTURE, this.leftPos, this.topPos, 0, 0, this.imageWidth, this.imageHeight);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) {
|
||||
this.renderBackground(guiGraphics, mouseX, mouseY, partialTick);
|
||||
super.render(guiGraphics, mouseX, mouseY, partialTick);
|
||||
this.renderTooltip(guiGraphics, mouseX, mouseY);
|
||||
}
|
||||
}
|
||||
@@ -67,7 +67,7 @@ public class BomberEntity extends Monster implements GeoEntity {
|
||||
private static final int DEFAULT_FUSE_TICKS = 120;
|
||||
private static final int EXPLODE_ANIM_START_TICKS = 25;
|
||||
private static final int FLASH_INTERVAL_TICKS = 5;
|
||||
private static final double KNOCKBACK_MULTIPLIER = 3.0D;
|
||||
private static final double KNOCKBACK_MULTIPLIER = 5.5D;
|
||||
private static final float EXPLOSION_RADIUS_MULTIPLIER = 0.45F;
|
||||
|
||||
private static final RawAnimation IDLE_ANIM = RawAnimation.begin().thenLoop("idle");
|
||||
@@ -153,6 +153,7 @@ public class BomberEntity extends Monster implements GeoEntity {
|
||||
this.primeFuse();
|
||||
}
|
||||
|
||||
this.playSound(AntarchySoundEvents.BOMBER_KNOCK.get(), 1.0F, 0.9F + this.random.nextFloat() * 0.2F);
|
||||
this.pushAwayFrom(source);
|
||||
return false;
|
||||
}
|
||||
@@ -259,7 +260,7 @@ public class BomberEntity extends Monster implements GeoEntity {
|
||||
return PlayState.STOP;
|
||||
}
|
||||
|
||||
private void primeFuse() {
|
||||
public void primeFuse() {
|
||||
if (this.detonating) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,95 @@
|
||||
package com.craisinlord.antarchy.content.entity;
|
||||
|
||||
import com.craisinlord.antarchy.config.AntarchySettings;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.sounds.SoundEvent;
|
||||
import net.minecraft.sounds.SoundEvents;
|
||||
import net.minecraft.world.damagesource.DamageSource;
|
||||
import net.minecraft.world.entity.EntityType;
|
||||
import net.minecraft.world.entity.ai.attributes.AttributeSupplier;
|
||||
import net.minecraft.world.entity.ai.attributes.Attributes;
|
||||
import net.minecraft.world.entity.ai.goal.MeleeAttackGoal;
|
||||
import net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal;
|
||||
import net.minecraft.world.entity.animal.AbstractFish;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.item.Items;
|
||||
import net.minecraft.world.level.Level;
|
||||
import software.bernie.geckolib.animatable.GeoEntity;
|
||||
import software.bernie.geckolib.animatable.instance.AnimatableInstanceCache;
|
||||
import software.bernie.geckolib.animation.AnimatableManager;
|
||||
import software.bernie.geckolib.animation.AnimationController;
|
||||
import software.bernie.geckolib.animation.AnimationState;
|
||||
import software.bernie.geckolib.animation.PlayState;
|
||||
import software.bernie.geckolib.animation.RawAnimation;
|
||||
import software.bernie.geckolib.util.GeckoLibUtil;
|
||||
|
||||
public class CheepEntity extends AbstractFish implements GeoEntity {
|
||||
private static final RawAnimation IDLE_ANIM = RawAnimation.begin().thenLoop("idle");
|
||||
private static final RawAnimation SWIM_ANIM = RawAnimation.begin().thenLoop("swim");
|
||||
private static final RawAnimation ATTACK_ANIM = RawAnimation.begin().thenLoop("attack");
|
||||
|
||||
private final AnimatableInstanceCache geoCache = GeckoLibUtil.createInstanceCache(this);
|
||||
|
||||
public CheepEntity(EntityType<? extends CheepEntity> entityType, Level level) {
|
||||
super(entityType, level);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void registerGoals() {
|
||||
super.registerGoals();
|
||||
this.goalSelector.addGoal(1, new MeleeAttackGoal(this, 1.2D, true));
|
||||
this.targetSelector.addGoal(1, new HurtByTargetGoal(this));
|
||||
}
|
||||
|
||||
public static AttributeSupplier.Builder createAttributes() {
|
||||
return AbstractFish.createAttributes()
|
||||
.add(Attributes.MAX_HEALTH, AntarchySettings.cheepHealth())
|
||||
.add(Attributes.ATTACK_DAMAGE, AntarchySettings.cheepAttackDamage())
|
||||
.add(Attributes.MOVEMENT_SPEED, 0.5D);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getBucketItemStack() {
|
||||
return new ItemStack(Items.WATER_BUCKET);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getAmbientSound() {
|
||||
return SoundEvents.COD_AMBIENT;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getDeathSound() {
|
||||
return SoundEvents.COD_DEATH;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getHurtSound(DamageSource source) {
|
||||
return SoundEvents.COD_HURT;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getFlopSound() {
|
||||
return SoundEvents.COD_FLOP;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerControllers(AnimatableManager.ControllerRegistrar controllers) {
|
||||
controllers.add(new AnimationController<>(this, "main_controller", 2, this::mainAnimController));
|
||||
}
|
||||
|
||||
private PlayState mainAnimController(AnimationState<CheepEntity> state) {
|
||||
if (this.isAggressive()) {
|
||||
return state.setAndContinue(ATTACK_ANIM);
|
||||
}
|
||||
if (state.isMoving()) {
|
||||
return state.setAndContinue(SWIM_ANIM);
|
||||
}
|
||||
return state.setAndContinue(IDLE_ANIM);
|
||||
}
|
||||
|
||||
@Override
|
||||
public AnimatableInstanceCache getAnimatableInstanceCache() {
|
||||
return this.geoCache;
|
||||
}
|
||||
}
|
||||
@@ -11,6 +11,7 @@ import net.minecraft.network.syncher.EntityDataAccessor;
|
||||
import net.minecraft.network.syncher.EntityDataSerializers;
|
||||
import net.minecraft.network.syncher.SynchedEntityData;
|
||||
import net.minecraft.world.entity.EntityType;
|
||||
import net.minecraft.world.entity.LivingEntity;
|
||||
import net.minecraft.world.entity.Mob;
|
||||
import net.minecraft.world.entity.MobSpawnType;
|
||||
import net.minecraft.world.entity.ai.attributes.AttributeSupplier;
|
||||
@@ -27,6 +28,7 @@ import net.minecraft.world.entity.player.Player;
|
||||
import net.minecraft.world.level.Level;
|
||||
import net.minecraft.world.level.ServerLevelAccessor;
|
||||
import net.minecraft.world.level.block.Blocks;
|
||||
import net.minecraft.world.phys.Vec3;
|
||||
import net.minecraft.world.level.block.state.BlockState;
|
||||
import software.bernie.geckolib.animatable.GeoEntity;
|
||||
import software.bernie.geckolib.animatable.instance.AnimatableInstanceCache;
|
||||
@@ -169,9 +171,28 @@ public class CreepingHorrorEntity extends Monster implements GeoEntity {
|
||||
@Override
|
||||
public void tick() {
|
||||
super.tick();
|
||||
if (!this.level().isClientSide()) {
|
||||
this.entityData.set(CLIMBING, this.horizontalCollision);
|
||||
}
|
||||
if (attackAnimTicks > 0) attackAnimTicks--;
|
||||
if (this.level().isClientSide()) return;
|
||||
|
||||
boolean climbing = this.horizontalCollision;
|
||||
this.entityData.set(CLIMBING, climbing);
|
||||
|
||||
if (climbing && this.getTarget() != null) {
|
||||
LivingEntity target = this.getTarget();
|
||||
Vec3 toTarget = target.position().subtract(this.position());
|
||||
double hDist = Math.sqrt(toTarget.x * toTarget.x + toTarget.z * toTarget.z);
|
||||
double speed = this.getAttributeValue(Attributes.MOVEMENT_SPEED) * 2.8D;
|
||||
if (hDist > 0.01D) {
|
||||
this.setDeltaMovement(
|
||||
(toTarget.x / hDist) * speed,
|
||||
0.22D,
|
||||
(toTarget.z / hDist) * speed
|
||||
);
|
||||
} else {
|
||||
Vec3 mov = this.getDeltaMovement();
|
||||
this.setDeltaMovement(mov.x, 0.22D, mov.z);
|
||||
}
|
||||
this.getNavigation().stop();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,465 @@
|
||||
package com.craisinlord.antarchy.content.entity;
|
||||
|
||||
import com.craisinlord.antarchy.content.AntarchyObjects;
|
||||
import com.craisinlord.antarchy.config.AntarchySettings;
|
||||
import com.craisinlord.antarchy.content.item.CheepOnAStickItem;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.syncher.EntityDataAccessor;
|
||||
import net.minecraft.network.syncher.EntityDataSerializers;
|
||||
import net.minecraft.network.syncher.SynchedEntityData;
|
||||
import net.minecraft.core.registries.BuiltInRegistries;
|
||||
import net.minecraft.server.level.ServerLevel;
|
||||
import net.minecraft.sounds.SoundEvent;
|
||||
import net.minecraft.sounds.SoundEvents;
|
||||
import net.minecraft.world.InteractionHand;
|
||||
import net.minecraft.world.InteractionResult;
|
||||
import net.minecraft.world.damagesource.DamageSource;
|
||||
import net.minecraft.world.entity.AgeableMob;
|
||||
import net.minecraft.world.entity.Entity;
|
||||
import net.minecraft.world.entity.EntityType;
|
||||
import net.minecraft.world.entity.Entity.MoveFunction;
|
||||
import net.minecraft.world.entity.LivingEntity;
|
||||
import net.minecraft.world.entity.Mob;
|
||||
import net.minecraft.world.entity.ai.attributes.AttributeSupplier;
|
||||
import net.minecraft.world.entity.ai.attributes.Attributes;
|
||||
import net.minecraft.world.entity.ai.control.SmoothSwimmingLookControl;
|
||||
import net.minecraft.world.entity.ai.control.SmoothSwimmingMoveControl;
|
||||
import net.minecraft.world.entity.ai.goal.BreathAirGoal;
|
||||
import net.minecraft.world.entity.ai.goal.FloatGoal;
|
||||
import net.minecraft.world.entity.ai.goal.Goal;
|
||||
import net.minecraft.world.entity.ai.goal.LookAtPlayerGoal;
|
||||
import net.minecraft.world.entity.ai.goal.RandomLookAroundGoal;
|
||||
import net.minecraft.world.entity.ai.goal.RandomSwimmingGoal;
|
||||
import net.minecraft.world.entity.ai.goal.TryFindWaterGoal;
|
||||
import java.util.EnumSet;
|
||||
import java.util.List;
|
||||
import net.minecraft.world.entity.ai.navigation.PathNavigation;
|
||||
import net.minecraft.world.entity.ai.navigation.WaterBoundPathNavigation;
|
||||
import net.minecraft.world.entity.animal.Animal;
|
||||
import net.minecraft.world.entity.player.Player;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.item.Items;
|
||||
import net.minecraft.world.level.Level;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.world.phys.Vec3;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import software.bernie.geckolib.animatable.GeoEntity;
|
||||
import software.bernie.geckolib.animatable.instance.AnimatableInstanceCache;
|
||||
import software.bernie.geckolib.animation.AnimatableManager;
|
||||
import software.bernie.geckolib.animation.AnimationController;
|
||||
import software.bernie.geckolib.animation.AnimationState;
|
||||
import software.bernie.geckolib.animation.PlayState;
|
||||
import software.bernie.geckolib.animation.RawAnimation;
|
||||
import software.bernie.geckolib.util.GeckoLibUtil;
|
||||
|
||||
public class DorrieEntity extends Animal implements GeoEntity {
|
||||
private static final ResourceLocation CHEEP_ITEM_ID = ResourceLocation.fromNamespaceAndPath("antarchy", "cheep");
|
||||
private static final EntityDataAccessor<Boolean> HAS_SADDLE =
|
||||
SynchedEntityData.defineId(DorrieEntity.class, EntityDataSerializers.BOOLEAN);
|
||||
private static final EntityDataAccessor<Boolean> TAMED =
|
||||
SynchedEntityData.defineId(DorrieEntity.class, EntityDataSerializers.BOOLEAN);
|
||||
private static final EntityDataAccessor<Integer> JUMP_CHARGE =
|
||||
SynchedEntityData.defineId(DorrieEntity.class, EntityDataSerializers.INT);
|
||||
|
||||
private static final int MAX_CHARGE_TICKS = 40;
|
||||
private static final float BASE_SPEED = 0.6F;
|
||||
private static final float BOOSTED_SPEED = 1.3F;
|
||||
|
||||
private static final RawAnimation IDLE_ANIM = RawAnimation.begin().thenLoop("idle");
|
||||
private static final RawAnimation SWIM_ANIM = RawAnimation.begin().thenLoop("swim");
|
||||
private static final RawAnimation JUMP_START_ANIM = RawAnimation.begin().thenPlay("jump_1");
|
||||
private static final RawAnimation JUMP_LOOP_ANIM = RawAnimation.begin().thenLoop("jump_2");
|
||||
private static final RawAnimation JUMP_LAND_ANIM = RawAnimation.begin().thenPlay("jump_3");
|
||||
|
||||
private final AnimatableInstanceCache geoCache = GeckoLibUtil.createInstanceCache(this);
|
||||
|
||||
private int chargeTicks = 0;
|
||||
private boolean isCharging = false;
|
||||
private boolean isLeaping = false;
|
||||
private boolean wasInAir = false;
|
||||
private int landAnimTicks = 0;
|
||||
private boolean isPressingJump = false;
|
||||
|
||||
public DorrieEntity(EntityType<? extends DorrieEntity> entityType, Level level) {
|
||||
super(entityType, level);
|
||||
this.moveControl = new SmoothSwimmingMoveControl(this, 85, 10, BASE_SPEED, 1.0F, true);
|
||||
this.lookControl = new SmoothSwimmingLookControl(this, 10);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void defineSynchedData(SynchedEntityData.Builder builder) {
|
||||
super.defineSynchedData(builder);
|
||||
builder.define(HAS_SADDLE, false);
|
||||
builder.define(TAMED, false);
|
||||
builder.define(JUMP_CHARGE, 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected PathNavigation createNavigation(Level level) {
|
||||
return new WaterBoundPathNavigation(this, level);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void registerGoals() {
|
||||
this.goalSelector.addGoal(0, new FloatGoal(this));
|
||||
this.goalSelector.addGoal(1, new BreathAirGoal(this));
|
||||
this.goalSelector.addGoal(2, new TryFindWaterGoal(this));
|
||||
this.goalSelector.addGoal(3, new HuntCheepGoal(this));
|
||||
this.goalSelector.addGoal(4, new RandomSwimmingGoal(this, 1.0D, 10));
|
||||
this.goalSelector.addGoal(5, new LookAtPlayerGoal(this, Player.class, 6.0F));
|
||||
this.goalSelector.addGoal(6, new RandomLookAroundGoal(this));
|
||||
}
|
||||
|
||||
public static AttributeSupplier.Builder createAttributes() {
|
||||
return Mob.createMobAttributes()
|
||||
.add(Attributes.MAX_HEALTH, AntarchySettings.dorrieHealth())
|
||||
.add(Attributes.MOVEMENT_SPEED, BASE_SPEED)
|
||||
.add(Attributes.FOLLOW_RANGE, 16.0D)
|
||||
.add(Attributes.ATTACK_DAMAGE, 4.0D);
|
||||
}
|
||||
|
||||
|
||||
public boolean hasSaddle() {
|
||||
return this.entityData.get(HAS_SADDLE);
|
||||
}
|
||||
|
||||
public void setSaddle(boolean saddle) {
|
||||
this.entityData.set(HAS_SADDLE, saddle);
|
||||
}
|
||||
|
||||
public boolean isTamed() {
|
||||
return this.entityData.get(TAMED);
|
||||
}
|
||||
|
||||
public void setTamed(boolean tamed) {
|
||||
this.entityData.set(TAMED, tamed);
|
||||
}
|
||||
|
||||
public int getJumpCharge() {
|
||||
return this.entityData.get(JUMP_CHARGE);
|
||||
}
|
||||
|
||||
private void setJumpCharge(int charge) {
|
||||
this.entityData.set(JUMP_CHARGE, charge);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void addAdditionalSaveData(CompoundTag tag) {
|
||||
super.addAdditionalSaveData(tag);
|
||||
tag.putBoolean("Tamed", this.isTamed());
|
||||
tag.putBoolean("HasSaddle", this.hasSaddle());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readAdditionalSaveData(CompoundTag tag) {
|
||||
super.readAdditionalSaveData(tag);
|
||||
this.setTamed(tag.getBoolean("Tamed"));
|
||||
this.setSaddle(tag.getBoolean("HasSaddle"));
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public InteractionResult mobInteract(Player player, InteractionHand hand) {
|
||||
ItemStack stack = player.getItemInHand(hand);
|
||||
|
||||
if (!this.isTamed()) {
|
||||
if (!this.level().isClientSide && this.isCheepItem(stack)) {
|
||||
if (!player.getAbilities().instabuild) stack.shrink(1);
|
||||
if (this.random.nextInt(3) == 0) {
|
||||
this.setTamed(true);
|
||||
this.playSound(SoundEvents.HORSE_BREATHE, 0.5F, 1.0F);
|
||||
} else {
|
||||
this.playSound(SoundEvents.DOLPHIN_HURT, 0.5F, 1.0F);
|
||||
}
|
||||
return InteractionResult.sidedSuccess(this.level().isClientSide);
|
||||
}
|
||||
return super.mobInteract(player, hand);
|
||||
}
|
||||
|
||||
// Remove saddle with empty hand
|
||||
if (this.hasSaddle() && stack.isEmpty() && !player.isPassengerOfSameVehicle(this)) {
|
||||
if (!this.level().isClientSide) {
|
||||
this.setSaddle(false);
|
||||
this.spawnAtLocation(new ItemStack(Items.SADDLE));
|
||||
this.playSound(SoundEvents.HORSE_SADDLE, 1.0F, 1.0F);
|
||||
}
|
||||
return InteractionResult.sidedSuccess(this.level().isClientSide);
|
||||
}
|
||||
|
||||
// Apply saddle
|
||||
if (!this.hasSaddle() && stack.is(Items.SADDLE)) {
|
||||
if (!this.level().isClientSide) {
|
||||
this.setSaddle(true);
|
||||
if (!player.getAbilities().instabuild) stack.shrink(1);
|
||||
this.playSound(SoundEvents.HORSE_SADDLE, 1.0F, 1.0F);
|
||||
}
|
||||
return InteractionResult.sidedSuccess(this.level().isClientSide);
|
||||
}
|
||||
|
||||
// Mount
|
||||
if (this.hasSaddle() && !player.isPassengerOfSameVehicle(this)) {
|
||||
if (!this.level().isClientSide) player.startRiding(this);
|
||||
return InteractionResult.sidedSuccess(this.level().isClientSide);
|
||||
}
|
||||
|
||||
return super.mobInteract(player, hand);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isFood(ItemStack stack) {
|
||||
return this.isCheepItem(stack);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public LivingEntity getControllingPassenger() {
|
||||
if (!this.isTamed() || !this.hasSaddle()) return null;
|
||||
Entity passenger = this.getFirstPassenger();
|
||||
if (passenger instanceof Player player) return player;
|
||||
return null;
|
||||
}
|
||||
|
||||
private boolean riderHasCheepStick(Player player) {
|
||||
return player.getMainHandItem().getItem() instanceof CheepOnAStickItem
|
||||
|| player.getOffhandItem().getItem() instanceof CheepOnAStickItem;
|
||||
}
|
||||
|
||||
private ItemStack getCheepStick(Player player) {
|
||||
if (player.getMainHandItem().getItem() instanceof CheepOnAStickItem) return player.getMainHandItem();
|
||||
if (player.getOffhandItem().getItem() instanceof CheepOnAStickItem) return player.getOffhandItem();
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Vec3 getRiddenInput(Player player, Vec3 travelVector) {
|
||||
if (!riderHasCheepStick(player)) return Vec3.ZERO;
|
||||
float forward = player.zza > 0 ? player.zza : player.zza / 4.0F;
|
||||
float strafe = player.xxa * 0.5F;
|
||||
return new Vec3(strafe, travelVector.y, forward);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getRiddenSpeed(Player player) {
|
||||
float speed = BASE_SPEED;
|
||||
if (riderHasCheepStick(player)) {
|
||||
speed = BOOSTED_SPEED;
|
||||
if (!this.level().isClientSide) {
|
||||
ItemStack stick = getCheepStick(player);
|
||||
if (!stick.isEmpty() && this.tickCount % 10 == 0) {
|
||||
stick.hurtAndBreak(1, player,
|
||||
player.getMainHandItem().getItem() instanceof CheepOnAStickItem
|
||||
? net.minecraft.world.entity.EquipmentSlot.MAINHAND
|
||||
: net.minecraft.world.entity.EquipmentSlot.OFFHAND);
|
||||
}
|
||||
}
|
||||
}
|
||||
return (float) this.getAttributeValue(Attributes.MOVEMENT_SPEED) * speed;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
super.tick();
|
||||
|
||||
if (!this.level().isClientSide) {
|
||||
LivingEntity passenger = this.getControllingPassenger();
|
||||
|
||||
if (passenger != null && isPressingJump) {
|
||||
Vec3 mov = this.getDeltaMovement();
|
||||
double boost = this.isInWater() ? 0.1D : 0.04D;
|
||||
this.setDeltaMovement(mov.x, Math.min(mov.y + boost, 0.5D), mov.z);
|
||||
this.hasImpulse = true;
|
||||
}
|
||||
|
||||
if (passenger instanceof Player && isCharging) {
|
||||
chargeTicks = Math.min(chargeTicks + 1, MAX_CHARGE_TICKS);
|
||||
setJumpCharge((int) ((chargeTicks / (float) MAX_CHARGE_TICKS) * 100));
|
||||
}
|
||||
}
|
||||
|
||||
if (landAnimTicks > 0) landAnimTicks--;
|
||||
|
||||
boolean inAirNow = !this.onGround() && !this.isInWater() && !this.isInLava();
|
||||
if (wasInAir && !inAirNow && isLeaping) {
|
||||
isLeaping = false;
|
||||
landAnimTicks = 12;
|
||||
}
|
||||
wasInAir = inAirNow;
|
||||
}
|
||||
|
||||
|
||||
/** Called when the rider presses/releases space (up movement). */
|
||||
public void setPressingJump(boolean pressing) {
|
||||
this.isPressingJump = pressing;
|
||||
}
|
||||
|
||||
/** Called when the rider presses left-control (charge start). */
|
||||
public void startJumpCharge() {
|
||||
if (!this.level().isClientSide) {
|
||||
isCharging = true;
|
||||
}
|
||||
}
|
||||
|
||||
/** Called when the rider releases left-control (charge release). */
|
||||
public void releaseJump() {
|
||||
if (!this.level().isClientSide && isCharging) {
|
||||
float power = chargeTicks / (float) MAX_CHARGE_TICKS;
|
||||
if (power > 0.05F) {
|
||||
double horizontal = 0.8D + power * 1.4D;
|
||||
double vertical = 0.4D + power * 0.8D;
|
||||
Vec3 look = this.getLookAngle();
|
||||
Vec3 current = this.getDeltaMovement();
|
||||
this.setDeltaMovement(
|
||||
look.x * horizontal * 0.7D + current.x * 0.3D,
|
||||
vertical,
|
||||
look.z * horizontal * 0.7D + current.z * 0.3D
|
||||
);
|
||||
this.hasImpulse = true;
|
||||
isLeaping = true;
|
||||
}
|
||||
isCharging = false;
|
||||
chargeTicks = 0;
|
||||
setJumpCharge(0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void positionRider(Entity passenger, MoveFunction moveFunction) {
|
||||
if (this.hasPassenger(passenger)) {
|
||||
moveFunction.accept(passenger,
|
||||
this.getX(),
|
||||
this.getY() + this.getPassengersRidingOffset() + passenger.getBbHeight() * 0.5D,
|
||||
this.getZ());
|
||||
}
|
||||
}
|
||||
|
||||
public double getPassengersRidingOffset() {
|
||||
return 0.6D;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void dropEquipment() {
|
||||
super.dropEquipment();
|
||||
if (this.hasSaddle()) {
|
||||
this.spawnAtLocation(new ItemStack(Items.SADDLE));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public DorrieEntity getBreedOffspring(ServerLevel level, AgeableMob mob) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean canBeLeashed() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getAmbientSound() {
|
||||
return SoundEvents.DOLPHIN_AMBIENT;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getHurtSound(DamageSource source) {
|
||||
return SoundEvents.DOLPHIN_HURT;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getDeathSound() {
|
||||
return SoundEvents.DOLPHIN_DEATH;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SoundEvent getSwimSound() {
|
||||
return SoundEvents.DOLPHIN_SWIM;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void registerControllers(AnimatableManager.ControllerRegistrar controllers) {
|
||||
controllers.add(new AnimationController<>(this, "main_controller", 2, this::mainAnimController));
|
||||
}
|
||||
|
||||
private PlayState mainAnimController(AnimationState<DorrieEntity> state) {
|
||||
if (landAnimTicks > 0) return state.setAndContinue(JUMP_LAND_ANIM);
|
||||
if (isLeaping) {
|
||||
return state.setAndContinue(wasInAir ? JUMP_LOOP_ANIM : JUMP_START_ANIM);
|
||||
}
|
||||
return state.setAndContinue(state.isMoving() ? SWIM_ANIM : IDLE_ANIM);
|
||||
}
|
||||
|
||||
@Override
|
||||
public AnimatableInstanceCache getAnimatableInstanceCache() {
|
||||
return this.geoCache;
|
||||
}
|
||||
|
||||
private boolean isCheepItem(ItemStack stack) {
|
||||
return !stack.isEmpty() && stack.is(BuiltInRegistries.ITEM.getOptional(CHEEP_ITEM_ID).orElse(Items.AIR));
|
||||
}
|
||||
|
||||
private static class HuntCheepGoal extends Goal {
|
||||
private static final int COOLDOWN_TICKS = 600; // 30 seconds
|
||||
private static final double HUNT_RANGE = 16.0D;
|
||||
private static final double ATTACK_RANGE_SQ = 2.5D * 2.5D;
|
||||
|
||||
private final DorrieEntity dorrie;
|
||||
private CheepEntity target;
|
||||
private int cooldown = 0;
|
||||
|
||||
HuntCheepGoal(DorrieEntity dorrie) {
|
||||
this.dorrie = dorrie;
|
||||
setFlags(EnumSet.of(Flag.MOVE, Flag.LOOK));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canUse() {
|
||||
if (dorrie.level().isClientSide) return false;
|
||||
if (cooldown > 0) { cooldown--; return false; }
|
||||
List<CheepEntity> nearby = dorrie.level().getEntitiesOfClass(
|
||||
CheepEntity.class,
|
||||
dorrie.getBoundingBox().inflate(HUNT_RANGE)
|
||||
);
|
||||
if (nearby.isEmpty()) return false;
|
||||
nearby.sort((a, b) -> Double.compare(a.distanceToSqr(dorrie), b.distanceToSqr(dorrie)));
|
||||
target = nearby.get(0);
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canContinueToUse() {
|
||||
return target != null && target.isAlive() && dorrie.distanceToSqr(target) <= HUNT_RANGE * HUNT_RANGE * 4;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void start() {
|
||||
dorrie.getNavigation().moveTo(target, 1.4D);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
if (target == null) return;
|
||||
dorrie.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
dorrie.getNavigation().moveTo(target, 1.4D);
|
||||
if (dorrie.distanceToSqr(target) <= ATTACK_RANGE_SQ) {
|
||||
target.hurt(dorrie.damageSources().mobAttack(dorrie), (float) dorrie.getAttributeValue(Attributes.ATTACK_DAMAGE));
|
||||
stop();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void stop() {
|
||||
target = null;
|
||||
dorrie.getNavigation().stop();
|
||||
cooldown = COOLDOWN_TICKS;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -64,17 +64,23 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
private static final String POUNCE_COOLDOWN_KEY = "PounceCooldown";
|
||||
private static final String RECOVERY_TICKS_KEY = "RecoveryTicks";
|
||||
private static final String POUNCE_TICKS_KEY = "PounceTicks";
|
||||
private static final String LEAPING_TICKS_KEY = "LeapingTicks";
|
||||
|
||||
private static final double DEFAULT_MOVEMENT_SPEED = 0.25D;
|
||||
private static final double DEFAULT_FOLLOW_RANGE = 16.0D;
|
||||
private static final double MELEE_WALK_RANGE = 4.0D;
|
||||
private static final double CHASE_LEAP_RANGE_SQR = 8.0D * 8.0D;
|
||||
private static final int DEFAULT_POUNCE_COOLDOWN = 60;
|
||||
private static final int DEFAULT_RECOVERY_TICKS = 20;
|
||||
private static final int CHASE_JUMP_COOLDOWN = 25;
|
||||
private static final double POUNCE_HORIZONTAL_SPEED = 0.92D;
|
||||
private static final double POUNCE_UPWARD_SPEED = 0.75D;
|
||||
private static final double CHASE_LEAP_HORIZONTAL = 1.5D;
|
||||
private static final double CHASE_LEAP_VERTICAL = 0.55D;
|
||||
private static final double QUICK_MOVE_SQR = 0.14D * 0.14D;
|
||||
private static final double CLING_SEARCH_RANGE = 1.5D;
|
||||
private static final double POUNCE_LAND_DAMAGE_RANGE = 5.0D;
|
||||
private static final int CEILING_SEARCH_RANGE = 30;
|
||||
private static final double CAMOUFLAGE_PLAYER_RANGE = 24.0D;
|
||||
|
||||
private static final RawAnimation IDLE_ANIM = RawAnimation.begin().thenLoop("idle");
|
||||
private static final RawAnimation WALK_ANIM = RawAnimation.begin().thenLoop("walk");
|
||||
@@ -86,6 +92,8 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
private int pounceCooldownTicks;
|
||||
private int recoveryTicks;
|
||||
private int pounceTicks;
|
||||
private int leapingTicks;
|
||||
private int chaseJumpCooldownTicks;
|
||||
private float visualAlpha = 1.0F;
|
||||
private float previousVisualAlpha = 1.0F;
|
||||
|
||||
@@ -122,12 +130,13 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
@Override
|
||||
protected void registerGoals() {
|
||||
this.goalSelector.addGoal(0, new FloatGoal(this));
|
||||
this.goalSelector.addGoal(1, new PounceAttackGoal());
|
||||
this.goalSelector.addGoal(2, new CeilingClingGoal());
|
||||
this.goalSelector.addGoal(3, new ChaseTargetGoal());
|
||||
this.goalSelector.addGoal(4, new WanderGoal());
|
||||
this.goalSelector.addGoal(5, new LookAtPlayerGoal(this, Player.class, 10.0F));
|
||||
this.goalSelector.addGoal(6, new RandomLookAroundGoal(this));
|
||||
this.goalSelector.addGoal(1, new CloseMeleeGoal());
|
||||
this.goalSelector.addGoal(2, new PounceAttackGoal());
|
||||
this.goalSelector.addGoal(3, new HideOnCeilingGoal());
|
||||
this.goalSelector.addGoal(4, new ChaseTargetGoal());
|
||||
this.goalSelector.addGoal(5, new WanderGoal());
|
||||
this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 10.0F));
|
||||
this.goalSelector.addGoal(7, new RandomLookAroundGoal(this));
|
||||
this.targetSelector.addGoal(1, new HurtByTargetGoal(this));
|
||||
this.targetSelector.addGoal(2, new NearestAttackableTargetGoal<>(this, Player.class, true));
|
||||
}
|
||||
@@ -148,6 +157,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
tag.putInt(POUNCE_COOLDOWN_KEY, this.pounceCooldownTicks);
|
||||
tag.putInt(RECOVERY_TICKS_KEY, this.recoveryTicks);
|
||||
tag.putInt(POUNCE_TICKS_KEY, this.pounceTicks);
|
||||
tag.putInt(LEAPING_TICKS_KEY, this.leapingTicks);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -156,6 +166,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
this.pounceCooldownTicks = tag.getInt(POUNCE_COOLDOWN_KEY);
|
||||
this.recoveryTicks = tag.getInt(RECOVERY_TICKS_KEY);
|
||||
this.pounceTicks = tag.getInt(POUNCE_TICKS_KEY);
|
||||
this.leapingTicks = tag.getInt(LEAPING_TICKS_KEY);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -168,7 +179,10 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
@Override
|
||||
public void tick() {
|
||||
this.previousVisualAlpha = this.visualAlpha;
|
||||
this.visualAlpha += (this.getTargetVisualAlpha() - this.visualAlpha) * 0.25F;
|
||||
float targetAlpha = this.getTargetVisualAlpha();
|
||||
if (this.visualAlpha != targetAlpha) {
|
||||
this.visualAlpha += (targetAlpha - this.visualAlpha) * 0.25F;
|
||||
}
|
||||
|
||||
super.tick();
|
||||
|
||||
@@ -182,11 +196,16 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
if (this.recoveryTicks > 0) {
|
||||
this.recoveryTicks--;
|
||||
}
|
||||
if (this.chaseJumpCooldownTicks > 0) {
|
||||
this.chaseJumpCooldownTicks--;
|
||||
}
|
||||
|
||||
if (this.isClingingToCeiling()) {
|
||||
this.tickClinging();
|
||||
} else if (this.isPouncing()) {
|
||||
this.tickPouncing();
|
||||
} else if (this.isLeapingToCeiling()) {
|
||||
this.tickLeapingToCeiling();
|
||||
} else {
|
||||
this.setNoGravity(false);
|
||||
this.noPhysics = false;
|
||||
@@ -222,6 +241,9 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
if (this.isPouncing()) {
|
||||
this.finishPounce(false);
|
||||
}
|
||||
if (this.isLeapingToCeiling()) {
|
||||
this.cancelLeap();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -262,6 +284,10 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
return this.getAttackState() == AttackState.POUNCING;
|
||||
}
|
||||
|
||||
public boolean isLeapingToCeiling() {
|
||||
return this.getAttackState() == AttackState.LEAPING_TO_CEILING;
|
||||
}
|
||||
|
||||
public float getVisualAlpha(float partialTick) {
|
||||
return Mth.lerp(partialTick, this.previousVisualAlpha, this.visualAlpha);
|
||||
}
|
||||
@@ -288,7 +314,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
|
||||
private PlayState mainAnimController(AnimationState<JumpyBugEntity> state) {
|
||||
AttackState attackState = this.getAttackState();
|
||||
if (attackState == AttackState.POUNCING || attackState == AttackState.CLINGING) {
|
||||
if (attackState == AttackState.POUNCING || attackState == AttackState.CLINGING || attackState == AttackState.LEAPING_TO_CEILING) {
|
||||
return state.setAndContinue(JUMP_ANIM);
|
||||
}
|
||||
if (attackState == AttackState.RECOVERING) {
|
||||
@@ -298,7 +324,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
|
||||
private void tickClinging() {
|
||||
BlockPos clingPos = this.findClingBlockPos();
|
||||
BlockPos clingPos = this.findCeilingWithinRange(2);
|
||||
if (clingPos == null) {
|
||||
this.stopClinging();
|
||||
return;
|
||||
@@ -328,37 +354,61 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
}
|
||||
|
||||
private void tickLeapingToCeiling() {
|
||||
this.leapingTicks++;
|
||||
if (this.leapingTicks > 80) {
|
||||
this.cancelLeap();
|
||||
return;
|
||||
}
|
||||
this.getNavigation().stop();
|
||||
BlockPos ceiling = this.findCeilingWithinRange(2);
|
||||
if (ceiling != null) {
|
||||
this.leapingTicks = 0;
|
||||
this.beginClinging();
|
||||
}
|
||||
}
|
||||
|
||||
private void updateCamouflage() {
|
||||
if (this.isPouncing()) {
|
||||
if (this.isPouncing() || this.isLeapingToCeiling()) {
|
||||
this.setCamouflaged(false);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.isClingingToCeiling()) {
|
||||
this.setCamouflaged(true);
|
||||
return;
|
||||
}
|
||||
|
||||
boolean playerNearby = this.level().getNearestPlayer(this, CAMOUFLAGE_PLAYER_RANGE) != null;
|
||||
if (!playerNearby) {
|
||||
this.setCamouflaged(false);
|
||||
return;
|
||||
}
|
||||
|
||||
boolean idle = this.getTarget() == null && this.getDeltaMovement().horizontalDistanceSqr() < 0.003D;
|
||||
boolean stalking = this.isClingingToCeiling();
|
||||
boolean movingQuickly = this.getDeltaMovement().lengthSqr() > QUICK_MOVE_SQR;
|
||||
boolean shouldCamouflage = !movingQuickly && (idle || stalking);
|
||||
this.setCamouflaged(shouldCamouflage);
|
||||
this.setCamouflaged(!movingQuickly && idle);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
private BlockPos findClingBlockPos() {
|
||||
private BlockPos findCeilingWithinRange(int maxBlocks) {
|
||||
BlockPos origin = this.blockPosition();
|
||||
for (int dy = 1; dy <= 2; dy++) {
|
||||
for (int dy = 1; dy <= maxBlocks; dy++) {
|
||||
BlockPos candidate = origin.above(dy);
|
||||
if (this.isCeilingBlock(candidate)) {
|
||||
if (isCeilingBlock(candidate)) {
|
||||
return candidate;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private boolean isCeilingBlock(BlockPos pos) {
|
||||
return this.level().getBlockState(pos).isFaceSturdy(this.level(), pos, net.minecraft.core.Direction.DOWN);
|
||||
@Nullable
|
||||
private BlockPos findCeilingForLeap() {
|
||||
return findCeilingWithinRange(CEILING_SEARCH_RANGE);
|
||||
}
|
||||
|
||||
private boolean canClingHere() {
|
||||
return this.findClingBlockPos() != null;
|
||||
private boolean isCeilingBlock(BlockPos pos) {
|
||||
return this.level().getBlockState(pos).isFaceSturdy(this.level(), pos, net.minecraft.core.Direction.DOWN);
|
||||
}
|
||||
|
||||
private void beginClinging() {
|
||||
@@ -377,6 +427,23 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
this.noPhysics = false;
|
||||
}
|
||||
|
||||
private void beginLeapToCeiling(BlockPos ceilingPos) {
|
||||
this.setAttackState(AttackState.LEAPING_TO_CEILING);
|
||||
this.setCamouflaged(false);
|
||||
this.leapingTicks = 0;
|
||||
this.getNavigation().stop();
|
||||
|
||||
double dy = ceilingPos.getY() - this.getY();
|
||||
double upwardSpeed = Math.min(2.5D, Math.sqrt(0.16D * Math.max(dy, 1.0D)) + 0.4D);
|
||||
this.setDeltaMovement(0.0D, upwardSpeed, 0.0D);
|
||||
this.hasImpulse = true;
|
||||
}
|
||||
|
||||
private void cancelLeap() {
|
||||
this.leapingTicks = 0;
|
||||
this.setAttackState(AttackState.GROUND);
|
||||
}
|
||||
|
||||
private void beginPounce(LivingEntity target) {
|
||||
this.stopClinging();
|
||||
this.setTarget(target);
|
||||
@@ -407,14 +474,16 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
|
||||
private boolean canUseAmbush() {
|
||||
return !this.isPouncing()
|
||||
&& !this.isLeapingToCeiling()
|
||||
&& this.recoveryTicks <= 0;
|
||||
}
|
||||
|
||||
private enum AttackState implements StringRepresentable {
|
||||
public enum AttackState implements StringRepresentable {
|
||||
GROUND(0, "ground"),
|
||||
CLINGING(1, "clinging"),
|
||||
POUNCING(2, "pouncing"),
|
||||
RECOVERING(3, "recovering");
|
||||
RECOVERING(3, "recovering"),
|
||||
LEAPING_TO_CEILING(4, "leaping_to_ceiling");
|
||||
|
||||
private static final IntFunction<AttackState> BY_ID = ByIdMap.continuous(AttackState::id, values(), ByIdMap.OutOfBoundsStrategy.ZERO);
|
||||
public static final Codec<AttackState> CODEC = StringRepresentable.fromEnum(AttackState::values);
|
||||
@@ -437,6 +506,61 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
}
|
||||
|
||||
private final class CloseMeleeGoal extends Goal {
|
||||
private static final double MELEE_RANGE_SQR = 5.0D * 5.0D;
|
||||
private static final double CONTINUE_RANGE_SQR = 7.0D * 7.0D;
|
||||
private static final int ATTACK_COOLDOWN = 20;
|
||||
private int attackCooldown;
|
||||
|
||||
private CloseMeleeGoal() {
|
||||
this.setFlags(EnumSet.of(Flag.MOVE, Flag.LOOK));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canUse() {
|
||||
LivingEntity target = JumpyBugEntity.this.getTarget();
|
||||
return target != null
|
||||
&& target.isAlive()
|
||||
&& !JumpyBugEntity.this.isPouncing()
|
||||
&& !JumpyBugEntity.this.isLeapingToCeiling()
|
||||
&& !JumpyBugEntity.this.isClingingToCeiling()
|
||||
&& JumpyBugEntity.this.distanceToSqr(target) <= MELEE_RANGE_SQR;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canContinueToUse() {
|
||||
LivingEntity target = JumpyBugEntity.this.getTarget();
|
||||
return target != null
|
||||
&& target.isAlive()
|
||||
&& !JumpyBugEntity.this.isPouncing()
|
||||
&& !JumpyBugEntity.this.isLeapingToCeiling()
|
||||
&& !JumpyBugEntity.this.isClingingToCeiling()
|
||||
&& JumpyBugEntity.this.distanceToSqr(target) <= CONTINUE_RANGE_SQR;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void start() {
|
||||
this.attackCooldown = 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
LivingEntity target = JumpyBugEntity.this.getTarget();
|
||||
if (target == null) return;
|
||||
|
||||
JumpyBugEntity.this.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
JumpyBugEntity.this.getNavigation().moveTo(target, 1.1D);
|
||||
|
||||
if (this.attackCooldown > 0) {
|
||||
this.attackCooldown--;
|
||||
}
|
||||
if (this.attackCooldown <= 0 && JumpyBugEntity.this.distanceToSqr(target) <= MELEE_RANGE_SQR) {
|
||||
JumpyBugEntity.this.doHurtTarget(target);
|
||||
this.attackCooldown = ATTACK_COOLDOWN;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private final class PounceAttackGoal extends Goal {
|
||||
private PounceAttackGoal() {
|
||||
this.setFlags(EnumSet.of(Flag.MOVE, Flag.LOOK, Flag.JUMP));
|
||||
@@ -466,8 +590,11 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
}
|
||||
|
||||
private final class CeilingClingGoal extends Goal {
|
||||
private CeilingClingGoal() {
|
||||
private final class HideOnCeilingGoal extends Goal {
|
||||
@Nullable
|
||||
private BlockPos targetCeiling;
|
||||
|
||||
private HideOnCeilingGoal() {
|
||||
this.setFlags(EnumSet.of(Flag.MOVE, Flag.LOOK, Flag.JUMP));
|
||||
}
|
||||
|
||||
@@ -476,40 +603,53 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
if (!JumpyBugEntity.this.canUseAmbush() || JumpyBugEntity.this.isClingingToCeiling()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
LivingEntity target = JumpyBugEntity.this.getTarget();
|
||||
if (target == null) {
|
||||
return JumpyBugEntity.this.random.nextInt(40) == 0 && JumpyBugEntity.this.canClingHere();
|
||||
boolean targetFarAway = target != null
|
||||
&& JumpyBugEntity.this.distanceToSqr(target) > 12.0D * 12.0D;
|
||||
boolean noTarget = target == null;
|
||||
if (!noTarget && !targetFarAway) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return JumpyBugEntity.this.distanceToSqr(target) <= (DEFAULT_FOLLOW_RANGE + CLING_SEARCH_RANGE) * (DEFAULT_FOLLOW_RANGE + CLING_SEARCH_RANGE)
|
||||
&& JumpyBugEntity.this.canClingHere();
|
||||
if (JumpyBugEntity.this.random.nextInt(25) != 0) {
|
||||
return false;
|
||||
}
|
||||
this.targetCeiling = JumpyBugEntity.this.findCeilingForLeap();
|
||||
return this.targetCeiling != null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canContinueToUse() {
|
||||
return JumpyBugEntity.this.isClingingToCeiling();
|
||||
return JumpyBugEntity.this.isClingingToCeiling() || JumpyBugEntity.this.isLeapingToCeiling();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void start() {
|
||||
if (this.targetCeiling != null) {
|
||||
BlockPos ceil = this.targetCeiling;
|
||||
// If we're already adjacent to the ceiling, just cling directly
|
||||
if (ceil.getY() - JumpyBugEntity.this.getY() <= 2) {
|
||||
JumpyBugEntity.this.beginClinging();
|
||||
} else {
|
||||
JumpyBugEntity.this.beginLeapToCeiling(ceil);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void stop() {
|
||||
if (JumpyBugEntity.this.isClingingToCeiling()) {
|
||||
JumpyBugEntity.this.stopClinging();
|
||||
} else if (JumpyBugEntity.this.isLeapingToCeiling()) {
|
||||
JumpyBugEntity.this.cancelLeap();
|
||||
}
|
||||
this.targetCeiling = null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
if (JumpyBugEntity.this.isClingingToCeiling()) {
|
||||
LivingEntity target = JumpyBugEntity.this.getTarget();
|
||||
if (target == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (target != null) {
|
||||
JumpyBugEntity.this.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
if (JumpyBugEntity.this.pounceCooldownTicks <= 0
|
||||
&& (JumpyBugEntity.this.hasLineOfSight(target) || JumpyBugEntity.this.distanceToSqr(target) <= 4.0D)) {
|
||||
@@ -518,6 +658,8 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private final class ChaseTargetGoal extends Goal {
|
||||
private ChaseTargetGoal() {
|
||||
@@ -531,6 +673,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
&& target.isAlive()
|
||||
&& !JumpyBugEntity.this.isClingingToCeiling()
|
||||
&& !JumpyBugEntity.this.isPouncing()
|
||||
&& !JumpyBugEntity.this.isLeapingToCeiling()
|
||||
&& JumpyBugEntity.this.recoveryTicks <= 0;
|
||||
}
|
||||
|
||||
@@ -547,11 +690,24 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
|
||||
JumpyBugEntity.this.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
// Only walk when close; at range, pounce is the primary approach
|
||||
if (JumpyBugEntity.this.distanceToSqr(target) <= MELEE_WALK_RANGE * MELEE_WALK_RANGE) {
|
||||
double distSqr = JumpyBugEntity.this.distanceToSqr(target);
|
||||
|
||||
if (distSqr <= MELEE_WALK_RANGE * MELEE_WALK_RANGE) {
|
||||
JumpyBugEntity.this.getNavigation().moveTo(target, 1.05D);
|
||||
} else {
|
||||
} else if (distSqr > CHASE_LEAP_RANGE_SQR) {
|
||||
if (JumpyBugEntity.this.onGround() && JumpyBugEntity.this.chaseJumpCooldownTicks <= 0) {
|
||||
Vec3 dir = target.position().subtract(JumpyBugEntity.this.position()).normalize();
|
||||
JumpyBugEntity.this.setDeltaMovement(
|
||||
dir.x * CHASE_LEAP_HORIZONTAL,
|
||||
CHASE_LEAP_VERTICAL,
|
||||
dir.z * CHASE_LEAP_HORIZONTAL
|
||||
);
|
||||
JumpyBugEntity.this.hasImpulse = true;
|
||||
JumpyBugEntity.this.chaseJumpCooldownTicks = CHASE_JUMP_COOLDOWN;
|
||||
}
|
||||
JumpyBugEntity.this.getNavigation().stop();
|
||||
} else {
|
||||
JumpyBugEntity.this.getNavigation().moveTo(target, 1.05D);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -565,6 +721,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
public boolean canUse() {
|
||||
return !JumpyBugEntity.this.isClingingToCeiling()
|
||||
&& !JumpyBugEntity.this.isPouncing()
|
||||
&& !JumpyBugEntity.this.isLeapingToCeiling()
|
||||
&& JumpyBugEntity.this.getTarget() == null
|
||||
&& super.canUse();
|
||||
}
|
||||
@@ -573,6 +730,7 @@ public class JumpyBugEntity extends Monster implements GeoEntity {
|
||||
public boolean canContinueToUse() {
|
||||
return !JumpyBugEntity.this.isClingingToCeiling()
|
||||
&& !JumpyBugEntity.this.isPouncing()
|
||||
&& !JumpyBugEntity.this.isLeapingToCeiling()
|
||||
&& super.canContinueToUse();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -168,7 +168,7 @@ public class LurkingTerrorEntity extends Monster implements GeoEntity {
|
||||
if (!this.level().isClientSide() && !this.onGround() && this.tickCount % 40 == 0) {
|
||||
this.playSound(AntarchySoundEvents.LURKING_TERROR_FLY_LOOP.get(), 0.45F, 0.95F + this.random.nextFloat() * 0.1F);
|
||||
}
|
||||
if (attackAnimTicks > 0) attackAnimTicks--;
|
||||
if (!this.level().isClientSide() && attackAnimTicks > 0) attackAnimTicks--;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -52,7 +52,7 @@ public class SpitBugEntity extends Monster implements GeoEntity {
|
||||
private static final RawAnimation WALK_ANIM = RawAnimation.begin().thenLoop("walk");
|
||||
private static final RawAnimation SPIT_ANIM = RawAnimation.begin().thenPlay("spit");
|
||||
|
||||
private static final double MAX_HEALTH = 30.0D;
|
||||
private static final double MAX_HEALTH = 50.0D;
|
||||
private static final double MOVEMENT_SPEED = 0.23D;
|
||||
private static final double ATTACK_DAMAGE = 5.0D;
|
||||
private static final double FOLLOW_RANGE = 24.0D;
|
||||
|
||||
@@ -70,19 +70,17 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
private static final int ANIM_RAPID_SHOOT = 8;
|
||||
|
||||
private static final int ATTACK_RAPID_FIRE = 0;
|
||||
private static final int ATTACK_HUGE_BOMB = 1;
|
||||
private static final int ATTACK_BOMBERS = 2;
|
||||
private static final int ATTACK_BOMBERS = 1;
|
||||
|
||||
private static final int DEATH_TICKS = 60;
|
||||
private static final int SHOOT_TOTAL_TICKS = 75;
|
||||
private static final int SHOOT_FIRE_START_TICK = 12;
|
||||
private static final int RAPID_FIRE_INTERVAL = 4;
|
||||
private static final int RAPID_FIRE_END_TICK = 60;
|
||||
private static final int SHOOT_BOMBER_TICK = 12;
|
||||
private static final int SHOOT_BOMBER_SECOND_TICK = 32;
|
||||
private static final int JUMP_TOTAL_TICKS = 40;
|
||||
private static final int JUMP_TOTAL_TICKS = 55;
|
||||
private static final int JUMP_LAUNCH_TICK = 10;
|
||||
private static final int JUMP_SHAKE_TICKS = 25;
|
||||
private static final int JUMP_SHAKE_TICKS = 12;
|
||||
private static final int SPIN_START_TOTAL_TICKS = 5;
|
||||
private static final int SPIN_LOOP_MIN_TICKS = 200;
|
||||
private static final int SPIN_LOOP_MAX_TICKS = 300;
|
||||
@@ -96,8 +94,8 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
private static final double SPIN_TRIGGER_RANGE_SQR = 225.0D;
|
||||
private static final double SPIN_LEASH_RANGE_SQR = 225.0D;
|
||||
private static final double SPIN_RADIUS = 4.5D;
|
||||
private static final double SPIN_MOVE_SPEED = 1.7D;
|
||||
private static final double SPIN_ANIMATION_SPEED = 0.7D;
|
||||
private static final double SPIN_MOVE_SPEED = 0.833D;
|
||||
private static final double SPIN_ANIMATION_SPEED = 0.49D;
|
||||
private static final double JUMP_SHOCKWAVE_RADIUS = 6.0D;
|
||||
|
||||
private static final RawAnimation IDLE_ANIM = RawAnimation.begin().thenLoop("Idle");
|
||||
@@ -123,6 +121,7 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
private int jumpCooldown;
|
||||
private int spinCooldown;
|
||||
private boolean jumpLaunched;
|
||||
private boolean jumpAirborne;
|
||||
private boolean shockwaveApplied;
|
||||
private int jumpShakeTicks;
|
||||
private int shootAttackType;
|
||||
@@ -274,7 +273,7 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
return this.entityData.get(JUMP_SHAKING);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Override
|
||||
public void startSeenByPlayer(ServerPlayer player) {
|
||||
super.startSeenByPlayer(player);
|
||||
this.bossEvent.addPlayer(player);
|
||||
@@ -377,12 +376,6 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
this.fireRapidBomb();
|
||||
}
|
||||
}
|
||||
case ATTACK_HUGE_BOMB -> {
|
||||
this.setAnimationState(ANIM_SHOOT);
|
||||
if (elapsed == SHOOT_FIRE_START_TICK) {
|
||||
this.fireHugeBomb();
|
||||
}
|
||||
}
|
||||
default -> {
|
||||
this.setAnimationState(ANIM_SHOOT);
|
||||
if (!this.shootBomberFired && elapsed >= SHOOT_BOMBER_TICK) {
|
||||
@@ -398,7 +391,12 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
this.getNavigation().stop();
|
||||
this.setDeltaMovement(this.getDeltaMovement().scale(0.85D));
|
||||
if (this.getTarget() != null) {
|
||||
this.getLookControl().setLookAt(this.getTarget(), 30.0F, 20.0F);
|
||||
Vec3 toTarget = this.getTarget().position().subtract(this.position());
|
||||
float yaw = (float) (net.minecraft.util.Mth.atan2(toTarget.z, toTarget.x) * (180.0D / Math.PI)) - 90.0F;
|
||||
this.setYRot(yaw);
|
||||
this.yBodyRot = yaw;
|
||||
this.yHeadRot = yaw;
|
||||
this.setYHeadRot(yaw);
|
||||
}
|
||||
this.shootAnimTicks--;
|
||||
if (this.shootAnimTicks <= 0) {
|
||||
@@ -414,16 +412,30 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
LivingEntity target = this.getTarget();
|
||||
if (target != null) {
|
||||
Vec3 toTarget = target.position().subtract(this.position()).normalize();
|
||||
this.setDeltaMovement(toTarget.x * 0.6D, 0.85D, toTarget.z * 0.6D);
|
||||
this.setDeltaMovement(toTarget.x * 0.6D, 1.4D, toTarget.z * 0.6D);
|
||||
this.hasImpulse = true;
|
||||
}
|
||||
}
|
||||
if (this.jumpLaunched && this.onGround() && elapsed > JUMP_LAUNCH_TICK + 3 && !this.shockwaveApplied) {
|
||||
if (this.jumpLaunched && !this.onGround()) {
|
||||
this.jumpAirborne = true;
|
||||
}
|
||||
if (this.jumpLaunched && this.jumpAirborne && !this.shockwaveApplied) {
|
||||
boolean forceLand = this.jumpAnimTicks <= 1;
|
||||
if (forceLand) {
|
||||
BlockPos pos = BlockPos.containing(this.getX(), this.getY(), this.getZ());
|
||||
while (pos.getY() > this.level().getMinBuildHeight() && this.level().isEmptyBlock(pos)) {
|
||||
pos = pos.below();
|
||||
}
|
||||
this.teleportTo(this.getX(), pos.getY() + 1.0, this.getZ());
|
||||
this.setDeltaMovement(Vec3.ZERO);
|
||||
}
|
||||
if (this.onGround() || forceLand) {
|
||||
this.shockwaveApplied = true;
|
||||
this.applyJumpShockwave();
|
||||
this.jumpShakeTicks = JUMP_SHAKE_TICKS;
|
||||
this.entityData.set(JUMP_SHAKING, true);
|
||||
}
|
||||
}
|
||||
this.jumpAnimTicks--;
|
||||
if (this.jumpAnimTicks <= 0) {
|
||||
this.jumpCooldown = 140 + this.random.nextInt(80);
|
||||
@@ -509,8 +521,7 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
return;
|
||||
}
|
||||
Vec3 forward = this.spinDirection.lengthSqr() > 1.0E-4D ? this.spinDirection.normalize() : towardTarget;
|
||||
Vec3 strafe = new Vec3(-towardTarget.z, 0.0D, towardTarget.x).scale(this.spinStrafeSign);
|
||||
Vec3 combined = forward.scale(1.2D).add(towardTarget.scale(0.15D)).add(strafe.scale(1.35D));
|
||||
Vec3 combined = forward.scale(0.95D).add(towardTarget.scale(0.05D));
|
||||
this.spinDirection = combined.lengthSqr() > 1.0E-4D ? combined.normalize() : towardTarget;
|
||||
}
|
||||
|
||||
@@ -677,22 +688,6 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
}
|
||||
}
|
||||
|
||||
private void fireHugeBomb() {
|
||||
if (!(this.level() instanceof ServerLevel serverLevel)) return;
|
||||
LivingEntity target = this.getTarget();
|
||||
if (target == null) return;
|
||||
this.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
Vec3 from = new Vec3(this.getX(), this.getEyeY(), this.getZ());
|
||||
Vec3 to = new Vec3(target.getX(), target.getY(), target.getZ());
|
||||
Vec3 vel = calcLaunchVelocity(from, to, 0.9);
|
||||
WaterBombEntity bomb = new WaterBombEntity(this.level(), this, true);
|
||||
bomb.setPos(from.x, from.y, from.z);
|
||||
bomb.setDeltaMovement(vel);
|
||||
bomb.hasImpulse = true;
|
||||
serverLevel.addFreshEntity(bomb);
|
||||
}
|
||||
|
||||
|
||||
private void fireBomberBurst() {
|
||||
if (!(this.level() instanceof ServerLevel serverLevel)) return;
|
||||
LivingEntity target = this.getTarget();
|
||||
@@ -710,6 +705,7 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
bomber.setDeltaMovement(vx, vy, vz);
|
||||
bomber.setTarget(target);
|
||||
serverLevel.addFreshEntity(bomber);
|
||||
bomber.primeFuse();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -778,15 +774,8 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
ToreterrorEntity.this.shootBomberFiredSecond = false;
|
||||
ToreterrorEntity.this.rapidFireNextTick = 0;
|
||||
float roll = ToreterrorEntity.this.random.nextFloat();
|
||||
if (ToreterrorEntity.this.isPhase2()) {
|
||||
if (roll < 0.5F) ToreterrorEntity.this.shootAttackType = ATTACK_RAPID_FIRE;
|
||||
else if (roll < 0.65F) ToreterrorEntity.this.shootAttackType = ATTACK_HUGE_BOMB;
|
||||
else ToreterrorEntity.this.shootAttackType = ATTACK_BOMBERS;
|
||||
} else {
|
||||
if (roll < 0.5F) ToreterrorEntity.this.shootAttackType = ATTACK_RAPID_FIRE;
|
||||
else if (roll < 0.7F) ToreterrorEntity.this.shootAttackType = ATTACK_HUGE_BOMB;
|
||||
else ToreterrorEntity.this.shootAttackType = ATTACK_BOMBERS;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -818,6 +807,7 @@ public class ToreterrorEntity extends Monster implements GeoEntity {
|
||||
public void start() {
|
||||
ToreterrorEntity.this.jumpAnimTicks = JUMP_TOTAL_TICKS;
|
||||
ToreterrorEntity.this.jumpLaunched = false;
|
||||
ToreterrorEntity.this.jumpAirborne = false;
|
||||
ToreterrorEntity.this.shockwaveApplied = false;
|
||||
}
|
||||
|
||||
|
||||
@@ -117,9 +117,6 @@ public class WaterBombEntity extends ThrowableProjectile {
|
||||
for (BlockPos pos : BlockPos.betweenClosed(hitPos.offset(-1, 0, -1), hitPos.offset(1, 0, 1))) {
|
||||
if (level.getBlockState(pos).getBlock() instanceof BaseFireBlock) {
|
||||
level.removeBlock(pos, false);
|
||||
} else if (level.isEmptyBlock(pos)) {
|
||||
level.setBlock(pos, Blocks.WATER.defaultBlockState(), 3);
|
||||
level.scheduleTick(pos, Fluids.WATER, 2);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.LinkedHashSet;
|
||||
import java.util.Set;
|
||||
import net.minecraft.core.BlockPos;
|
||||
import net.minecraft.core.Direction;
|
||||
import net.minecraft.resources.ResourceKey;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.resources.ResourceKey;
|
||||
import net.minecraft.server.level.PlayerRespawnLogic;
|
||||
@@ -113,6 +114,11 @@ public final class AntTeleportHelper {
|
||||
|
||||
@Nullable
|
||||
private static Vec3 findSafeArrivalPosition(ServerPlayer player, ServerLevel destination, BlockPos preferredPos) {
|
||||
int[] yRange = getDimensionYRange(destination);
|
||||
if (yRange != null) {
|
||||
return findSafeArrivalPositionInYRange(player, destination, preferredPos, yRange[0], yRange[1]);
|
||||
}
|
||||
|
||||
Set<BlockPos> candidates = new LinkedHashSet<>();
|
||||
BlockPos adjustedPreferredPos = player.adjustSpawnLocation(destination, preferredPos);
|
||||
addArrivalCandidate(candidates, preferredPos);
|
||||
@@ -148,6 +154,40 @@ public final class AntTeleportHelper {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
private static int[] getDimensionYRange(ServerLevel destination) {
|
||||
ResourceKey<Level> dim = destination.dimension();
|
||||
if (dim == AntarchySettings.termiteDestinationDimension()) {
|
||||
return new int[]{100, 200};
|
||||
}
|
||||
if (dim == AntarchySettings.brownAntDestinationDimension()) {
|
||||
return new int[]{75, 120};
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
private static Vec3 findSafeArrivalPositionInYRange(ServerPlayer player, ServerLevel destination, BlockPos preferredPos, int minY, int maxY) {
|
||||
for (int radius = 0; radius <= 8; radius++) {
|
||||
for (int xOff = -radius; xOff <= radius; xOff++) {
|
||||
for (int zOff = -radius; zOff <= radius; zOff++) {
|
||||
if (radius > 0 && Math.abs(xOff) != radius && Math.abs(zOff) != radius) {
|
||||
continue;
|
||||
}
|
||||
int x = preferredPos.getX() + xOff;
|
||||
int z = preferredPos.getZ() + zOff;
|
||||
for (int y = maxY; y >= minY + 1; y--) {
|
||||
Vec3 safePos = tryFindSafeDismount(player, destination, new BlockPos(x, y, z));
|
||||
if (safePos != null && safePos.y >= minY && safePos.y <= maxY) {
|
||||
return safePos;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private static void addArrivalCandidate(Set<BlockPos> candidates, @Nullable BlockPos pos) {
|
||||
if (pos == null) {
|
||||
return;
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.craisinlord.antarchy.content.entity.ant;
|
||||
|
||||
import com.craisinlord.antarchy.content.AntarchySoundEvents;
|
||||
import com.craisinlord.antarchy.content.AntarchyTags;
|
||||
import com.craisinlord.antarchy.config.AntarchySettings;
|
||||
import net.minecraft.core.BlockPos;
|
||||
@@ -91,16 +92,6 @@ public class TermiteEntity extends BaseAntEntity implements GeoEntity {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canGroupWithNestmates() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canMarch() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean shouldUseBiteAnimation() {
|
||||
return true;
|
||||
@@ -149,6 +140,7 @@ public class TermiteEntity extends BaseAntEntity implements GeoEntity {
|
||||
this.triggerBiteAnimation(WOOD_BITE_ANIMATION_TICKS);
|
||||
this.level().destroyBlock(targetPos, false, this);
|
||||
this.level().playSound(null, targetPos, soundType.getBreakSound(), this.getSoundSource(), 0.7F, 1.1F);
|
||||
this.playSound(AntarchySoundEvents.ANT_BITE.get(), 0.35F, 0.95F + this.random.nextFloat() * 0.1F);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -604,7 +604,7 @@ public class BasiliskEntity extends Monster implements GeoEntity {
|
||||
BasiliskEntity.this.getLookControl().setLookAt(target, 30.0F, 30.0F);
|
||||
}
|
||||
|
||||
// super handles path recalc and cooldown timer — always run it
|
||||
// super handles path recalc and cooldown timer
|
||||
super.tick();
|
||||
|
||||
if (BasiliskEntity.this.hissChargeTimer > 0 || BasiliskEntity.this.attackAnimTicks > 0) {
|
||||
|
||||
@@ -403,6 +403,17 @@ public class KrakenEntity extends Monster implements GeoEntity {
|
||||
this.updateAnimationState();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void startSeenByPlayer(net.minecraft.server.level.ServerPlayer player) {
|
||||
super.startSeenByPlayer(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void stopSeenByPlayer(net.minecraft.server.level.ServerPlayer player) {
|
||||
super.stopSeenByPlayer(player);
|
||||
this.bossEvent.removePlayer(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void remove(Entity.RemovalReason reason) {
|
||||
this.clearKrakenStorm();
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
package com.craisinlord.antarchy.content.item;
|
||||
|
||||
import net.minecraft.world.item.Item;
|
||||
|
||||
public class CheepOnAStickItem extends Item {
|
||||
public CheepOnAStickItem(Properties properties) {
|
||||
super(properties);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,129 @@
|
||||
package com.craisinlord.antarchy.content.menu;
|
||||
|
||||
import net.minecraft.world.Container;
|
||||
import net.minecraft.world.SimpleContainer;
|
||||
import net.minecraft.world.entity.player.Inventory;
|
||||
import net.minecraft.world.entity.player.Player;
|
||||
import net.minecraft.world.inventory.AbstractContainerMenu;
|
||||
import net.minecraft.world.inventory.MenuType;
|
||||
import net.minecraft.world.inventory.Slot;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.item.Items;
|
||||
|
||||
import java.util.function.Supplier;
|
||||
|
||||
public class DorrieMenu extends AbstractContainerMenu {
|
||||
// Set by the Fabric platform during registration so common entity code can open the menu.
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Supplier<MenuType<DorrieMenu>> TYPE_SUPPLIER = () -> {
|
||||
throw new IllegalStateException("DorrieMenu.TYPE_SUPPLIER accessed before registration");
|
||||
};
|
||||
|
||||
private static final int EQUIPMENT_SLOTS = 1;
|
||||
private static final int PLAYER_INV_ROWS = 3;
|
||||
private static final int PLAYER_INV_COLS = 9;
|
||||
|
||||
// GUI layout constants (relative to background image top-left)
|
||||
public static final int SADDLE_SLOT_X = 80;
|
||||
public static final int SADDLE_SLOT_Y = 18;
|
||||
public static final int PLAYER_INV_X = 8;
|
||||
public static final int PLAYER_INV_Y = 48;
|
||||
public static final int HOTBAR_Y = 106;
|
||||
|
||||
private final Container equipment;
|
||||
|
||||
// Server-side constructor — receives the real Dorrie inventory.
|
||||
public DorrieMenu(int syncId, Inventory playerInventory, Container equipment) {
|
||||
super(TYPE_SUPPLIER.get(), syncId);
|
||||
this.equipment = equipment;
|
||||
checkContainerSize(equipment, EQUIPMENT_SLOTS);
|
||||
|
||||
// Slot 0: saddle
|
||||
this.addSlot(new Slot(equipment, 0, SADDLE_SLOT_X, SADDLE_SLOT_Y) {
|
||||
@Override
|
||||
public boolean mayPlace(ItemStack stack) {
|
||||
return stack.is(Items.SADDLE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxStackSize() {
|
||||
return 1;
|
||||
}
|
||||
});
|
||||
|
||||
// Player inventory (3 × 9)
|
||||
for (int row = 0; row < PLAYER_INV_ROWS; row++) {
|
||||
for (int col = 0; col < PLAYER_INV_COLS; col++) {
|
||||
this.addSlot(new Slot(
|
||||
playerInventory,
|
||||
col + row * PLAYER_INV_COLS + PLAYER_INV_COLS,
|
||||
PLAYER_INV_X + col * 18,
|
||||
PLAYER_INV_Y + row * 18
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
// Hotbar (9)
|
||||
for (int col = 0; col < PLAYER_INV_COLS; col++) {
|
||||
this.addSlot(new Slot(playerInventory, col, PLAYER_INV_X + col * 18, HOTBAR_Y));
|
||||
}
|
||||
}
|
||||
|
||||
// Client-side factory — syncs slot data from server.
|
||||
public static DorrieMenu clientCreate(int syncId, Inventory playerInventory) {
|
||||
return new DorrieMenu(syncId, playerInventory, new SimpleContainer(EQUIPMENT_SLOTS));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean stillValid(Player player) {
|
||||
return this.equipment.stillValid(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack quickMoveStack(Player player, int index) {
|
||||
ItemStack result = ItemStack.EMPTY;
|
||||
Slot slot = this.slots.get(index);
|
||||
if (!slot.hasItem()) return result;
|
||||
|
||||
ItemStack stack = slot.getItem();
|
||||
result = stack.copy();
|
||||
|
||||
int equipEnd = EQUIPMENT_SLOTS;
|
||||
int invEnd = equipEnd + PLAYER_INV_ROWS * PLAYER_INV_COLS;
|
||||
int totalSlots = invEnd + PLAYER_INV_COLS;
|
||||
|
||||
if (index < equipEnd) {
|
||||
// Equipment slot → player inventory
|
||||
if (!this.moveItemStackTo(stack, equipEnd, totalSlots, true)) {
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
} else {
|
||||
// Player inventory/hotbar → try equipment slot first
|
||||
if (stack.is(Items.SADDLE) && this.slots.get(0).mayPlace(stack)) {
|
||||
if (!this.moveItemStackTo(stack, 0, equipEnd, false)) {
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
} else if (index < invEnd) {
|
||||
// Inventory → hotbar
|
||||
if (!this.moveItemStackTo(stack, invEnd, totalSlots, false)) {
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
} else {
|
||||
// Hotbar → inventory
|
||||
if (!this.moveItemStackTo(stack, equipEnd, invEnd, false)) {
|
||||
return ItemStack.EMPTY;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (stack.isEmpty()) {
|
||||
slot.set(ItemStack.EMPTY);
|
||||
} else {
|
||||
slot.setChanged();
|
||||
}
|
||||
|
||||
if (stack.getCount() == result.getCount()) return ItemStack.EMPTY;
|
||||
slot.onTake(player, stack);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.craisinlord.antarchy.content.network;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import net.minecraft.network.codec.ByteBufCodecs;
|
||||
import net.minecraft.network.codec.StreamCodec;
|
||||
import net.minecraft.network.protocol.common.custom.CustomPacketPayload;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
|
||||
public record DorrieChargeJumpPayload(boolean pressing) implements CustomPacketPayload {
|
||||
public static final Type<DorrieChargeJumpPayload> TYPE =
|
||||
new Type<>(ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "dorrie_charge_jump_input"));
|
||||
public static final StreamCodec<ByteBuf, DorrieChargeJumpPayload> STREAM_CODEC =
|
||||
StreamCodec.composite(
|
||||
ByteBufCodecs.BOOL, DorrieChargeJumpPayload::pressing,
|
||||
DorrieChargeJumpPayload::new
|
||||
);
|
||||
|
||||
@Override
|
||||
public Type<DorrieChargeJumpPayload> type() {
|
||||
return TYPE;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.craisinlord.antarchy.content.network;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import net.minecraft.network.codec.ByteBufCodecs;
|
||||
import net.minecraft.network.codec.StreamCodec;
|
||||
import net.minecraft.network.protocol.common.custom.CustomPacketPayload;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
|
||||
public record DorrieJumpInputPayload(boolean pressing) implements CustomPacketPayload {
|
||||
public static final Type<DorrieJumpInputPayload> TYPE =
|
||||
new Type<>(ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "dorrie_jump_input"));
|
||||
public static final StreamCodec<ByteBuf, DorrieJumpInputPayload> STREAM_CODEC =
|
||||
StreamCodec.composite(
|
||||
ByteBufCodecs.BOOL, DorrieJumpInputPayload::pressing,
|
||||
DorrieJumpInputPayload::new
|
||||
);
|
||||
|
||||
@Override
|
||||
public Type<DorrieJumpInputPayload> type() {
|
||||
return TYPE;
|
||||
}
|
||||
}
|
||||
@@ -20,15 +20,19 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
net.minecraft.world.level.block.Block block,
|
||||
net.minecraft.world.level.block.Block coral,
|
||||
net.minecraft.world.level.block.Block wallFan,
|
||||
net.minecraft.world.level.block.Block floorFan
|
||||
net.minecraft.world.level.block.Block floorFan,
|
||||
net.minecraft.world.level.block.Block deadBlock,
|
||||
net.minecraft.world.level.block.Block deadCoral,
|
||||
net.minecraft.world.level.block.Block deadWallFan,
|
||||
net.minecraft.world.level.block.Block deadFloorFan
|
||||
) {}
|
||||
|
||||
private static final CoralSet[] CORAL_SETS = {
|
||||
new CoralSet(Blocks.TUBE_CORAL_BLOCK, Blocks.TUBE_CORAL, Blocks.TUBE_CORAL_WALL_FAN, Blocks.TUBE_CORAL_FAN),
|
||||
new CoralSet(Blocks.BRAIN_CORAL_BLOCK, Blocks.BRAIN_CORAL, Blocks.BRAIN_CORAL_WALL_FAN, Blocks.BRAIN_CORAL_FAN),
|
||||
new CoralSet(Blocks.BUBBLE_CORAL_BLOCK, Blocks.BUBBLE_CORAL, Blocks.BUBBLE_CORAL_WALL_FAN, Blocks.BUBBLE_CORAL_FAN),
|
||||
new CoralSet(Blocks.FIRE_CORAL_BLOCK, Blocks.FIRE_CORAL, Blocks.FIRE_CORAL_WALL_FAN, Blocks.FIRE_CORAL_FAN),
|
||||
new CoralSet(Blocks.HORN_CORAL_BLOCK, Blocks.HORN_CORAL, Blocks.HORN_CORAL_WALL_FAN, Blocks.HORN_CORAL_FAN),
|
||||
new CoralSet(Blocks.TUBE_CORAL_BLOCK, Blocks.TUBE_CORAL, Blocks.TUBE_CORAL_WALL_FAN, Blocks.TUBE_CORAL_FAN, Blocks.DEAD_TUBE_CORAL_BLOCK, Blocks.DEAD_TUBE_CORAL, Blocks.DEAD_TUBE_CORAL_WALL_FAN, Blocks.DEAD_TUBE_CORAL_FAN),
|
||||
new CoralSet(Blocks.BRAIN_CORAL_BLOCK, Blocks.BRAIN_CORAL, Blocks.BRAIN_CORAL_WALL_FAN, Blocks.BRAIN_CORAL_FAN, Blocks.DEAD_BRAIN_CORAL_BLOCK, Blocks.DEAD_BRAIN_CORAL, Blocks.DEAD_BRAIN_CORAL_WALL_FAN, Blocks.DEAD_BRAIN_CORAL_FAN),
|
||||
new CoralSet(Blocks.BUBBLE_CORAL_BLOCK, Blocks.BUBBLE_CORAL, Blocks.BUBBLE_CORAL_WALL_FAN, Blocks.BUBBLE_CORAL_FAN, Blocks.DEAD_BUBBLE_CORAL_BLOCK, Blocks.DEAD_BUBBLE_CORAL, Blocks.DEAD_BUBBLE_CORAL_WALL_FAN, Blocks.DEAD_BUBBLE_CORAL_FAN),
|
||||
new CoralSet(Blocks.FIRE_CORAL_BLOCK, Blocks.FIRE_CORAL, Blocks.FIRE_CORAL_WALL_FAN, Blocks.FIRE_CORAL_FAN, Blocks.DEAD_FIRE_CORAL_BLOCK, Blocks.DEAD_FIRE_CORAL, Blocks.DEAD_FIRE_CORAL_WALL_FAN, Blocks.DEAD_FIRE_CORAL_FAN),
|
||||
new CoralSet(Blocks.HORN_CORAL_BLOCK, Blocks.HORN_CORAL, Blocks.HORN_CORAL_WALL_FAN, Blocks.HORN_CORAL_FAN, Blocks.DEAD_HORN_CORAL_BLOCK, Blocks.DEAD_HORN_CORAL, Blocks.DEAD_HORN_CORAL_WALL_FAN, Blocks.DEAD_HORN_CORAL_FAN),
|
||||
};
|
||||
|
||||
public CoralSpikeFeature(Codec<NoneFeatureConfiguration> codec) {
|
||||
@@ -58,13 +62,13 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
|
||||
CoralSet coral = CORAL_SETS[random.nextInt(CORAL_SETS.length)];
|
||||
|
||||
int baseRadius = 2 + random.nextInt(2); // 2–3 wide at base
|
||||
int totalHeight = 20 + random.nextInt(15); // 20–34 blocks tall
|
||||
int baseRadius = 2 + random.nextInt(2); // 2-3 wide at base
|
||||
int totalHeight = 20 + random.nextInt(15); // 20-34 blocks tall
|
||||
|
||||
double curveAngle = random.nextDouble() * Math.PI * 2;
|
||||
double curveDX = Math.cos(curveAngle);
|
||||
double curveDZ = Math.sin(curveAngle);
|
||||
double maxCurve = 4.0 + random.nextDouble() * 5.0; // 4–9 block lean at tip
|
||||
double maxCurve = 4.0 + random.nextDouble() * 5.0; // 4-9 block lean at tip
|
||||
|
||||
boolean placed = false;
|
||||
|
||||
@@ -72,7 +76,7 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
int blockY = floorY + dy;
|
||||
double progress = (double) dy / totalHeight;
|
||||
|
||||
// Quadratic lean — slow at base, bending hard near tip
|
||||
// Quadratic lean -- slow at base, bending hard near tip
|
||||
double curveOffset = maxCurve * progress * progress;
|
||||
double centerX = origin.getX() + curveDX * curveOffset;
|
||||
double centerZ = origin.getZ() + curveDZ * curveOffset;
|
||||
@@ -92,7 +96,11 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
BlockPos pos = new BlockPos(origin.getX() + dx, blockY, origin.getZ() + dz);
|
||||
if (!canReplace(level.getBlockState(pos))) continue;
|
||||
|
||||
level.setBlock(pos, coral.block().defaultBlockState(), 2);
|
||||
boolean inWater = touchesWater(level, pos);
|
||||
level.setBlock(pos, inWater
|
||||
? coral.block().defaultBlockState()
|
||||
: coral.deadBlock().defaultBlockState(),
|
||||
2);
|
||||
placed = true;
|
||||
|
||||
if (dist >= radius - 0.6 && radius > 0) {
|
||||
@@ -115,11 +123,19 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
BlockState existing = level.getBlockState(fanPos);
|
||||
if (!existing.isAir() && !existing.is(Blocks.WATER)) continue;
|
||||
boolean fanInWater = existing.is(Blocks.WATER);
|
||||
if (fanInWater) {
|
||||
level.setBlock(fanPos,
|
||||
coral.wallFan().defaultBlockState()
|
||||
.setValue(BlockStateProperties.HORIZONTAL_FACING, dir)
|
||||
.setValue(BlockStateProperties.WATERLOGGED, fanInWater),
|
||||
.setValue(BlockStateProperties.WATERLOGGED, true),
|
||||
2);
|
||||
} else {
|
||||
level.setBlock(fanPos,
|
||||
coral.deadWallFan().defaultBlockState()
|
||||
.setValue(BlockStateProperties.HORIZONTAL_FACING, dir)
|
||||
.setValue(BlockStateProperties.WATERLOGGED, false),
|
||||
2);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -142,22 +158,36 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
float roll = random.nextFloat();
|
||||
CoralSet randomCoral = CORAL_SETS[random.nextInt(CORAL_SETS.length)];
|
||||
|
||||
if (roll < 0.35f && decorInWater) {
|
||||
// Coral plant (frond)
|
||||
if (roll < 0.35f) {
|
||||
if (decorInWater) {
|
||||
BlockState coralState = randomCoral.coral().defaultBlockState()
|
||||
.setValue(BlockStateProperties.WATERLOGGED, true);
|
||||
if (coralState.canSurvive(level, decorPos)) {
|
||||
level.setBlock(decorPos, coralState, 2);
|
||||
}
|
||||
} else {
|
||||
BlockState coralState = randomCoral.deadCoral().defaultBlockState()
|
||||
.setValue(BlockStateProperties.WATERLOGGED, false);
|
||||
if (coralState.canSurvive(level, decorPos)) {
|
||||
level.setBlock(decorPos, coralState, 2);
|
||||
}
|
||||
}
|
||||
} else if (roll < 0.65f) {
|
||||
// Floor fan
|
||||
if (decorInWater) {
|
||||
BlockState fanState = randomCoral.floorFan().defaultBlockState()
|
||||
.setValue(BlockStateProperties.WATERLOGGED, decorInWater);
|
||||
.setValue(BlockStateProperties.WATERLOGGED, true);
|
||||
if (fanState.canSurvive(level, decorPos)) {
|
||||
level.setBlock(decorPos, fanState, 2);
|
||||
}
|
||||
} else {
|
||||
// Sea pickle cluster
|
||||
BlockState fanState = randomCoral.deadFloorFan().defaultBlockState()
|
||||
.setValue(BlockStateProperties.WATERLOGGED, false);
|
||||
if (fanState.canSurvive(level, decorPos)) {
|
||||
level.setBlock(decorPos, fanState, 2);
|
||||
}
|
||||
}
|
||||
} else if (decorInWater) {
|
||||
// Sea pickle cluster -- only underwater
|
||||
BlockState pickle = Blocks.SEA_PICKLE.defaultBlockState()
|
||||
.setValue(SeaPickleBlock.PICKLES, 1 + random.nextInt(4));
|
||||
if (pickle.canSurvive(level, decorPos)) {
|
||||
@@ -169,6 +199,14 @@ public class CoralSpikeFeature extends Feature<NoneFeatureConfiguration> {
|
||||
return placed;
|
||||
}
|
||||
|
||||
private static boolean touchesWater(WorldGenLevel level, BlockPos pos) {
|
||||
if (level.getBlockState(pos).is(Blocks.WATER)) return true;
|
||||
for (Direction dir : Direction.values()) {
|
||||
if (level.getBlockState(pos.relative(dir)).is(Blocks.WATER)) return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private static boolean canReplace(BlockState state) {
|
||||
return state.isAir() || state.is(Blocks.WATER) || state.canBeReplaced();
|
||||
}
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
"animation_length": 0.5,
|
||||
"sound_effects": {
|
||||
"0.0": {
|
||||
"effect": "antarchy:bomber_walk|1.5|1.0"
|
||||
"effect": "antarchy:bomber_walk|0.6|1.0"
|
||||
}
|
||||
},
|
||||
"bones": {
|
||||
|
||||
@@ -0,0 +1,492 @@
|
||||
{
|
||||
"format_version": "1.8.0",
|
||||
"animations": {
|
||||
"pose": {
|
||||
"loop": true,
|
||||
"bones": {
|
||||
"right_arm": {
|
||||
"rotation": {
|
||||
"vector": [0, 0, 52.5]
|
||||
}
|
||||
},
|
||||
"left_arm": {
|
||||
"rotation": {
|
||||
"vector": [0, 0, -52.5]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"attack": {
|
||||
"loop": "hold_on_last_frame",
|
||||
"animation_length": 0.5,
|
||||
"bones": {
|
||||
"right_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [0, 0, 110]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [0, 0, 35]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bone": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
},
|
||||
"position": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0.3]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [0, 1, -2.7]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"left_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [0, 0, -110]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [0, 0, -35]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"tail": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.0417": {
|
||||
"post": {
|
||||
"vector": [0, -20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.0833": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.125": {
|
||||
"post": {
|
||||
"vector": [0, -20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.1667": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [0, -20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.25": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [0, -20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.3333": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.375": {
|
||||
"post": {
|
||||
"vector": [0, -20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.4167": {
|
||||
"post": {
|
||||
"vector": [0, 20, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"jaw": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [30, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [-5, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"mouth": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2083": {
|
||||
"post": {
|
||||
"vector": [-10, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.2917": {
|
||||
"post": {
|
||||
"vector": [5, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"swim": {
|
||||
"loop": true,
|
||||
"animation_length": 1,
|
||||
"bones": {
|
||||
"right_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.25": {
|
||||
"post": {
|
||||
"vector": [0, 0, 117.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.75": {
|
||||
"post": {
|
||||
"vector": [0, 0, 117.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bone": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.25": {
|
||||
"post": {
|
||||
"vector": [-2.5, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.75": {
|
||||
"post": {
|
||||
"vector": [2.5, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
},
|
||||
"position": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"left_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.25": {
|
||||
"post": {
|
||||
"vector": [0, 0, -117.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.75": {
|
||||
"post": {
|
||||
"vector": [0, 0, -117.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"tail": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 17.5, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"0.5": {
|
||||
"post": {
|
||||
"vector": [0, -17.5, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 17.5, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"idle": {
|
||||
"loop": true,
|
||||
"animation_length": 2,
|
||||
"bones": {
|
||||
"right_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 47.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"2.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bone": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"2.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
},
|
||||
"position": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0.4, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"2.0": {
|
||||
"post": {
|
||||
"vector": [0, 1, 0]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
},
|
||||
"left_arm": {
|
||||
"rotation": {
|
||||
"0.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"1.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -47.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
},
|
||||
"2.0": {
|
||||
"post": {
|
||||
"vector": [0, 0, -52.5]
|
||||
},
|
||||
"lerp_mode": "catmullrom"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,75 @@
|
||||
{
|
||||
"format_version": "1.12.0",
|
||||
"minecraft:geometry": [
|
||||
{
|
||||
"description": {
|
||||
"identifier": "geometry.unknown",
|
||||
"texture_width": 128,
|
||||
"texture_height": 128,
|
||||
"visible_bounds_width": 3,
|
||||
"visible_bounds_height": 2.5,
|
||||
"visible_bounds_offset": [0, 0.75, 0]
|
||||
},
|
||||
"bones": [
|
||||
{
|
||||
"name": "bone",
|
||||
"pivot": [-6, 7, 3.5],
|
||||
"cubes": [
|
||||
{"origin": [-6, 2, -4], "size": [12, 12, 12], "uv": [0, 0]},
|
||||
{"origin": [-0.5, 14, -3], "size": [1, 3, 11], "uv": [38, 24]},
|
||||
{"origin": [-0.5, 11, 8], "size": [1, 4, 2], "uv": [42, 53]},
|
||||
{"origin": [0, 17, -3], "size": [0, 4, 11], "uv": [38, 38]},
|
||||
{"origin": [0, 10.4, 8], "size": [0, 9, 4], "pivot": [0, 15.4, 11], "rotation": [5, 0, 0], "uv": [34, 53]},
|
||||
{"origin": [-6.2, 9.4, -4.2], "size": [6, 3, 3], "pivot": [-3.7, 10.4, -2.7], "rotation": [0, 0, 5], "uv": [48, 0]},
|
||||
{"origin": [0.2, 9.4, -4.2], "size": [6, 3, 3], "pivot": [3.7, 10.4, -2.7], "rotation": [0, 0, -5], "uv": [48, 0], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "jaw",
|
||||
"parent": "bone",
|
||||
"pivot": [0, 4, -0.5],
|
||||
"cubes": [
|
||||
{"origin": [-6, 2.5, -7], "size": [12, 3, 7], "inflate": 0.01, "uv": [0, 35]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "mouth",
|
||||
"parent": "bone",
|
||||
"pivot": [0, 7.5, 0.4],
|
||||
"cubes": [
|
||||
{"origin": [-6, 5.5, -7.1], "size": [12, 4, 7], "inflate": 0.2, "uv": [0, 24]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_arm",
|
||||
"parent": "bone",
|
||||
"pivot": [-6, 7, 3.5],
|
||||
"cubes": [
|
||||
{"origin": [-7, 2, 0], "size": [2, 5, 7], "uv": [0, 45]},
|
||||
{"origin": [-6.5, 0, 0], "size": [1, 2, 7], "uv": [18, 45]},
|
||||
{"origin": [-6, -2, 0], "size": [0, 2, 7], "uv": [48, 12]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_arm",
|
||||
"parent": "bone",
|
||||
"pivot": [6, 7, 3.5],
|
||||
"cubes": [
|
||||
{"origin": [5, 2, 0], "size": [2, 5, 7], "uv": [0, 45], "mirror": true},
|
||||
{"origin": [5.5, 0, 0], "size": [1, 2, 7], "uv": [18, 45], "mirror": true},
|
||||
{"origin": [6, -2, 0], "size": [0, 2, 7], "uv": [48, 12], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "tail",
|
||||
"parent": "bone",
|
||||
"pivot": [0, 6, 8.25],
|
||||
"cubes": [
|
||||
{"origin": [-1, 3, 7.5], "size": [2, 6, 2], "uv": [0, 81]},
|
||||
{"origin": [0, 2, 9.5], "size": [0, 8, 5], "uv": [12, 77]}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,253 @@
|
||||
{
|
||||
"format_version": "1.12.0",
|
||||
"minecraft:geometry": [
|
||||
{
|
||||
"description": {
|
||||
"identifier": "geometry.unknown",
|
||||
"texture_width": 256,
|
||||
"texture_height": 256,
|
||||
"visible_bounds_width": 9,
|
||||
"visible_bounds_height": 4.5,
|
||||
"visible_bounds_offset": [0, 1.75, 0]
|
||||
},
|
||||
"bones": [
|
||||
{
|
||||
"name": "bone",
|
||||
"pivot": [0, 8.5, 16.125]
|
||||
},
|
||||
{
|
||||
"name": "waist",
|
||||
"parent": "bone",
|
||||
"pivot": [0, 8.5, 16.125],
|
||||
"cubes": [
|
||||
{"origin": [-10, 1, 15], "size": [20, 19, 6], "uv": [98, 55]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "tail",
|
||||
"parent": "waist",
|
||||
"pivot": [0, 7.83333, 20.83333],
|
||||
"cubes": [
|
||||
{"origin": [-7, 2, 21], "size": [14, 17, 17], "uv": [70, 81]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "tail2",
|
||||
"parent": "tail",
|
||||
"pivot": [0, 6.5, 37.5],
|
||||
"cubes": [
|
||||
{"origin": [-5, 2, 38], "size": [10, 11, 17], "uv": [62, 115]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "tail3",
|
||||
"parent": "tail2",
|
||||
"pivot": [0, 5.5, 54.5],
|
||||
"cubes": [
|
||||
{"origin": [-3, 2, 55], "size": [6, 7, 7], "uv": [34, 163]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"parent": "bone",
|
||||
"pivot": [0, 11.33767, -10.06778],
|
||||
"cubes": [
|
||||
{"origin": [-13, 0, -19], "size": [26, 21, 34], "uv": [0, 0]},
|
||||
{"origin": [-11, 2, -24.6], "size": [22, 21, 13], "pivot": [0, 12.5, -19.6], "rotation": [-12.5, 0, 0], "uv": [0, 81]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "neck",
|
||||
"parent": "body",
|
||||
"pivot": [0, 20.33333, -19.1],
|
||||
"cubes": [
|
||||
{"origin": [-8, 10, -26.6], "size": [16, 16, 15], "uv": [0, 115]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "neck2",
|
||||
"parent": "neck",
|
||||
"pivot": [0, 25.5, -19.1],
|
||||
"cubes": [
|
||||
{"origin": [-6, 26, -25.6], "size": [12, 8, 13], "uv": [120, 12]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "neck3",
|
||||
"parent": "neck2",
|
||||
"pivot": [0, 34, -19.1],
|
||||
"cubes": [
|
||||
{"origin": [-5, 34, -24.6], "size": [10, 6, 11], "uv": [0, 146]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "head",
|
||||
"parent": "neck3",
|
||||
"pivot": [0.025, 40.75, -18.1],
|
||||
"cubes": [
|
||||
{"origin": [-6.5, 39, -25.6], "size": [13, 12, 13], "pivot": [-0.5, 44.5, -19.1], "rotation": [10, 0, 0], "uv": [116, 115]},
|
||||
{"origin": [-4.9, 39, -37.6], "size": [10, 3, 16], "uv": [120, 33]},
|
||||
{"origin": [-5.5, 42, -30.6], "size": [11, 7, 9], "uv": [100, 156]},
|
||||
{"origin": [-5.5, 42, -37.6], "size": [11, 7, 8], "inflate": 0.2, "uv": [150, 65]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "googles",
|
||||
"parent": "head",
|
||||
"pivot": [0, 47.45804, -21.34628],
|
||||
"cubes": [
|
||||
{"origin": [-5.5, 46.7, -27.4], "size": [11, 3, 1], "inflate": 0.1, "pivot": [0, 47.6, -24.6], "rotation": [9, 0, 0], "uv": [162, 151]},
|
||||
{"origin": [-7, 45.7, -19.3], "size": [14, 3, 7], "pivot": [-0.5, 44.5, -19.1], "rotation": [10, 0, 0], "uv": [140, 156]},
|
||||
{"origin": [-7.5, 44.7, -26.6], "size": [15, 5, 8], "pivot": [-0.5, 44.5, -19.1], "rotation": [10, 0, 0], "uv": [150, 52]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "saddle",
|
||||
"parent": "body",
|
||||
"pivot": [4.66667, 18.5, 1.16667],
|
||||
"cubes": [
|
||||
{"origin": [-13, 21, -10], "size": [26, 3, 23], "uv": [0, 55]},
|
||||
{"origin": [-9, 24, -10], "size": [18, 5, 3], "uv": [132, 106]},
|
||||
{"origin": [-13, 24, 9], "size": [26, 4, 4], "uv": [132, 80]},
|
||||
{"origin": [-14, -1, 7], "size": [28, 10, 2], "uv": [120, 0]},
|
||||
{"origin": [-15, 9, 6], "size": [2, 14, 4], "uv": [88, 164]},
|
||||
{"origin": [13, 9, 6], "size": [2, 14, 4], "uv": [88, 164], "mirror": true},
|
||||
{"origin": [13, 9, -7], "size": [2, 14, 4], "uv": [88, 164], "mirror": true},
|
||||
{"origin": [-15, 9, -7], "size": [2, 14, 4], "uv": [88, 164]},
|
||||
{"origin": [-14, -1, -6], "size": [28, 10, 2], "uv": [120, 0]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg",
|
||||
"parent": "body",
|
||||
"pivot": [-10.875, 0.875, 13.375],
|
||||
"rotation": [0, 45, 0],
|
||||
"cubes": [
|
||||
{"origin": [-14, 0, 9], "size": [5, 3, 9], "uv": [60, 164]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg2",
|
||||
"parent": "left_leg",
|
||||
"pivot": [-14.66667, 0.66667, 13.33333]
|
||||
},
|
||||
{
|
||||
"name": "left_leg3",
|
||||
"parent": "left_leg2",
|
||||
"pivot": [-14.66667, 0.66667, 13.33333],
|
||||
"cubes": [
|
||||
{"origin": [-19, 0, 9], "size": [5, 2, 9], "uv": [140, 166]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg4",
|
||||
"parent": "left_leg3",
|
||||
"pivot": [-19.25, 0.5, 13.25],
|
||||
"cubes": [
|
||||
{"origin": [-27, 0, 9], "size": [8, 1, 9], "uv": [0, 163]},
|
||||
{"origin": [-30, 0, 9], "size": [3, 1, 8], "uv": [168, 114]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg",
|
||||
"parent": "body",
|
||||
"pivot": [10.875, 0.875, 13.375],
|
||||
"rotation": [0, -45, 0],
|
||||
"cubes": [
|
||||
{"origin": [9, 0, 9], "size": [5, 3, 9], "uv": [60, 164], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg2",
|
||||
"parent": "right_leg",
|
||||
"pivot": [14.66667, 0.66667, 13.33333]
|
||||
},
|
||||
{
|
||||
"name": "right_leg3",
|
||||
"parent": "right_leg2",
|
||||
"pivot": [14.66667, 0.66667, 13.33333],
|
||||
"cubes": [
|
||||
{"origin": [14, 0, 9], "size": [5, 2, 9], "uv": [140, 166], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg4",
|
||||
"parent": "right_leg3",
|
||||
"pivot": [19.25, 0.5, 13.25],
|
||||
"cubes": [
|
||||
{"origin": [19, 0, 9], "size": [8, 1, 9], "uv": [0, 163], "mirror": true},
|
||||
{"origin": [27, 0, 9], "size": [3, 1, 8], "uv": [168, 114], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_arm",
|
||||
"parent": "body",
|
||||
"pivot": [-12.41667, 1.66667, -9.25],
|
||||
"cubes": [
|
||||
{"origin": [-15, 0, -18], "size": [4, 6, 15], "uv": [62, 143]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_arm2",
|
||||
"parent": "left_arm",
|
||||
"pivot": [-14.7, 1.4, -9],
|
||||
"cubes": [
|
||||
{"origin": [-25, 0, -17], "size": [10, 5, 13], "uv": [132, 88]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_arm3",
|
||||
"parent": "left_arm2",
|
||||
"pivot": [-25.125, 1.125, -8.625],
|
||||
"cubes": [
|
||||
{"origin": [-35, 0, -17], "size": [10, 3, 13], "uv": [116, 140]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_arm4",
|
||||
"parent": "left_arm3",
|
||||
"pivot": [-35.5, 1, -8],
|
||||
"cubes": [
|
||||
{"origin": [-45, 0, -17], "size": [10, 2, 9], "uv": [162, 140]},
|
||||
{"origin": [-42, 0, -7], "size": [2, 2, 3], "uv": [100, 143]},
|
||||
{"origin": [-40, 0, -8], "size": [5, 2, 4], "uv": [42, 146]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_arm",
|
||||
"parent": "body",
|
||||
"pivot": [12.41667, 1.66667, -9.25],
|
||||
"cubes": [
|
||||
{"origin": [11, 0, -18], "size": [4, 6, 15], "uv": [62, 143], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_arm2",
|
||||
"parent": "right_arm",
|
||||
"pivot": [14.7, 1.4, -9],
|
||||
"cubes": [
|
||||
{"origin": [15, 0, -17], "size": [10, 5, 13], "uv": [132, 88], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_arm3",
|
||||
"parent": "right_arm2",
|
||||
"pivot": [25.125, 1.125, -8.625],
|
||||
"cubes": [
|
||||
{"origin": [25, 0, -17], "size": [10, 3, 13], "uv": [116, 140], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_arm4",
|
||||
"parent": "right_arm3",
|
||||
"pivot": [35.5, 1, -8],
|
||||
"cubes": [
|
||||
{"origin": [35, 0, -17], "size": [10, 2, 9], "uv": [162, 140], "mirror": true},
|
||||
{"origin": [40, 0, -7], "size": [2, 2, 3], "uv": [100, 143], "mirror": true},
|
||||
{"origin": [35, 0, -8], "size": [5, 2, 4], "uv": [42, 146], "mirror": true}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,212 @@
|
||||
{
|
||||
"format_version": "1.12.0",
|
||||
"minecraft:geometry": [
|
||||
{
|
||||
"description": {
|
||||
"identifier": "geometry.unknown",
|
||||
"texture_width": 512,
|
||||
"texture_height": 512,
|
||||
"visible_bounds_width": 15,
|
||||
"visible_bounds_height": 5.5,
|
||||
"visible_bounds_offset": [0, 2.25, 0]
|
||||
},
|
||||
"bones": [
|
||||
{
|
||||
"name": "Hercules_beetle",
|
||||
"pivot": [0, 11.49286, 5.85714]
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"parent": "Hercules_beetle",
|
||||
"pivot": [0, 11.49286, 5.85714]
|
||||
},
|
||||
{
|
||||
"name": "torso",
|
||||
"parent": "body",
|
||||
"pivot": [0, 11.25, 0],
|
||||
"cubes": [
|
||||
{"origin": [-20, 11.2, -18], "size": [40, 31, 58], "uv": [0, 160]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "wingcase",
|
||||
"parent": "torso",
|
||||
"pivot": [0, 42.7, -19]
|
||||
},
|
||||
{
|
||||
"name": "left_wingcase",
|
||||
"parent": "wingcase",
|
||||
"pivot": [0, 42.7, -19],
|
||||
"cubes": [
|
||||
{"origin": [17, 41.2, -12], "size": [6, 14, 6], "pivot": [18, 50.2, -16], "rotation": [0, 0, 22.5], "uv": [156, 298]},
|
||||
{"origin": [0, 18.2, -19], "size": [21, 25, 60], "uv": [196, 160]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_wingcase",
|
||||
"parent": "wingcase",
|
||||
"pivot": [0, 42.7, -19],
|
||||
"cubes": [
|
||||
{"origin": [-21, 18.2, -19], "size": [21, 25, 60], "uv": [218, 0]},
|
||||
{"origin": [-23, 41.2, -12], "size": [6, 14, 6], "pivot": [-18, 50.2, -16], "rotation": [0, 0, -22.5], "uv": [334, 311]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_wing",
|
||||
"parent": "torso",
|
||||
"pivot": [0, 42.2, -18],
|
||||
"cubes": [
|
||||
{"origin": [-29, 42.275, -18], "size": [29, 0, 80], "pivot": [-3, 0, 0], "rotation": [0, -22.5, 0], "uv": [0, 0]},
|
||||
{"origin": [-29, 42.2, -18], "size": [29, 0, 80], "uv": [0, 80], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_wing",
|
||||
"parent": "torso",
|
||||
"pivot": [0, 42.2, -18],
|
||||
"cubes": [
|
||||
{"origin": [0, 42.275, -18], "size": [29, 0, 80], "pivot": [3, 0, 0], "rotation": [0, 22.5, 0], "uv": [0, 0], "mirror": true},
|
||||
{"origin": [0, 42.2, -18], "size": [29, 0, 80], "uv": [0, 80]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "neck",
|
||||
"parent": "torso",
|
||||
"pivot": [0, 26.2, -12],
|
||||
"cubes": [
|
||||
{"origin": [-18.5, 19.2, -33], "size": [37, 27, 24], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [218, 85]},
|
||||
{"origin": [-18.5, 39.2, -33], "size": [37, 7, 14], "inflate": 0.5, "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [320, 15]},
|
||||
{"origin": [-19.75, 22.2, -33], "size": [0, 24, 14], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [320, 22]},
|
||||
{"origin": [19.75, 22.2, -33], "size": [0, 24, 14], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [320, 22], "mirror": true},
|
||||
{"origin": [-18.5, 47.2, -24], "size": [37, 10, 5], "inflate": 0.5, "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [320, 0]},
|
||||
{"origin": [-17.5, 11.2, -30], "size": [35, 33, 18], "inflate": 0.05, "uv": [196, 245]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "basket_right",
|
||||
"parent": "neck",
|
||||
"pivot": [-24.5, 41.19827, -27.2321],
|
||||
"cubes": [
|
||||
{"origin": [-29, 37.2, -35], "size": [0, 12, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 42]},
|
||||
{"origin": [-20, 37.2, -35], "size": [0, 12, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 54]},
|
||||
{"origin": [-29, 37.2, -35], "size": [9, 12, 0], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 48]},
|
||||
{"origin": [-29, 37.2, -17], "size": [9, 12, 0], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 84]},
|
||||
{"origin": [-29, 37.2, -35], "size": [9, 0, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 42]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "basket_left",
|
||||
"parent": "neck",
|
||||
"pivot": [24.5, 41.19827, -27.2321],
|
||||
"cubes": [
|
||||
{"origin": [29, 37.2, -35], "size": [0, 12, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 42], "mirror": true},
|
||||
{"origin": [20, 37.2, -35], "size": [0, 12, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 54], "mirror": true},
|
||||
{"origin": [20, 37.2, -35], "size": [9, 12, 0], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 48], "mirror": true},
|
||||
{"origin": [20, 37.2, -17], "size": [9, 12, 0], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 84], "mirror": true},
|
||||
{"origin": [20, 37.2, -35], "size": [9, 0, 18], "pivot": [0, 32.2, -20.5], "rotation": [7.5, 0, 0], "uv": [380, 42], "mirror": true}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "head",
|
||||
"parent": "neck",
|
||||
"pivot": [0, 24.7, -27],
|
||||
"cubes": [
|
||||
{"origin": [-13.5, 9.2, -39], "size": [27, 31, 12], "uv": [182, 296]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "upper_mandibule",
|
||||
"parent": "head",
|
||||
"pivot": [0, 40.42222, -32.05556],
|
||||
"cubes": [
|
||||
{"origin": [-5.5, 32.2, -72], "size": [11, 16, 33], "uv": [94, 249]},
|
||||
{"origin": [-4.5, 32.2, -110], "size": [9, 11, 38], "uv": [0, 249]},
|
||||
{"origin": [-4.5, 32.2, -120], "size": [9, 11, 46], "inflate": 0.5, "uv": [140, 161]},
|
||||
{"origin": [-4.5, 26.2, -120], "size": [9, 17, 10], "uv": [72, 308]},
|
||||
{"origin": [-1.5, 25.2, -82], "size": [3, 7, 6], "uv": [288, 339]},
|
||||
{"origin": [-2.5, 48.2, -67], "size": [5, 13, 9], "uv": [110, 328]},
|
||||
{"origin": [-1.5, 61.2, -64], "size": [3, 8, 6], "uv": [270, 339]},
|
||||
{"origin": [-1, 56.2, -70], "size": [2, 4, 3], "uv": [182, 249]},
|
||||
{"origin": [-1, 48.2, -70], "size": [2, 4, 3], "uv": [182, 256]},
|
||||
{"origin": [-3.5, 16.2, -118], "size": [7, 10, 8], "uv": [334, 293]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "lower_mandibule",
|
||||
"parent": "head",
|
||||
"pivot": [0, 15.28333, -38.91667],
|
||||
"cubes": [
|
||||
{"origin": [-3.5, 10.2, -65], "size": [7, 10, 29], "uv": [0, 298]},
|
||||
{"origin": [-15.5, 10.2, -50], "size": [12, 0, 14], "pivot": [-7, 10.2, -50.5], "rotation": [37.5, 0, 0], "uv": [302, 255]},
|
||||
{"origin": [3.5, 10.2, -50], "size": [12, 0, 14], "pivot": [7, 10.2, -50.5], "rotation": [37.5, 0, 0], "uv": [302, 269]},
|
||||
{"origin": [-3.5, 7.2, -95], "size": [7, 13, 30], "uv": [260, 296]},
|
||||
{"origin": [-2.5, 10.2, -105], "size": [5, 10, 10], "uv": [138, 328]},
|
||||
{"origin": [-2.5, 20.2, -105], "size": [5, 10, 8], "uv": [334, 331]},
|
||||
{"origin": [-1.5, 20.2, -62], "size": [3, 6, 5], "uv": [306, 339]},
|
||||
{"origin": [-1.5, 20.2, -52], "size": [3, 6, 5], "uv": [340, 85]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg3",
|
||||
"parent": "body",
|
||||
"pivot": [-12.33333, 12.7, 5.5],
|
||||
"cubes": [
|
||||
{"origin": [-45.5, 11.2, 2], "size": [33, 3, 7], "inflate": 0.1, "uv": [218, 136]},
|
||||
{"origin": [-63.5, 11.2, 3], "size": [18, 0, 5], "uv": [302, 283]},
|
||||
{"origin": [-71.5, 11.2, 1], "size": [8, 0, 9], "uv": [72, 335]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg",
|
||||
"parent": "body",
|
||||
"pivot": [12.33333, 12.7, -21.5],
|
||||
"cubes": [
|
||||
{"origin": [12.5, 11.2, -25], "size": [33, 3, 7], "inflate": 0.1, "uv": [218, 146]},
|
||||
{"origin": [45.5, 11.2, -24], "size": [18, 0, 5], "uv": [302, 288]},
|
||||
{"origin": [63.5, 11.2, -26], "size": [8, 0, 9], "uv": [0, 337]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg",
|
||||
"parent": "body",
|
||||
"pivot": [-12.33333, 12.7, -21.5],
|
||||
"cubes": [
|
||||
{"origin": [-45.5, 11.2, -25], "size": [33, 3, 7], "inflate": 0.1, "uv": [72, 298]},
|
||||
{"origin": [-63.5, 11.2, -24], "size": [18, 0, 5], "uv": [110, 308]},
|
||||
{"origin": [-71.5, 11.2, -26], "size": [8, 0, 9], "uv": [34, 337]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg3",
|
||||
"parent": "body",
|
||||
"pivot": [12.33333, 12.7, 5.5],
|
||||
"cubes": [
|
||||
{"origin": [12.5, 11.2, 2], "size": [33, 3, 7], "inflate": 0.1, "uv": [298, 136]},
|
||||
{"origin": [45.5, 11.2, 3], "size": [18, 0, 5], "uv": [110, 313]},
|
||||
{"origin": [63.5, 11.2, 1], "size": [8, 0, 9], "uv": [168, 339]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "left_leg2",
|
||||
"parent": "body",
|
||||
"pivot": [12.33333, 12.7, -9.5],
|
||||
"cubes": [
|
||||
{"origin": [12.5, 11.2, -13], "size": [33, 3, 7], "inflate": 0.1, "uv": [298, 146]},
|
||||
{"origin": [45.5, 11.2, -12], "size": [18, 0, 5], "uv": [110, 318]},
|
||||
{"origin": [63.5, 11.2, -14], "size": [8, 0, 9], "uv": [202, 339]}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "right_leg2",
|
||||
"parent": "body",
|
||||
"pivot": [-12.33333, 12.7, -9.5],
|
||||
"cubes": [
|
||||
{"origin": [-45.5, 11.2, -13], "size": [33, 3, 7], "inflate": 0.1, "uv": [302, 245]},
|
||||
{"origin": [-63.5, 11.2, -12], "size": [18, 0, 5], "uv": [110, 323]},
|
||||
{"origin": [-71.5, 11.2, -14], "size": [8, 0, 9], "uv": [236, 339]}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -764,6 +764,14 @@
|
||||
"death.attack.toreterror_jump.player": "%1$s was pounded to death by Toreterror",
|
||||
"death.attack.water_soaked": "%1$s was super soaked to death by %2$s",
|
||||
"death.attack.water_soaked.player": "%1$s was super soaked to death by %2$s",
|
||||
"entity.antarchy.cheep": "Cheep",
|
||||
"entity.antarchy.dorrie": "Dorrie",
|
||||
"item.antarchy.cheep": "Cheep",
|
||||
"item.antarchy.cheep_on_a_stick": "Cheep on a Stick",
|
||||
"item.antarchy.cheep_spawn_egg": "Cheep Spawn Egg",
|
||||
"item.antarchy.dorrie_spawn_egg": "Dorrie Spawn Egg",
|
||||
"container.antarchy.dorrie": "Dorrie",
|
||||
"key.antarchy.dorrie_charge_jump": "Dorrie: Charge Jump",
|
||||
"entity.antarchy.reverie": "Reverie",
|
||||
"biome.antarchy.thoraxis": "Thoraxis",
|
||||
"biome.antarchy.nightmare_wastes": "Nightmare Wastes",
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"parent": "minecraft:item/template_spawn_egg"
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"parent": "minecraft:item/template_spawn_egg"
|
||||
}
|
||||
@@ -492,7 +492,16 @@
|
||||
"subtitle": "subtitles.antarchy.creeping_horror_bite",
|
||||
"sounds": [
|
||||
{
|
||||
"name": "antarchy:mob/creeping_horror/creeping_horror_bite"
|
||||
"name": "antarchy:mob/creeping_horror/creeping_horror_bite1"
|
||||
},
|
||||
{
|
||||
"name": "antarchy:mob/creeping_horror/creeping_horror_bite2"
|
||||
},
|
||||
{
|
||||
"name": "antarchy:mob/creeping_horror/creeping_horror_bite3"
|
||||
},
|
||||
{
|
||||
"name": "antarchy:mob/creeping_horror/creeping_horror_bite4"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 15 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 39 KiB |
|
After Width: | Height: | Size: 38 KiB |
@@ -87,6 +87,41 @@
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:mud_pie",
|
||||
"weight": 2
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 3
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 2
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 2
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -157,6 +157,41 @@
|
||||
],
|
||||
"name": "minecraft:candle",
|
||||
"weight": 8
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 6
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 4
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -187,6 +187,41 @@
|
||||
],
|
||||
"name": "antarchy:duct_tape",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 3
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 3
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -172,6 +172,41 @@
|
||||
],
|
||||
"name": "antarchy:duct_tape",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 3
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 3
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -166,6 +166,41 @@
|
||||
],
|
||||
"name": "antarchy:duct_tape",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 4
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 3
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 2.0
|
||||
},
|
||||
"function": "minecraft:set_count"
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 3
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 6,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -236,7 +236,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 6,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -247,6 +247,11 @@
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 4
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -92,7 +92,7 @@
|
||||
}
|
||||
],
|
||||
"name": "minecraft:diamond",
|
||||
"weight": 10
|
||||
"weight": 12
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
@@ -116,7 +116,7 @@
|
||||
}
|
||||
],
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 1
|
||||
"weight": 8
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
@@ -131,7 +131,12 @@
|
||||
}
|
||||
],
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 1
|
||||
"weight": 8
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 6
|
||||
}
|
||||
],
|
||||
"rolls": 1.0
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"type": "minecraft:entity",
|
||||
"pools": [
|
||||
{
|
||||
"rolls": 1.0,
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:cheep"
|
||||
}
|
||||
],
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
"count": {
|
||||
"type": "minecraft:uniform",
|
||||
"min": 1.0,
|
||||
"max": 1.0
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"random_sequence": "antarchy:entities/cheep"
|
||||
}
|
||||
@@ -172,7 +172,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:fallen_king_crown",
|
||||
"weight": 1,
|
||||
"weight": 6,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -187,7 +187,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 9,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -202,7 +202,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 9,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -213,6 +213,11 @@
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 9
|
||||
}
|
||||
],
|
||||
"rolls": {
|
||||
|
||||
@@ -170,7 +170,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:fallen_king_crown",
|
||||
"weight": 1,
|
||||
"weight": 4,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -185,7 +185,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:uranium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 7,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -200,7 +200,7 @@
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "antarchy:titanium_nugget",
|
||||
"weight": 1,
|
||||
"weight": 7,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
@@ -212,6 +212,11 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:golden_apple",
|
||||
"weight": 7
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "minecraft:diamond",
|
||||
|
||||
@@ -38,8 +38,7 @@
|
||||
[],
|
||||
[
|
||||
"antarchy:cavaryn_bile_veins",
|
||||
"antarchy:brooding_tunnels_creepvine",
|
||||
"antarchy:cavaryn_terror_egg_patch"
|
||||
"antarchy:brooding_tunnels_creepvine"
|
||||
],
|
||||
[
|
||||
"antarchy:cavaryn_bile_cysts"
|
||||
@@ -49,25 +48,19 @@
|
||||
"spawners": {
|
||||
"monster": [
|
||||
{
|
||||
"type": "antarchy:creeping_horror",
|
||||
"type": "antarchy:jumpy_bug",
|
||||
"weight": 95,
|
||||
"minCount": 2,
|
||||
"maxCount": 5
|
||||
"minCount": 1,
|
||||
"maxCount": 3
|
||||
},
|
||||
{
|
||||
"type": "antarchy:lurking_terror",
|
||||
"type": "antarchy:spit_bug",
|
||||
"weight": 95,
|
||||
"minCount": 2,
|
||||
"maxCount": 5
|
||||
}
|
||||
],
|
||||
"creature": [
|
||||
{
|
||||
"type": "antarchy:stink_bug",
|
||||
"weight": 10,
|
||||
"minCount": 1,
|
||||
"maxCount": 3
|
||||
}
|
||||
],
|
||||
"ambient": [],
|
||||
"axolotls": [],
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 8084735,
|
||||
"water_color": 5021432,
|
||||
"water_fog_color": 2502722,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 6245375,
|
||||
"water_color": 3461580,
|
||||
"water_fog_color": 1741620,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 8084735,
|
||||
"water_color": 5021432,
|
||||
"water_fog_color": 2502722,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 8084735,
|
||||
"water_color": 5021432,
|
||||
"water_fog_color": 2502722,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 8084735,
|
||||
"water_color": 5021432,
|
||||
"water_fog_color": 2502722,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"effects": {
|
||||
"fog_color": 8084735,
|
||||
"water_color": 5021432,
|
||||
"water_fog_color": 2502722,
|
||||
"water_fog_color": 736368,
|
||||
"sky_color": 8084735,
|
||||
"foliage_color": 2867501,
|
||||
"grass_color": 4304168,
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"type": "integrated_api:generic_structure",
|
||||
"start_pool": "antarchy:toreterror_arena/toreterror_arena",
|
||||
"size": 2,
|
||||
"valid_biome_radius_check": 5,
|
||||
"valid_biome_radius_check": 3,
|
||||
"biomes": "#antarchy:has_structure/toreterror_arena_biomes",
|
||||
"step": "surface_structures",
|
||||
"terrain_adaptation": "none",
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
"antarchy:cheep"
|
||||
]
|
||||
}
|
||||
@@ -264,6 +264,7 @@ public final class AntarchyFabricContent {
|
||||
private static final DeferredRegister<Potion> POTIONS = DeferredRegister.create(Registries.POTION, Antarchy.MODID);
|
||||
private static final DeferredRegister<SoundEvent> SOUND_EVENTS = DeferredRegister.create(Registries.SOUND_EVENT, Antarchy.MODID);
|
||||
private static final DeferredRegister<Fluid> FLUIDS = DeferredRegister.create(Registries.FLUID, Antarchy.MODID);
|
||||
private static final DeferredRegister<net.minecraft.world.inventory.MenuType<?>> MENUS = DeferredRegister.create(Registries.MENU, Antarchy.MODID);
|
||||
private static final Tier ULTIMATE_TIER = new SimpleToolTier(
|
||||
3072,
|
||||
10.5F,
|
||||
@@ -1808,6 +1809,26 @@ public final class AntarchyFabricContent {
|
||||
() -> new DeferredSpawnEggItem(CREEPING_HORROR, 0x6B3A1F, 0x6B0000, new Item.Properties()));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> LURKING_TERROR_SPAWN_EGG = ITEMS.register("lurking_terror_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(LURKING_TERROR, 0x2D5A1B, 0x8B0000, new Item.Properties()));
|
||||
|
||||
public static final DeferredHolder<EntityType<?>, EntityType<com.craisinlord.antarchy.content.entity.CheepEntity>> CHEEP = ENTITY_TYPES.register("cheep",
|
||||
() -> EntityType.Builder.of(com.craisinlord.antarchy.content.entity.CheepEntity::new, MobCategory.WATER_CREATURE)
|
||||
.sized(1.0F, 1.2F)
|
||||
.clientTrackingRange(8)
|
||||
.build("cheep"));
|
||||
public static final DeferredHolder<EntityType<?>, EntityType<com.craisinlord.antarchy.content.entity.DorrieEntity>> DORRIE = ENTITY_TYPES.register("dorrie",
|
||||
() -> EntityType.Builder.of(com.craisinlord.antarchy.content.entity.DorrieEntity::new, MobCategory.WATER_CREATURE)
|
||||
.sized(2.4F, 2.0F)
|
||||
.clientTrackingRange(10)
|
||||
.build("dorrie"));
|
||||
public static final DeferredItem<Item> CHEEP_ITEM = ITEMS.register("cheep",
|
||||
() -> new Item(new Item.Properties().food(new FoodProperties.Builder().nutrition(2).saturationModifier(0.2F).build())));
|
||||
public static final DeferredItem<com.craisinlord.antarchy.content.item.CheepOnAStickItem> CHEEP_ON_A_STICK = ITEMS.register("cheep_on_a_stick",
|
||||
() -> new com.craisinlord.antarchy.content.item.CheepOnAStickItem(new Item.Properties().stacksTo(1).durability(25)));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> CHEEP_SPAWN_EGG = ITEMS.register("cheep_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(CHEEP, 0xFF00AA, 0x00FF44, new Item.Properties()));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> DORRIE_SPAWN_EGG = ITEMS.register("dorrie_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(DORRIE, 0x1B91B3, 0xC0E8FF, new Item.Properties()));
|
||||
|
||||
public static final DeferredHolder<CreativeModeTab, CreativeModeTab> ANTARCHY_TAB = CREATIVE_MODE_TABS.register("antarchy",
|
||||
() -> CreativeModeTab.builder(CreativeModeTab.Row.TOP, 0)
|
||||
.title(net.minecraft.network.chat.Component.translatable("itemGroup.antarchy.antarchy"))
|
||||
@@ -1894,6 +1915,8 @@ public final class AntarchyFabricContent {
|
||||
FabricDefaultAttributeRegistry.register(TORETERROR.get(), ToreterrorEntity.createAttributes().build());
|
||||
FabricDefaultAttributeRegistry.register(CREEPING_HORROR.get(), CreepingHorrorEntity.createAttributes().build());
|
||||
FabricDefaultAttributeRegistry.register(LURKING_TERROR.get(), LurkingTerrorEntity.createAttributes().build());
|
||||
FabricDefaultAttributeRegistry.register(CHEEP.get(), com.craisinlord.antarchy.content.entity.CheepEntity.createAttributes().build());
|
||||
FabricDefaultAttributeRegistry.register(DORRIE.get(), com.craisinlord.antarchy.content.entity.DorrieEntity.createAttributes().build());
|
||||
|
||||
FabricDefaultAttributeRegistry.register(RED_ANT.get(), buildAntAttributes(
|
||||
AntarchySettings.redAntHealth(),
|
||||
@@ -2048,6 +2071,8 @@ public final class AntarchyFabricContent {
|
||||
"basilisk_spawn_egg", "emperor_scorpion_spawn_egg", "toreterror_spawn_egg",
|
||||
"creeping_horror_spawn_egg", "lurking_terror_spawn_egg" -> 90;
|
||||
case "stink_bug", "chiten" -> 22;
|
||||
case "cheep" -> 21;
|
||||
case "cheep_on_a_stick" -> 52;
|
||||
case "water_cannon" -> 52;
|
||||
case "primordial_helmet", "primordial_chestplate", "primordial_leggings", "primordial_boots" -> 53;
|
||||
case "jumpy_boots" -> 54;
|
||||
@@ -2329,8 +2354,12 @@ public final class AntarchyFabricContent {
|
||||
MOB_EFFECTS.register();
|
||||
POTIONS.register();
|
||||
ITEMS.register();
|
||||
MENUS.register();
|
||||
CREATIVE_MODE_TABS.register();
|
||||
|
||||
// Wire common-module accessors after all registrations are complete.
|
||||
AntarchyObjects.CHEEP_ITEM = () -> CHEEP_ITEM.get();
|
||||
|
||||
AntarchySoundEvents.bind(
|
||||
SQUIDZOOKA_FIRE,
|
||||
SHRINK_RAY_SOUND,
|
||||
@@ -2480,6 +2509,8 @@ public final class AntarchyFabricContent {
|
||||
CREEPING_HORROR,
|
||||
LURKING_TERROR,
|
||||
STINK_BUG,
|
||||
CHEEP,
|
||||
DORRIE,
|
||||
() -> DUPLICATOR_LOG.get(),
|
||||
() -> DUPLICATOR_SAPLING.get(),
|
||||
() -> DUCT_TAPE.get(),
|
||||
|
||||
@@ -49,6 +49,10 @@ public final class AntarchyFabricClientBootstrap {
|
||||
|
||||
public static void register() {
|
||||
AntarchyKeyBindings.register();
|
||||
net.minecraft.client.gui.screens.MenuScreens.register(
|
||||
com.craisinlord.antarchy.fabric.AntarchyFabricContent.DORRIE_MENU.get(),
|
||||
com.craisinlord.antarchy.content.client.screen.DorrieScreen::new
|
||||
);
|
||||
registerRenderers();
|
||||
registerEntityLayers();
|
||||
registerColors();
|
||||
@@ -113,6 +117,8 @@ public final class AntarchyFabricClientBootstrap {
|
||||
EntityRendererRegistry.register(AntarchyFabricContent.WATER_BOMB.get(), WaterBombRenderer::new);
|
||||
EntityRendererRegistry.register(AntarchyFabricContent.CREEPING_HORROR.get(), CreepingHorrorRenderer::new);
|
||||
EntityRendererRegistry.register(AntarchyFabricContent.LURKING_TERROR.get(), LurkingTerrorRenderer::new);
|
||||
EntityRendererRegistry.register(AntarchyFabricContent.CHEEP.get(), com.craisinlord.antarchy.content.client.renderer.CheepRenderer::new);
|
||||
EntityRendererRegistry.register(AntarchyFabricContent.DORRIE.get(), com.craisinlord.antarchy.content.client.renderer.DorrieRenderer::new);
|
||||
|
||||
EntityModelLayerRegistry.registerModelLayer(OuranwoodBoatRenderer.boatLayer(), BoatModel::createBodyModel);
|
||||
EntityModelLayerRegistry.registerModelLayer(OuranwoodBoatRenderer.chestBoatLayer(), ChestBoatModel::createBodyModel);
|
||||
@@ -325,6 +331,7 @@ public final class AntarchyFabricClientBootstrap {
|
||||
DreadClientHandler.tick();
|
||||
BloodCrystalKatanaTrailHandler.tick();
|
||||
ScorpionWhipTetherRenderHandler.tick();
|
||||
DorrieJumpClientHandler.tick();
|
||||
});
|
||||
|
||||
GravityGunClientHandler.register();
|
||||
@@ -342,6 +349,7 @@ public final class AntarchyFabricClientBootstrap {
|
||||
JumpyBootsHudRenderer.render(guiGraphics);
|
||||
BloodglassHudRenderer.render(guiGraphics);
|
||||
TriffidGooHudRenderer.render(guiGraphics);
|
||||
DorrieJumpHudRenderer.render(guiGraphics);
|
||||
});
|
||||
|
||||
WorldRenderEvents.AFTER_TRANSLUCENT.register(context -> {
|
||||
|
||||
@@ -17,13 +17,25 @@ public final class AntarchyKeyBindings {
|
||||
CATEGORY
|
||||
);
|
||||
|
||||
public static final KeyMapping DORRIE_CHARGE_JUMP = new KeyMapping(
|
||||
"key.antarchy.dorrie_charge_jump",
|
||||
InputConstants.Type.KEYSYM,
|
||||
GLFW.GLFW_KEY_LEFT_CONTROL,
|
||||
CATEGORY
|
||||
);
|
||||
|
||||
private AntarchyKeyBindings() {}
|
||||
|
||||
public static void register() {
|
||||
KeyBindingHelper.registerKeyBinding(BRUTALFLY_FLAP);
|
||||
KeyBindingHelper.registerKeyBinding(DORRIE_CHARGE_JUMP);
|
||||
}
|
||||
|
||||
public static boolean isBrutalflyFlapPressed() {
|
||||
return Minecraft.getInstance().screen == null && BRUTALFLY_FLAP.isDown();
|
||||
}
|
||||
|
||||
public static boolean isDorrieChargeJumpPressed() {
|
||||
return Minecraft.getInstance().screen == null && DORRIE_CHARGE_JUMP.isDown();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
package com.craisinlord.antarchy.fabric.client;
|
||||
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload;
|
||||
import com.craisinlord.antarchy.content.network.DorrieJumpInputPayload;
|
||||
import net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.player.LocalPlayer;
|
||||
|
||||
public final class DorrieJumpClientHandler {
|
||||
private static boolean wasPressingJump = false;
|
||||
private static boolean wasPressingCharge = false;
|
||||
|
||||
private DorrieJumpClientHandler() {}
|
||||
|
||||
public static void tick() {
|
||||
Minecraft mc = Minecraft.getInstance();
|
||||
LocalPlayer player = mc.player;
|
||||
|
||||
if (player == null || mc.screen != null) {
|
||||
resetAll();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!(player.getVehicle() instanceof DorrieEntity)) {
|
||||
resetAll();
|
||||
return;
|
||||
}
|
||||
|
||||
// Space bar → upward movement.
|
||||
boolean pressingJump = mc.options.keyJump.isDown();
|
||||
if (pressingJump != wasPressingJump) {
|
||||
ClientPlayNetworking.send(new DorrieJumpInputPayload(pressingJump));
|
||||
wasPressingJump = pressingJump;
|
||||
}
|
||||
|
||||
// Left ctrl → charge jump.
|
||||
boolean pressingCharge = AntarchyKeyBindings.isDorrieChargeJumpPressed();
|
||||
if (pressingCharge != wasPressingCharge) {
|
||||
ClientPlayNetworking.send(new DorrieChargeJumpPayload(pressingCharge));
|
||||
wasPressingCharge = pressingCharge;
|
||||
}
|
||||
}
|
||||
|
||||
private static void resetAll() {
|
||||
if (wasPressingJump) {
|
||||
ClientPlayNetworking.send(new DorrieJumpInputPayload(false));
|
||||
wasPressingJump = false;
|
||||
}
|
||||
if (wasPressingCharge) {
|
||||
ClientPlayNetworking.send(new DorrieChargeJumpPayload(false));
|
||||
wasPressingCharge = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.craisinlord.antarchy.fabric.client;
|
||||
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiGraphics;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.util.Mth;
|
||||
import net.minecraft.world.entity.player.Player;
|
||||
|
||||
public final class DorrieJumpHudRenderer {
|
||||
private static final ResourceLocation JUMP_BAR_BACKGROUND =
|
||||
ResourceLocation.withDefaultNamespace("textures/gui/sprites/hud/jump_bar_background.png");
|
||||
private static final ResourceLocation JUMP_BAR_PROGRESS =
|
||||
ResourceLocation.withDefaultNamespace("textures/gui/sprites/hud/jump_bar_progress.png");
|
||||
private static final int BAR_WIDTH = 182;
|
||||
private static final int BAR_HEIGHT = 5;
|
||||
|
||||
private DorrieJumpHudRenderer() {}
|
||||
|
||||
public static void render(GuiGraphics guiGraphics) {
|
||||
Minecraft mc = Minecraft.getInstance();
|
||||
Player player = mc.player;
|
||||
if (player == null || mc.screen != null || player.isDeadOrDying()) return;
|
||||
|
||||
if (!(player.getVehicle() instanceof DorrieEntity dorrie)) return;
|
||||
|
||||
int charge = dorrie.getJumpCharge();
|
||||
if (charge <= 0) return;
|
||||
|
||||
int width = mc.getWindow().getGuiScaledWidth();
|
||||
int height = mc.getWindow().getGuiScaledHeight();
|
||||
int x0 = width / 2 - BAR_WIDTH / 2;
|
||||
int y0 = height - 29;
|
||||
|
||||
guiGraphics.blit(JUMP_BAR_BACKGROUND, x0, y0, 0, 0, BAR_WIDTH, BAR_HEIGHT, BAR_WIDTH, BAR_HEIGHT);
|
||||
|
||||
float chargeRatio = Mth.clamp(charge / 100.0F, 0.0F, 1.0F);
|
||||
int filledWidth = Mth.clamp((int) (chargeRatio * BAR_WIDTH), 0, BAR_WIDTH);
|
||||
if (filledWidth > 0) {
|
||||
guiGraphics.setColor(0.2F, 0.8F, 1.0F, 0.4F + chargeRatio * 0.6F);
|
||||
guiGraphics.blit(JUMP_BAR_PROGRESS, x0, y0, 0, 0, filledWidth, BAR_HEIGHT, BAR_WIDTH, BAR_HEIGHT);
|
||||
guiGraphics.setColor(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -36,7 +36,7 @@ public abstract class ToreterrorCameraShakeMixin {
|
||||
)) {
|
||||
double distance = Math.sqrt(cameraPos.distanceToSqr(toreterror.position().add(0, toreterror.getBbHeight() * 0.5, 0)));
|
||||
if (distance > MAX_SHAKE_RANGE) continue;
|
||||
shakeStrength += (float) ((1.0D - distance / MAX_SHAKE_RANGE) * 2.0F);
|
||||
shakeStrength += (float) ((1.0D - distance / MAX_SHAKE_RANGE) * 1.0F);
|
||||
}
|
||||
|
||||
if (BigBerthaItem.clientShakeTicks > 0) {
|
||||
|
||||
@@ -12,6 +12,8 @@ import com.craisinlord.antarchy.fabric.util.JumpyBootsFabricHelper;
|
||||
import com.craisinlord.antarchy.content.item.JumpyBootsItem;
|
||||
import com.craisinlord.antarchy.content.item.GravityGunItem;
|
||||
import com.craisinlord.antarchy.content.network.*;
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import com.craisinlord.antarchy.content.network.DorrieJumpInputPayload;
|
||||
import com.craisinlord.antarchy.content.network.JumpyBootsLaunchPayload;
|
||||
import com.craisinlord.antarchy.content.weather.ThoraxisWeatherSnapshot;
|
||||
import net.fabricmc.fabric.api.networking.v1.PayloadTypeRegistry;
|
||||
@@ -51,6 +53,8 @@ public final class AntarchyFabricNetworking {
|
||||
PayloadTypeRegistry.playC2S().register(DiamondMinecartInputPayload.TYPE, DiamondMinecartInputPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(BrutalflyElytraFlapPayload.TYPE, BrutalflyElytraFlapPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(JumpyBootsLaunchPayload.TYPE, JumpyBootsLaunchPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(DorrieJumpInputPayload.TYPE, DorrieJumpInputPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload.TYPE, com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(MultipartAttackPayload.TYPE, MultipartAttackPayload.STREAM_CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(MultipartInteractPayload.TYPE, MultipartInteractPayload.STREAM_CODEC);
|
||||
}
|
||||
@@ -66,6 +70,10 @@ public final class AntarchyFabricNetworking {
|
||||
context.server().execute(() -> handleBrutalflyFlap(context.player(), payload)));
|
||||
ServerPlayNetworking.registerGlobalReceiver(JumpyBootsLaunchPayload.TYPE, (payload, context) ->
|
||||
context.server().execute(() -> handleJumpyBootsLaunch(context.player(), payload)));
|
||||
ServerPlayNetworking.registerGlobalReceiver(DorrieJumpInputPayload.TYPE, (payload, context) ->
|
||||
context.server().execute(() -> handleDorrieJumpInput(context.player(), payload)));
|
||||
ServerPlayNetworking.registerGlobalReceiver(com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload.TYPE, (payload, context) ->
|
||||
context.server().execute(() -> handleDorrieChargeJumpInput(context.player(), payload)));
|
||||
ServerPlayNetworking.registerGlobalReceiver(MultipartAttackPayload.TYPE, (payload, context) ->
|
||||
context.server().execute(() -> handleMultipartAttack(context.player(), payload)));
|
||||
ServerPlayNetworking.registerGlobalReceiver(MultipartInteractPayload.TYPE, (payload, context) ->
|
||||
@@ -306,4 +314,18 @@ public final class AntarchyFabricNetworking {
|
||||
|
||||
player.getCooldowns().addCooldown(boots.getItem(), JumpyBootsHelper.COOLDOWN_TICKS);
|
||||
}
|
||||
|
||||
private static void handleDorrieJumpInput(ServerPlayer player, DorrieJumpInputPayload payload) {
|
||||
if (!(player.getVehicle() instanceof DorrieEntity dorrie)) return;
|
||||
dorrie.setPressingJump(payload.pressing());
|
||||
}
|
||||
|
||||
private static void handleDorrieChargeJumpInput(ServerPlayer player, com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload payload) {
|
||||
if (!(player.getVehicle() instanceof DorrieEntity dorrie)) return;
|
||||
if (payload.pressing()) {
|
||||
dorrie.startJumpCharge();
|
||||
} else {
|
||||
dorrie.releaseJump();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -166,6 +166,9 @@ public final class AntarchyConfigModuleNeoforge {
|
||||
AntarchySettings.setCreepingHorrorAttackDamage(AntarchyMobsConfig.creepingHorrorAttackDamage());
|
||||
AntarchySettings.setLurkingTerrorHealth(AntarchyMobsConfig.lurkingTerrorHealth());
|
||||
AntarchySettings.setLurkingTerrorAttackDamage(AntarchyMobsConfig.lurkingTerrorAttackDamage());
|
||||
AntarchySettings.setCheepHealth(AntarchyMobsConfig.cheepHealth());
|
||||
AntarchySettings.setCheepAttackDamage(AntarchyMobsConfig.cheepAttackDamage());
|
||||
AntarchySettings.setDorrieHealth(AntarchyMobsConfig.dorrieHealth());
|
||||
}
|
||||
|
||||
private static void bakeToolsConfig() {
|
||||
|
||||
@@ -182,6 +182,17 @@ public final class AntarchyMobsConfig {
|
||||
private static final ModConfigSpec.DoubleValue LURKING_TERROR_ATTACK_DAMAGE;
|
||||
|
||||
|
||||
// Cheep
|
||||
|
||||
private static final ModConfigSpec.DoubleValue CHEEP_HEALTH;
|
||||
private static final ModConfigSpec.DoubleValue CHEEP_ATTACK_DAMAGE;
|
||||
|
||||
|
||||
// Dorrie
|
||||
|
||||
private static final ModConfigSpec.DoubleValue DORRIE_HEALTH;
|
||||
|
||||
|
||||
// Lucid
|
||||
|
||||
private static final ModConfigSpec.DoubleValue LUCID_ATTACK_RANGE;
|
||||
@@ -473,6 +484,15 @@ public final class AntarchyMobsConfig {
|
||||
LURKING_TERROR_ATTACK_DAMAGE = b.comment("Base attack damage.").defineInRange("attackDamage", 6.0D, 0.0D, 1024.0D);
|
||||
b.pop();
|
||||
|
||||
b.push("cheep");
|
||||
CHEEP_HEALTH = b.comment("Base max health.").defineInRange("health", 8.0D, 1.0D, 32768.0D);
|
||||
CHEEP_ATTACK_DAMAGE = b.comment("Base attack damage.").defineInRange("attackDamage", 3.0D, 0.0D, 1024.0D);
|
||||
b.pop();
|
||||
|
||||
b.push("dorrie");
|
||||
DORRIE_HEALTH = b.comment("Base max health.").defineInRange("health", 60.0D, 1.0D, 32768.0D);
|
||||
b.pop();
|
||||
|
||||
b.push("toreterror");
|
||||
TORETERROR_HEALTH = b.comment("Base max health.").defineInRange("health", 300.0D, 1.0D, 32768.0D);
|
||||
TORETERROR_JUMP_ATTACK_DAMAGE = b.comment("Damage dealt by the jump shockwave.").defineInRange("jumpAttackDamage", 14.0D, 0.0D, 1024.0D);
|
||||
@@ -629,4 +649,7 @@ public final class AntarchyMobsConfig {
|
||||
static double creepingHorrorAttackDamage() { return CREEPING_HORROR_ATTACK_DAMAGE.get(); }
|
||||
static double lurkingTerrorHealth() { return LURKING_TERROR_HEALTH.get(); }
|
||||
static double lurkingTerrorAttackDamage() { return LURKING_TERROR_ATTACK_DAMAGE.get(); }
|
||||
static double cheepHealth() { return CHEEP_HEALTH.get(); }
|
||||
static double cheepAttackDamage() { return CHEEP_ATTACK_DAMAGE.get(); }
|
||||
static double dorrieHealth() { return DORRIE_HEALTH.get(); }
|
||||
}
|
||||
@@ -197,6 +197,8 @@ public class AntarchyNeoforge {
|
||||
AntarchyNeoforgeEntites.CREEPING_HORROR,
|
||||
AntarchyNeoforgeEntites.LURKING_TERROR,
|
||||
AntarchyNeoforgeEntites.STINK_BUG,
|
||||
AntarchyNeoforgeEntites.CHEEP,
|
||||
AntarchyNeoforgeEntites.DORRIE,
|
||||
() -> AntarchyNeoforgeBlocks.DUPLICATOR_LOG.get(),
|
||||
() -> AntarchyNeoforgeBlocks.DUPLICATOR_SAPLING.get(),
|
||||
() -> AntarchyNeoforgeBlocks.DUCT_TAPE.get(),
|
||||
|
||||
@@ -21,10 +21,19 @@ public final class AntarchyKeyBindings {
|
||||
CATEGORY
|
||||
);
|
||||
|
||||
public static final KeyMapping DORRIE_CHARGE_JUMP = new KeyMapping(
|
||||
"key.antarchy.dorrie_charge_jump",
|
||||
KeyConflictContext.IN_GAME,
|
||||
InputConstants.Type.KEYSYM,
|
||||
InputConstants.KEY_LCONTROL,
|
||||
CATEGORY
|
||||
);
|
||||
|
||||
private AntarchyKeyBindings() {}
|
||||
|
||||
@SubscribeEvent
|
||||
public static void onRegisterKeyMappings(RegisterKeyMappingsEvent event) {
|
||||
event.register(BRUTALFLY_FLAP);
|
||||
event.register(DORRIE_CHARGE_JUMP);
|
||||
}
|
||||
}
|
||||
@@ -130,6 +130,8 @@ public final class AntarchyNeoForgeClient {
|
||||
event.registerEntityRenderer(AntarchyNeoforgeEntites.WATER_BOMB.get(), WaterBombRenderer::new);
|
||||
event.registerEntityRenderer(AntarchyNeoforgeEntites.CREEPING_HORROR.get(), CreepingHorrorRenderer::new);
|
||||
event.registerEntityRenderer(AntarchyNeoforgeEntites.LURKING_TERROR.get(), LurkingTerrorRenderer::new);
|
||||
event.registerEntityRenderer(AntarchyNeoforgeEntites.CHEEP.get(), context -> withParalyzedGeoLayer(new com.craisinlord.antarchy.content.client.renderer.CheepRenderer(context)));
|
||||
event.registerEntityRenderer(AntarchyNeoforgeEntites.DORRIE.get(), context -> withParalyzedGeoLayer(new com.craisinlord.antarchy.content.client.renderer.DorrieRenderer(context)));
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
@@ -248,6 +250,10 @@ public final class AntarchyNeoForgeClient {
|
||||
ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "jumpy_boots"),
|
||||
(guiGraphics, partialTick) -> JumpyBootsHudRenderer.render(guiGraphics)
|
||||
);
|
||||
event.registerAboveAll(
|
||||
ResourceLocation.fromNamespaceAndPath(Antarchy.MODID, "dorrie_jump"),
|
||||
(guiGraphics, partialTick) -> DorrieJumpHudRenderer.render(guiGraphics)
|
||||
);
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
package com.craisinlord.antarchy.neoforge.client;
|
||||
|
||||
import com.craisinlord.antarchy.Antarchy;
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload;
|
||||
import com.craisinlord.antarchy.content.network.DorrieJumpInputPayload;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.player.LocalPlayer;
|
||||
import net.neoforged.api.distmarker.Dist;
|
||||
import net.neoforged.bus.api.SubscribeEvent;
|
||||
import net.neoforged.fml.common.EventBusSubscriber;
|
||||
import net.neoforged.neoforge.client.event.ClientTickEvent;
|
||||
import net.neoforged.neoforge.network.PacketDistributor;
|
||||
|
||||
@EventBusSubscriber(modid = Antarchy.MODID, value = Dist.CLIENT)
|
||||
public final class DorrieJumpClientHandler {
|
||||
private static boolean wasPressingJump = false;
|
||||
private static boolean wasPressingCharge = false;
|
||||
|
||||
private DorrieJumpClientHandler() {}
|
||||
|
||||
@SubscribeEvent
|
||||
public static void onClientTick(ClientTickEvent.Post event) {
|
||||
Minecraft mc = Minecraft.getInstance();
|
||||
LocalPlayer player = mc.player;
|
||||
|
||||
if (player == null || mc.screen != null) {
|
||||
resetAll();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!(player.getVehicle() instanceof DorrieEntity)) {
|
||||
resetAll();
|
||||
return;
|
||||
}
|
||||
|
||||
boolean pressingJump = mc.options.keyJump.isDown();
|
||||
if (pressingJump != wasPressingJump) {
|
||||
PacketDistributor.sendToServer(new DorrieJumpInputPayload(pressingJump));
|
||||
wasPressingJump = pressingJump;
|
||||
}
|
||||
|
||||
boolean pressingCharge = AntarchyKeyBindings.DORRIE_CHARGE_JUMP.isDown();
|
||||
if (pressingCharge != wasPressingCharge) {
|
||||
PacketDistributor.sendToServer(new DorrieChargeJumpPayload(pressingCharge));
|
||||
wasPressingCharge = pressingCharge;
|
||||
}
|
||||
}
|
||||
|
||||
private static void resetAll() {
|
||||
if (wasPressingJump) {
|
||||
PacketDistributor.sendToServer(new DorrieJumpInputPayload(false));
|
||||
wasPressingJump = false;
|
||||
}
|
||||
if (wasPressingCharge) {
|
||||
PacketDistributor.sendToServer(new DorrieChargeJumpPayload(false));
|
||||
wasPressingCharge = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
package com.craisinlord.antarchy.neoforge.client;
|
||||
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiGraphics;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.util.Mth;
|
||||
import net.minecraft.world.entity.Entity;
|
||||
import net.minecraft.world.entity.player.Player;
|
||||
|
||||
public final class DorrieJumpHudRenderer {
|
||||
private static final ResourceLocation JUMP_BAR_BACKGROUND =
|
||||
ResourceLocation.withDefaultNamespace("textures/gui/sprites/hud/jump_bar_background.png");
|
||||
private static final ResourceLocation JUMP_BAR_PROGRESS =
|
||||
ResourceLocation.withDefaultNamespace("textures/gui/sprites/hud/jump_bar_progress.png");
|
||||
private static final int BAR_WIDTH = 182;
|
||||
private static final int BAR_HEIGHT = 5;
|
||||
|
||||
private DorrieJumpHudRenderer() {}
|
||||
|
||||
public static void render(GuiGraphics guiGraphics) {
|
||||
Minecraft mc = Minecraft.getInstance();
|
||||
Player player = mc.player;
|
||||
if (player == null || mc.screen != null || player.isDeadOrDying()) return;
|
||||
|
||||
Entity vehicle = player.getVehicle();
|
||||
if (!(vehicle instanceof DorrieEntity dorrie)) return;
|
||||
|
||||
int charge = dorrie.getJumpCharge();
|
||||
if (charge <= 0) return;
|
||||
|
||||
int width = mc.getWindow().getGuiScaledWidth();
|
||||
int height = mc.getWindow().getGuiScaledHeight();
|
||||
int x0 = width / 2 - BAR_WIDTH / 2;
|
||||
int y0 = height - 29;
|
||||
|
||||
guiGraphics.blit(JUMP_BAR_BACKGROUND, x0, y0, 0, 0, BAR_WIDTH, BAR_HEIGHT, BAR_WIDTH, BAR_HEIGHT);
|
||||
|
||||
float chargeRatio = Mth.clamp(charge / 100.0F, 0.0F, 1.0F);
|
||||
int filledWidth = Mth.clamp((int) (chargeRatio * BAR_WIDTH), 0, BAR_WIDTH);
|
||||
if (filledWidth > 0) {
|
||||
guiGraphics.setColor(0.2F, 0.8F, 1.0F, 0.4F + chargeRatio * 0.6F);
|
||||
guiGraphics.blit(JUMP_BAR_PROGRESS, x0, y0, 0, 0, filledWidth, BAR_HEIGHT, BAR_WIDTH, BAR_HEIGHT);
|
||||
guiGraphics.setColor(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,7 +34,7 @@ public final class ToreterrorCameraShakeHandler {
|
||||
)) {
|
||||
double distance = Math.sqrt(cameraPos.distanceToSqr(toreterror.position().add(0, toreterror.getBbHeight() * 0.5, 0)));
|
||||
if (distance > MAX_SHAKE_RANGE) continue;
|
||||
shakeStrength += (float) ((1.0D - distance / MAX_SHAKE_RANGE) * 2.0D);
|
||||
shakeStrength += (float) ((1.0D - distance / MAX_SHAKE_RANGE) * 1.0D);
|
||||
}
|
||||
|
||||
if (BigBerthaItem.clientShakeTicks > 0) {
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.craisinlord.antarchy.neoforge.network;
|
||||
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import com.craisinlord.antarchy.content.network.DorrieChargeJumpPayload;
|
||||
import com.craisinlord.antarchy.content.network.DorrieJumpInputPayload;
|
||||
import net.minecraft.server.level.ServerPlayer;
|
||||
import net.neoforged.neoforge.network.handling.IPayloadContext;
|
||||
import net.neoforged.neoforge.network.registration.PayloadRegistrar;
|
||||
|
||||
public final class DorrieJumpNetworking {
|
||||
private DorrieJumpNetworking() {}
|
||||
|
||||
public static void register(PayloadRegistrar registrar) {
|
||||
registrar.playToServer(
|
||||
DorrieJumpInputPayload.TYPE,
|
||||
DorrieJumpInputPayload.STREAM_CODEC,
|
||||
DorrieJumpNetworking::handleJumpInput
|
||||
);
|
||||
registrar.playToServer(
|
||||
DorrieChargeJumpPayload.TYPE,
|
||||
DorrieChargeJumpPayload.STREAM_CODEC,
|
||||
DorrieJumpNetworking::handleChargeInput
|
||||
);
|
||||
}
|
||||
|
||||
private static void handleJumpInput(DorrieJumpInputPayload payload, IPayloadContext context) {
|
||||
context.enqueueWork(() -> {
|
||||
if (!(context.player() instanceof ServerPlayer player)) return;
|
||||
if (!(player.getVehicle() instanceof DorrieEntity dorrie)) return;
|
||||
dorrie.setPressingJump(payload.pressing());
|
||||
});
|
||||
}
|
||||
|
||||
private static void handleChargeInput(DorrieChargeJumpPayload payload, IPayloadContext context) {
|
||||
context.enqueueWork(() -> {
|
||||
if (!(context.player() instanceof ServerPlayer player)) return;
|
||||
if (!(player.getVehicle() instanceof DorrieEntity dorrie)) return;
|
||||
if (payload.pressing()) {
|
||||
dorrie.startJumpCharge();
|
||||
} else {
|
||||
dorrie.releaseJump();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -115,6 +115,7 @@ public class AntarchyNeoforgeCreativeModeTabs {
|
||||
}
|
||||
|
||||
if (event.getTabKey() == CreativeModeTabs.TOOLS_AND_UTILITIES) {
|
||||
event.accept(AntarchyNeoforgeItems.CHEEP_ON_A_STICK.get());
|
||||
event.insertAfter(new ItemStack(Items.SHEARS), new ItemStack(AntarchyNeoforgeItems.DUCT_TAPE_ITEM.get()), CreativeModeTab.TabVisibility.PARENT_AND_SEARCH_TABS);
|
||||
event.insertAfter(new ItemStack(Items.MINECART), new ItemStack(AntarchyNeoforgeItems.DIAMOND_MINECART_ITEM.get()), CreativeModeTab.TabVisibility.PARENT_AND_SEARCH_TABS);
|
||||
event.accept(AntarchyNeoforgeItems.BILE_BUCKET.get());
|
||||
@@ -144,6 +145,7 @@ 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());
|
||||
@@ -407,7 +409,7 @@ public class AntarchyNeoforgeCreativeModeTabs {
|
||||
|
||||
// 15 - Tools
|
||||
case "ultimate_pickaxe", "ultimate_axe", "ultimate_shovel", "ultimate_hoe",
|
||||
"duct_tape", "diamond_minecart", "gravity_sculk_sensor" -> 15;
|
||||
"duct_tape", "diamond_minecart", "gravity_sculk_sensor", "cheep_on_a_stick" -> 15;
|
||||
|
||||
// 16 - Liquid buckets
|
||||
case "bile_bucket", "ichor_bucket", "antiwater_bucket", "cloud_bucket" -> 16;
|
||||
@@ -435,7 +437,7 @@ public class AntarchyNeoforgeCreativeModeTabs {
|
||||
case "ultimate_bow", "ultimate_crossbow" -> 20;
|
||||
|
||||
// 21 - Foods
|
||||
case "cloud_shark_fin_soup", "mud_pie", "rainbow_sugar",
|
||||
case "cloud_shark_fin_soup", "mud_pie", "cheep", "rainbow_sugar",
|
||||
"blood_crystal_apple" -> 21;
|
||||
|
||||
// 22 - Crafting ingredients
|
||||
|
||||
@@ -46,7 +46,9 @@ import com.craisinlord.antarchy.content.entity.lucid.LucidBoltEntity;
|
||||
import com.craisinlord.antarchy.content.entity.lucid.LucidEntity;
|
||||
import com.craisinlord.antarchy.content.entity.lucid.LucidEyeProjectileEntity;
|
||||
import com.craisinlord.antarchy.content.entity.nightmare.NightmareEntity;
|
||||
import com.craisinlord.antarchy.content.entity.CheepEntity;
|
||||
import com.craisinlord.antarchy.content.entity.CreepingHorrorEntity;
|
||||
import com.craisinlord.antarchy.content.entity.DorrieEntity;
|
||||
import com.craisinlord.antarchy.content.entity.LurkingTerrorEntity;
|
||||
import com.craisinlord.antarchy.content.entity.ToreterrorEntity;
|
||||
import com.craisinlord.antarchy.content.entity.WaterBombEntity;
|
||||
@@ -299,6 +301,16 @@ public final class AntarchyNeoforgeEntites {
|
||||
.sized(1.3F, 1.5F)
|
||||
.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)
|
||||
.sized(1.0F, 1.2F)
|
||||
.clientTrackingRange(8)
|
||||
.build("cheep"));
|
||||
public static final DeferredHolder<EntityType<?>, EntityType<DorrieEntity>> DORRIE = ENTITY_TYPES.register("dorrie",
|
||||
() -> EntityType.Builder.of(DorrieEntity::new, MobCategory.WATER_CREATURE)
|
||||
.sized(2.4F, 2.0F)
|
||||
.clientTrackingRange(10)
|
||||
.build("dorrie"));
|
||||
public static final DeferredHolder<EntityType<?>, EntityType<UpwardFallingBlockEntity>> UPWARD_FALLING_BLOCK = ENTITY_TYPES.register("upward_falling_block",
|
||||
() -> EntityType.Builder.<UpwardFallingBlockEntity>of(
|
||||
UpwardFallingBlockEntity::new, MobCategory.MISC)
|
||||
|
||||
@@ -72,6 +72,8 @@ public class AntarchyNeoforgeEntityAttributes {
|
||||
event.put(AntarchyNeoforgeEntites.TERMITE.get(), termiteAttributes);
|
||||
event.put(AntarchyNeoforgeEntites.MOLEWORM.get(), MolewormEntity.createAttributes().build());
|
||||
event.put(AntarchyNeoforgeEntites.MOLEVORE.get(), MolevoreEntity.createAttributes().build());
|
||||
event.put(AntarchyNeoforgeEntites.CHEEP.get(), com.craisinlord.antarchy.content.entity.CheepEntity.createAttributes().build());
|
||||
event.put(AntarchyNeoforgeEntites.DORRIE.get(), com.craisinlord.antarchy.content.entity.DorrieEntity.createAttributes().build());
|
||||
}
|
||||
|
||||
private static AttributeSupplier.Builder buildAntAttributes(double health, double speed, double attackDamage) {
|
||||
|
||||
@@ -7,6 +7,7 @@ import com.craisinlord.antarchy.content.block.entity.PotentNyxiteBlockEntity;
|
||||
import com.craisinlord.antarchy.content.block.entity.WaspNestBlockEntity;
|
||||
import com.craisinlord.antarchy.content.entity.SizeRayProjectileEntity;
|
||||
import com.craisinlord.antarchy.content.item.*;
|
||||
import com.craisinlord.antarchy.content.item.CheepOnAStickItem;
|
||||
import com.craisinlord.antarchy.content.item.BloodCrystalArmorItem;
|
||||
import com.craisinlord.antarchy.content.item.BloodCrystalAppleItem;
|
||||
import com.craisinlord.antarchy.content.item.BloodCrystalKatanaItem;
|
||||
@@ -362,6 +363,14 @@ 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<CheepOnAStickItem> CHEEP_ON_A_STICK = ITEMS.register("cheep_on_a_stick",
|
||||
() -> new CheepOnAStickItem(new Item.Properties().stacksTo(1).durability(25)));
|
||||
public static final DeferredItem<Item> MOLEWORM_ITEM = ITEMS.register("moleworm",
|
||||
() -> new Item(new Item.Properties()
|
||||
.food(new FoodProperties.Builder()
|
||||
@@ -578,6 +587,10 @@ public final class AntarchyNeoforgeItems {
|
||||
() -> new DeferredSpawnEggItem(AntarchyNeoforgeEntites.CREEPING_HORROR, 0x6B3A1F, 0x6B0000, new Item.Properties()));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> LURKING_TERROR_SPAWN_EGG = ITEMS.register("lurking_terror_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(AntarchyNeoforgeEntites.LURKING_TERROR, 0x2D5A1B, 0x8B0000, new Item.Properties()));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> CHEEP_SPAWN_EGG = ITEMS.register("cheep_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(AntarchyNeoforgeEntites.CHEEP, 0xAA22FF, 0x22FF44, new Item.Properties()));
|
||||
public static final DeferredItem<DeferredSpawnEggItem> DORRIE_SPAWN_EGG = ITEMS.register("dorrie_spawn_egg",
|
||||
() -> new DeferredSpawnEggItem(AntarchyNeoforgeEntites.DORRIE, 0x1B91B3, 0xC0E8FF, new Item.Properties()));
|
||||
|
||||
private AntarchyNeoforgeItems() {}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.craisinlord.antarchy.neoforge.registry;
|
||||
import com.craisinlord.antarchy.content.network.BloodCrystalKatanaTrailPayload;
|
||||
import com.craisinlord.antarchy.neoforge.network.AntarchyGravityNetworking;
|
||||
import com.craisinlord.antarchy.neoforge.network.BrutalflyElytraNetworking;
|
||||
import com.craisinlord.antarchy.neoforge.network.DorrieJumpNetworking;
|
||||
import com.craisinlord.antarchy.neoforge.network.JumpyBootsNetworking;
|
||||
import com.craisinlord.antarchy.neoforge.network.MultipartNetworking;
|
||||
import net.neoforged.bus.api.IEventBus;
|
||||
@@ -20,6 +21,7 @@ public class AntarchyNeoforgePayloadHandlers {
|
||||
AntarchyGravityNetworking.register(registrar);
|
||||
BrutalflyElytraNetworking.register(registrar);
|
||||
JumpyBootsNetworking.register(registrar);
|
||||
DorrieJumpNetworking.register(registrar);
|
||||
registrar.playToClient(
|
||||
com.craisinlord.antarchy.content.network.BloodglassStatePayload.TYPE,
|
||||
com.craisinlord.antarchy.content.network.BloodglassStatePayload.STREAM_CODEC,
|
||||
|
||||