starts to add mawsonia and alligator gar as well as scale debug
This commit is contained in:
@@ -116,6 +116,8 @@ public class CommonClientClass {
|
|||||||
EntityRendererRegistry.register(ModEntities.MUSSASAURUS, MussasaurusRenderer::new);
|
EntityRendererRegistry.register(ModEntities.MUSSASAURUS, MussasaurusRenderer::new);
|
||||||
EntityRendererRegistry.register(ModEntities.THESCELOSAURUS, ThescelosaurusRenderer::new);
|
EntityRendererRegistry.register(ModEntities.THESCELOSAURUS, ThescelosaurusRenderer::new);
|
||||||
EntityRendererRegistry.register(ModEntities.COELACANTH, CoelacanthRenderer::new);
|
EntityRendererRegistry.register(ModEntities.COELACANTH, CoelacanthRenderer::new);
|
||||||
|
EntityRendererRegistry.register(ModEntities.MAWSONIA, MawsoniaRenderer::new);
|
||||||
|
EntityRendererRegistry.register(ModEntities.ALLIGATOR_GAR, AlligatorGarRenderer::new);
|
||||||
|
|
||||||
if (Platform.isFabric()) {
|
if (Platform.isFabric()) {
|
||||||
registerSpawnEggColors();
|
registerSpawnEggColors();
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ public class Constants
|
|||||||
public static final String MOD_NAME = "JurassicRevived";
|
public static final String MOD_NAME = "JurassicRevived";
|
||||||
public static final Logger LOG = LoggerFactory.getLogger(MOD_NAME);
|
public static final Logger LOG = LoggerFactory.getLogger(MOD_NAME);
|
||||||
|
|
||||||
public static final boolean DEBUG_SIZES = false;
|
public static final boolean DEBUG_SIZES = true;
|
||||||
|
|
||||||
public static ResourceLocation rl(String path) {
|
public static ResourceLocation rl(String path) {
|
||||||
//? if >1.20.1 {
|
//? if >1.20.1 {
|
||||||
|
|||||||
@@ -355,6 +355,14 @@ public class ModEntities {
|
|||||||
ENTITIES.register("coelacanth", () -> EntityType.Builder.of(CoelacanthEntity::new, MobCategory.CREATURE)
|
ENTITIES.register("coelacanth", () -> EntityType.Builder.of(CoelacanthEntity::new, MobCategory.CREATURE)
|
||||||
.sized(1.3f, 1.8f).build("coelacanth"));
|
.sized(1.3f, 1.8f).build("coelacanth"));
|
||||||
|
|
||||||
|
public static final RegistrySupplier<EntityType<MawsoniaEntity>> MAWSONIA =
|
||||||
|
ENTITIES.register("mawsonia", () -> EntityType.Builder.of(MawsoniaEntity::new, MobCategory.CREATURE)
|
||||||
|
.sized(1.3f, 1.8f).build("mawsonia"));
|
||||||
|
|
||||||
|
public static final RegistrySupplier<EntityType<AlligatorGarEntity>> ALLIGATOR_GAR =
|
||||||
|
ENTITIES.register("alligator_gar", () -> EntityType.Builder.of(AlligatorGarEntity::new, MobCategory.CREATURE)
|
||||||
|
.sized(1.3f, 1.8f).build("alligator_gar"));
|
||||||
|
|
||||||
public static void registerAttributes() {
|
public static void registerAttributes() {
|
||||||
EntityAttributeRegistry.register(APATOSAURUS, ApatosaurusEntity::createAttributes);
|
EntityAttributeRegistry.register(APATOSAURUS, ApatosaurusEntity::createAttributes);
|
||||||
EntityAttributeRegistry.register(ALBERTOSAURUS, AlbertosaurusEntity::createAttributes);
|
EntityAttributeRegistry.register(ALBERTOSAURUS, AlbertosaurusEntity::createAttributes);
|
||||||
@@ -437,6 +445,8 @@ public class ModEntities {
|
|||||||
EntityAttributeRegistry.register(MUSSASAURUS, MussasaurusEntity::createAttributes);
|
EntityAttributeRegistry.register(MUSSASAURUS, MussasaurusEntity::createAttributes);
|
||||||
EntityAttributeRegistry.register(THESCELOSAURUS, ThescelosaurusEntity::createAttributes);
|
EntityAttributeRegistry.register(THESCELOSAURUS, ThescelosaurusEntity::createAttributes);
|
||||||
EntityAttributeRegistry.register(COELACANTH, CoelacanthEntity::createAttributes);
|
EntityAttributeRegistry.register(COELACANTH, CoelacanthEntity::createAttributes);
|
||||||
|
EntityAttributeRegistry.register(MAWSONIA, MawsoniaEntity::createAttributes);
|
||||||
|
EntityAttributeRegistry.register(ALLIGATOR_GAR, AlligatorGarEntity::createAttributes);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void registerSpawnPlacements() {
|
public static void registerSpawnPlacements() {
|
||||||
|
|||||||
@@ -35,9 +35,20 @@ public abstract class DinoEntityBase extends Animal {
|
|||||||
|
|
||||||
public float liveDebugWidth = -1.0F;
|
public float liveDebugWidth = -1.0F;
|
||||||
public float liveDebugHeight = -1.0F;
|
public float liveDebugHeight = -1.0F;
|
||||||
|
public float liveDebugScale = -1.0F;
|
||||||
|
|
||||||
public float getDinoScale() {
|
public final float getDinoScale() {
|
||||||
return 1.0F;
|
// If debug is active, intercept the scale
|
||||||
|
if (Constants.DEBUG_SIZES && liveDebugScale > 0) {
|
||||||
|
return liveDebugScale;
|
||||||
|
}
|
||||||
|
// Otherwise, ask the specific dinosaur what its scale should be
|
||||||
|
return this.getLiveDinoScale();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2. The Hook: Subclasses will override this instead of getDinoScale()
|
||||||
|
public float getLiveDinoScale() {
|
||||||
|
return 1.0F; // Default base scale
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -205,14 +216,12 @@ public abstract class DinoEntityBase extends Animal {
|
|||||||
} else if (hand == InteractionHand.OFF_HAND) {
|
} else if (hand == InteractionHand.OFF_HAND) {
|
||||||
liveDebugHeight += adjustment; // Off hand edits HEIGHT
|
liveDebugHeight += adjustment; // Off hand edits HEIGHT
|
||||||
}
|
}
|
||||||
|
|
||||||
// INSTANT VISUAL UPDATE (Works because mobInteract is client+server)
|
|
||||||
this.refreshDimensions();
|
this.refreshDimensions();
|
||||||
|
|
||||||
if (!this.level().isClientSide) {
|
if (!this.level().isClientSide) {
|
||||||
String action = player.isShiftKeyDown() ? "§c[-] SHRUNK" : "§a[+] GREW";
|
String action = player.isShiftKeyDown() ? "§c[-] SHRUNK" : "§a[+] GREW";
|
||||||
String dimension = hand == InteractionHand.MAIN_HAND ? "WIDTH" : "HEIGHT";
|
String dimension = hand == InteractionHand.MAIN_HAND ? "WIDTH" : "HEIGHT";
|
||||||
String dinoName = net.minecraft.world.entity.EntityType.getKey(this.getType()).getPath();
|
String dinoName = EntityType.getKey(this.getType()).getPath();
|
||||||
|
|
||||||
player.sendSystemMessage(Component.literal(action + " " + dimension + "§f: " + dinoName +
|
player.sendSystemMessage(Component.literal(action + " " + dimension + "§f: " + dinoName +
|
||||||
" -> §e.sized(" + String.format("%.1f", liveDebugWidth) + "F, " +
|
" -> §e.sized(" + String.format("%.1f", liveDebugWidth) + "F, " +
|
||||||
@@ -222,6 +231,33 @@ public abstract class DinoEntityBase extends Animal {
|
|||||||
}
|
}
|
||||||
// --- END LIVE HITBOX TUNER ---
|
// --- END LIVE HITBOX TUNER ---
|
||||||
|
|
||||||
|
|
||||||
|
// --- LIVE SCALE TUNER ---
|
||||||
|
if (Constants.DEBUG_SIZES && stack.is(Items.BONE)) {
|
||||||
|
if (liveDebugScale < 0) {
|
||||||
|
liveDebugScale = 1.0F;
|
||||||
|
}
|
||||||
|
|
||||||
|
float adjustment = player.isShiftKeyDown() ? -0.1f : 0.1f;
|
||||||
|
liveDebugScale += adjustment;
|
||||||
|
|
||||||
|
if (liveDebugScale < 0.1F) {
|
||||||
|
liveDebugScale = 0.1F;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.refreshDimensions();
|
||||||
|
|
||||||
|
if (!this.level().isClientSide) {
|
||||||
|
String action = player.isShiftKeyDown() ? "§cShrunk" : "§aGrown";
|
||||||
|
String dinoName = EntityType.getKey(this.getType()).getPath();
|
||||||
|
player.sendSystemMessage(Component.literal(action + " SCALE§f: " + dinoName +
|
||||||
|
" -> §e" + String.format("%.1f", liveDebugScale) + "x"));
|
||||||
|
|
||||||
|
}
|
||||||
|
return InteractionResult.SUCCESS;
|
||||||
|
}
|
||||||
|
// --- END LIVE SCALE TUNER ---
|
||||||
|
|
||||||
if (this.isFood(stack)) {
|
if (this.isFood(stack)) {
|
||||||
if (!this.level().isClientSide) {
|
if (!this.level().isClientSide) {
|
||||||
feedDino(player, stack);
|
feedDino(player, stack);
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class AchillobatorRenderer extends GeoEntityRenderer<AchillobatorEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AchillobatorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AchillobatorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class AlbertosaurusRenderer extends GeoEntityRenderer<AlbertosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AlbertosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AlbertosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,113 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import com.google.common.collect.Maps;
|
||||||
|
import net.cmr.jurassicrevived.Constants;
|
||||||
|
import net.cmr.jurassicrevived.entity.custom.AlligatorGarEntity;
|
||||||
|
import net.minecraft.Util;
|
||||||
|
import net.minecraft.resources.ResourceLocation;
|
||||||
|
import net.minecraft.util.Mth;
|
||||||
|
import software.bernie.geckolib.cache.object.GeoBone;
|
||||||
|
import software.bernie.geckolib.constant.DataTickets;
|
||||||
|
import software.bernie.geckolib.core.animation.AnimationState;
|
||||||
|
import software.bernie.geckolib.model.GeoModel;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
/*?} else {*/
|
||||||
|
/*import software.bernie.geckolib.animation.AnimationState;
|
||||||
|
*//*?}*/
|
||||||
|
|
||||||
|
public class AlligatorGarModel extends GeoModel<AlligatorGarEntity> {
|
||||||
|
|
||||||
|
private static final Map<AlligatorGarVariant, ResourceLocation> LOCATION_BY_VARIANT =
|
||||||
|
Util.make(Maps.newEnumMap(AlligatorGarVariant.class), map -> {
|
||||||
|
map.put(AlligatorGarVariant.MALE, Constants.rl("textures/entity/alligator_gar.png"));
|
||||||
|
map.put(AlligatorGarVariant.FEMALE, Constants.rl("textures/entity/alligator_gar_female.png"));
|
||||||
|
});
|
||||||
|
|
||||||
|
// Model-local "currently applied" offsets; cleared before each entity render
|
||||||
|
private float[] appliedYaw = null;
|
||||||
|
private float[] appliedRoll = null;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getModelResource(AlligatorGarEntity animatable) {
|
||||||
|
return Constants.rl("geo/alligator_gar.geo.json");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getTextureResource(AlligatorGarEntity animatable) {
|
||||||
|
return LOCATION_BY_VARIANT.get(animatable.getVariant());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getAnimationResource(AlligatorGarEntity animatable) {
|
||||||
|
return Constants.rl("animations/alligator_gar.animation.json");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setCustomAnimations(AlligatorGarEntity entity, long id, AnimationState<AlligatorGarEntity> state) {
|
||||||
|
super.setCustomAnimations(entity, id, state);
|
||||||
|
|
||||||
|
String[] tailBones = { "BodySection3", "TailSection1", "TailSection2", "TailSection3", "TailSection5", "TailSection4" };
|
||||||
|
int n = tailBones.length;
|
||||||
|
|
||||||
|
if (appliedYaw == null || appliedYaw.length != n) {
|
||||||
|
appliedYaw = new float[n];
|
||||||
|
appliedRoll = new float[n];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 1) Clear previous offsets (from the last entity rendered with this model instance)
|
||||||
|
for (int i = 0; i < n; i++) {
|
||||||
|
if (appliedYaw[i] == 0.0f && appliedRoll[i] == 0.0f) continue;
|
||||||
|
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
||||||
|
if (bone == null) continue;
|
||||||
|
if (appliedYaw[i] != 0.0f) bone.setRotY(bone.getRotY() - appliedYaw[i]);
|
||||||
|
if (appliedRoll[i] != 0.0f) bone.setRotZ(bone.getRotZ() - appliedRoll[i]);
|
||||||
|
appliedYaw[i] = 0.0f;
|
||||||
|
appliedRoll[i] = 0.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2) Interpolated sway for extra smoothness between ticks
|
||||||
|
float sway = entity.getTailSwayOffset(state.getPartialTick()); // [-1, 1]
|
||||||
|
|
||||||
|
// Tuning
|
||||||
|
float maxYawDeg = 22.0f; // increased max sweep
|
||||||
|
float swayGain = 1.35f; // amplifies overall power
|
||||||
|
float rollFraction = 0.40f; // slightly stronger roll for heft
|
||||||
|
|
||||||
|
float deg2rad = (float)Math.PI / 180f;
|
||||||
|
|
||||||
|
// Direction: positive sway (left turn) -> tail swings right (negative yaw)
|
||||||
|
// Flip the sign here if the sway feels inverted
|
||||||
|
float baseYaw = sway * maxYawDeg * deg2rad;
|
||||||
|
float baseRoll = -baseYaw * rollFraction;
|
||||||
|
|
||||||
|
float[] weights = { 1.00f, 0.78f, 0.58f, 0.42f };
|
||||||
|
|
||||||
|
for (int i = 0; i < n; i++) {
|
||||||
|
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
||||||
|
if (bone == null) continue;
|
||||||
|
|
||||||
|
float w = weights[i];
|
||||||
|
float yaw = baseYaw * w;
|
||||||
|
float roll = baseRoll * w;
|
||||||
|
|
||||||
|
// OVERRIDE animations on Y/Z only: keep the model's predefined X bend intact
|
||||||
|
// Do NOT reset rotX here, so the upward bend stays
|
||||||
|
bone.setRotY(yaw);
|
||||||
|
bone.setRotZ(roll);
|
||||||
|
|
||||||
|
appliedYaw[i] = yaw;
|
||||||
|
appliedRoll[i] = roll;
|
||||||
|
}
|
||||||
|
|
||||||
|
GeoBone head = (GeoBone) getAnimationProcessor().getBone("Neck");
|
||||||
|
|
||||||
|
if (head != null) {
|
||||||
|
var entityData = state.getData(DataTickets.ENTITY_MODEL_DATA);
|
||||||
|
float clampedYawDeg = Mth.clamp(entityData.netHeadYaw(), -20.0f, 20.0f);
|
||||||
|
head.setRotY(clampedYawDeg * Mth.DEG_TO_RAD);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import com.mojang.blaze3d.vertex.PoseStack;
|
||||||
|
import net.cmr.jurassicrevived.entity.custom.AlligatorGarEntity;
|
||||||
|
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
||||||
|
import software.bernie.geckolib.cache.object.BakedGeoModel;
|
||||||
|
import software.bernie.geckolib.renderer.GeoEntityRenderer;
|
||||||
|
|
||||||
|
|
||||||
|
public class AlligatorGarRenderer extends GeoEntityRenderer<AlligatorGarEntity> {
|
||||||
|
public AlligatorGarRenderer(EntityRendererProvider.Context renderManager) {
|
||||||
|
super(renderManager, new AlligatorGarModel());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AlligatorGarEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
|
float scale = animatable.getDinoScale();
|
||||||
|
poseStack.scale(scale, scale, scale);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.Comparator;
|
||||||
|
|
||||||
|
public enum AlligatorGarVariant {
|
||||||
|
MALE(0),
|
||||||
|
FEMALE(1);
|
||||||
|
|
||||||
|
private static final AlligatorGarVariant[] BY_ID = Arrays.stream(values()).sorted(
|
||||||
|
Comparator.comparingInt(AlligatorGarVariant::getId)).toArray(AlligatorGarVariant[]::new);
|
||||||
|
|
||||||
|
private final int id;
|
||||||
|
|
||||||
|
AlligatorGarVariant(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static AlligatorGarVariant byId(int id) {
|
||||||
|
return BY_ID[id % BY_ID.length];
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -16,7 +16,7 @@ public class AllosaurusRenderer extends GeoEntityRenderer<AllosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AllosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AllosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class AlvarezsaurusRenderer extends GeoEntityRenderer<AlvarezsaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AlvarezsaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AlvarezsaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class AnkylosaurusRenderer extends GeoEntityRenderer<AnkylosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AnkylosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, AnkylosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class ApatosaurusRenderer extends GeoEntityRenderer<ApatosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ApatosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ApatosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ArambourgianiaRenderer extends GeoEntityRenderer<ArambourgianiaEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ArambourgianiaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ArambourgianiaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class BaryonyxRenderer extends GeoEntityRenderer<BaryonyxEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, BaryonyxEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, BaryonyxEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class BrachiosaurusRenderer extends GeoEntityRenderer<BrachiosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, BrachiosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, BrachiosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class CarcharodontosaurusRenderer extends GeoEntityRenderer<Carcharodonto
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CarcharodontosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CarcharodontosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class CarnotaurusRenderer extends GeoEntityRenderer<CarnotaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CarnotaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CarnotaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class CearadactylusRenderer extends GeoEntityRenderer<CearadactylusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CearadactylusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CearadactylusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class CeratosaurusRenderer extends GeoEntityRenderer<CeratosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CeratosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CeratosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ChasmosaurusRenderer extends GeoEntityRenderer<ChasmosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChasmosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChasmosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ChickenosaurusRenderer extends GeoEntityRenderer<ChickenosaurusEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChickenosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChickenosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class ChilesaurusRenderer extends GeoEntityRenderer<ChilesaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChilesaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ChilesaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ public class CoelacanthModel extends GeoModel<CoelacanthEntity> {
|
|||||||
public void setCustomAnimations(CoelacanthEntity entity, long id, AnimationState<CoelacanthEntity> state) {
|
public void setCustomAnimations(CoelacanthEntity entity, long id, AnimationState<CoelacanthEntity> state) {
|
||||||
super.setCustomAnimations(entity, id, state);
|
super.setCustomAnimations(entity, id, state);
|
||||||
|
|
||||||
String[] tailBones = { "tail1", "tail2", "tail3", "tail4", "tail5", "tail6" };
|
String[] tailBones = { "BodySection2", "BodySection3", "TailSection1", "TailSection2" , "TailSection3" };
|
||||||
int n = tailBones.length;
|
int n = tailBones.length;
|
||||||
|
|
||||||
if (appliedYaw == null || appliedYaw.length != n) {
|
if (appliedYaw == null || appliedYaw.length != n) {
|
||||||
@@ -82,7 +82,7 @@ public class CoelacanthModel extends GeoModel<CoelacanthEntity> {
|
|||||||
float baseYaw = sway * maxYawDeg * deg2rad;
|
float baseYaw = sway * maxYawDeg * deg2rad;
|
||||||
float baseRoll = -baseYaw * rollFraction;
|
float baseRoll = -baseYaw * rollFraction;
|
||||||
|
|
||||||
float[] weights = { 1.00f, 0.78f, 0.58f, 0.42f, 0.30f, 0.22f };
|
float[] weights = { 1.00f, 0.78f, 0.58f, 0.42f, 0.30f };
|
||||||
|
|
||||||
for (int i = 0; i < n; i++) {
|
for (int i = 0; i < n; i++) {
|
||||||
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
||||||
@@ -101,7 +101,7 @@ public class CoelacanthModel extends GeoModel<CoelacanthEntity> {
|
|||||||
appliedRoll[i] = roll;
|
appliedRoll[i] = roll;
|
||||||
}
|
}
|
||||||
|
|
||||||
GeoBone head = (GeoBone) getAnimationProcessor().getBone("body1");
|
GeoBone head = (GeoBone) getAnimationProcessor().getBone("BodySection1");
|
||||||
|
|
||||||
if (head != null) {
|
if (head != null) {
|
||||||
var entityData = state.getData(DataTickets.ENTITY_MODEL_DATA);
|
var entityData = state.getData(DataTickets.ENTITY_MODEL_DATA);
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public class CoelacanthRenderer extends GeoEntityRenderer<CoelacanthEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelacanthEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelacanthEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class CoelophysisRenderer extends GeoEntityRenderer<CoelophysisEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelophysisEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelophysisEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class CoelurusRenderer extends GeoEntityRenderer<CoelurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CoelurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class CompsognathusRenderer extends GeoEntityRenderer<CompsognathusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CompsognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CompsognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ConcavenatorRenderer extends GeoEntityRenderer<ConcavenatorEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ConcavenatorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ConcavenatorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class CorythosaurusRenderer extends GeoEntityRenderer<CorythosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CorythosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, CorythosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class DeinonychusRenderer extends GeoEntityRenderer<DeinonychusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DeinonychusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DeinonychusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class DilophosaurusRenderer extends GeoEntityRenderer<DilophosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DilophosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DilophosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class DimorphodonRenderer extends GeoEntityRenderer<DimorphodonEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DimorphodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DimorphodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class DiplodocusRenderer extends GeoEntityRenderer<DiplodocusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DiplodocusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DiplodocusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class DistortusRexRenderer extends GeoEntityRenderer<DistortusRexEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DistortusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DistortusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class DryosaurusRenderer extends GeoEntityRenderer<DryosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DryosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, DryosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class EdmontosaurusRenderer extends GeoEntityRenderer<EdmontosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, EdmontosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, EdmontosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class FDuckRenderer extends GeoEntityRenderer<FDuckEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, FDuckEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, FDuckEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class GallimimusRenderer extends GeoEntityRenderer<GallimimusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GallimimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GallimimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class GeosternbergiaRenderer extends GeoEntityRenderer<GeosternbergiaEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GeosternbergiaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GeosternbergiaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class GiganotosaurusRenderer extends GeoEntityRenderer<GiganotosaurusEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GiganotosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GiganotosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class GuanlongRenderer extends GeoEntityRenderer<GuanlongEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GuanlongEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GuanlongEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class GuidracoRenderer extends GeoEntityRenderer<GuidracoEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GuidracoEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, GuidracoEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class HadrosaurusRenderer extends GeoEntityRenderer<HadrosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HadrosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HadrosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class HerrerasaurusRenderer extends GeoEntityRenderer<HerrerasaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HerrerasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HerrerasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class HypsilophodonRenderer extends GeoEntityRenderer<HypsilophodonEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HypsilophodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, HypsilophodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class IndominusRexRenderer extends GeoEntityRenderer<IndominusRexEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, IndominusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, IndominusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class IndoraptorRenderer extends GeoEntityRenderer<IndoraptorEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, IndoraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, IndoraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class InostranceviaRenderer extends GeoEntityRenderer<InostranceviaEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, InostranceviaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, InostranceviaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class LambeosaurusRenderer extends GeoEntityRenderer<LambeosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, LambeosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, LambeosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class LudodactylusRenderer extends GeoEntityRenderer<LudodactylusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, LudodactylusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, LudodactylusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class MajungasaurusRenderer extends GeoEntityRenderer<MajungasaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MajungasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MajungasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class MamenchisaurusRenderer extends GeoEntityRenderer<MamenchisaurusEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MamenchisaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MamenchisaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,114 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import com.google.common.collect.Maps;
|
||||||
|
import net.cmr.jurassicrevived.Constants;
|
||||||
|
import net.cmr.jurassicrevived.entity.custom.MawsoniaEntity;
|
||||||
|
import net.minecraft.Util;
|
||||||
|
import net.minecraft.resources.ResourceLocation;
|
||||||
|
import net.minecraft.util.Mth;
|
||||||
|
import software.bernie.geckolib.cache.object.GeoBone;
|
||||||
|
import software.bernie.geckolib.constant.DataTickets;
|
||||||
|
import software.bernie.geckolib.core.animation.AnimationState;
|
||||||
|
import software.bernie.geckolib.model.GeoModel;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
/*?} else {*/
|
||||||
|
/*import software.bernie.geckolib.animation.AnimationState;
|
||||||
|
|
||||||
|
*//*?}*/
|
||||||
|
|
||||||
|
public class MawsoniaModel extends GeoModel<MawsoniaEntity> {
|
||||||
|
|
||||||
|
private static final Map<MawsoniaVariant, ResourceLocation> LOCATION_BY_VARIANT =
|
||||||
|
Util.make(Maps.newEnumMap(MawsoniaVariant.class), map -> {
|
||||||
|
map.put(MawsoniaVariant.MALE, Constants.rl("textures/entity/mawsonia.png"));
|
||||||
|
map.put(MawsoniaVariant.FEMALE, Constants.rl("textures/entity/mawsonia_female.png"));
|
||||||
|
});
|
||||||
|
|
||||||
|
// Model-local "currently applied" offsets; cleared before each entity render
|
||||||
|
private float[] appliedYaw = null;
|
||||||
|
private float[] appliedRoll = null;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getModelResource(MawsoniaEntity animatable) {
|
||||||
|
return Constants.rl("geo/mawsonia.geo.json");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getTextureResource(MawsoniaEntity animatable) {
|
||||||
|
return LOCATION_BY_VARIANT.get(animatable.getVariant());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ResourceLocation getAnimationResource(MawsoniaEntity animatable) {
|
||||||
|
return Constants.rl("animations/mawsonia.animation.json");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setCustomAnimations(MawsoniaEntity entity, long id, AnimationState<MawsoniaEntity> state) {
|
||||||
|
super.setCustomAnimations(entity, id, state);
|
||||||
|
|
||||||
|
String[] tailBones = { "BodySection6", "TailSection4", "TailSection5", "TailSection6" };
|
||||||
|
int n = tailBones.length;
|
||||||
|
|
||||||
|
if (appliedYaw == null || appliedYaw.length != n) {
|
||||||
|
appliedYaw = new float[n];
|
||||||
|
appliedRoll = new float[n];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 1) Clear previous offsets (from the last entity rendered with this model instance)
|
||||||
|
for (int i = 0; i < n; i++) {
|
||||||
|
if (appliedYaw[i] == 0.0f && appliedRoll[i] == 0.0f) continue;
|
||||||
|
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
||||||
|
if (bone == null) continue;
|
||||||
|
if (appliedYaw[i] != 0.0f) bone.setRotY(bone.getRotY() - appliedYaw[i]);
|
||||||
|
if (appliedRoll[i] != 0.0f) bone.setRotZ(bone.getRotZ() - appliedRoll[i]);
|
||||||
|
appliedYaw[i] = 0.0f;
|
||||||
|
appliedRoll[i] = 0.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2) Interpolated sway for extra smoothness between ticks
|
||||||
|
float sway = entity.getTailSwayOffset(state.getPartialTick()); // [-1, 1]
|
||||||
|
|
||||||
|
// Tuning
|
||||||
|
float maxYawDeg = 22.0f; // increased max sweep
|
||||||
|
float swayGain = 1.35f; // amplifies overall power
|
||||||
|
float rollFraction = 0.40f; // slightly stronger roll for heft
|
||||||
|
|
||||||
|
float deg2rad = (float)Math.PI / 180f;
|
||||||
|
|
||||||
|
// Direction: positive sway (left turn) -> tail swings right (negative yaw)
|
||||||
|
// Flip the sign here if the sway feels inverted
|
||||||
|
float baseYaw = sway * maxYawDeg * deg2rad;
|
||||||
|
float baseRoll = -baseYaw * rollFraction;
|
||||||
|
|
||||||
|
float[] weights = { 1.00f, 0.78f, 0.58f, 0.42f };
|
||||||
|
|
||||||
|
for (int i = 0; i < n; i++) {
|
||||||
|
GeoBone bone = (GeoBone) getAnimationProcessor().getBone(tailBones[i]);
|
||||||
|
if (bone == null) continue;
|
||||||
|
|
||||||
|
float w = weights[i];
|
||||||
|
float yaw = baseYaw * w;
|
||||||
|
float roll = baseRoll * w;
|
||||||
|
|
||||||
|
// OVERRIDE animations on Y/Z only: keep the model's predefined X bend intact
|
||||||
|
// Do NOT reset rotX here, so the upward bend stays
|
||||||
|
bone.setRotY(yaw);
|
||||||
|
bone.setRotZ(roll);
|
||||||
|
|
||||||
|
appliedYaw[i] = yaw;
|
||||||
|
appliedRoll[i] = roll;
|
||||||
|
}
|
||||||
|
|
||||||
|
GeoBone head = (GeoBone) getAnimationProcessor().getBone("Mainhead2");
|
||||||
|
|
||||||
|
if (head != null) {
|
||||||
|
var entityData = state.getData(DataTickets.ENTITY_MODEL_DATA);
|
||||||
|
float clampedYawDeg = Mth.clamp(entityData.netHeadYaw(), -20.0f, 20.0f);
|
||||||
|
head.setRotY(clampedYawDeg * Mth.DEG_TO_RAD);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import com.mojang.blaze3d.vertex.PoseStack;
|
||||||
|
import net.cmr.jurassicrevived.entity.custom.MawsoniaEntity;
|
||||||
|
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
||||||
|
import software.bernie.geckolib.cache.object.BakedGeoModel;
|
||||||
|
import software.bernie.geckolib.renderer.GeoEntityRenderer;
|
||||||
|
|
||||||
|
|
||||||
|
public class MawsoniaRenderer extends GeoEntityRenderer<MawsoniaEntity> {
|
||||||
|
public MawsoniaRenderer(EntityRendererProvider.Context renderManager) {
|
||||||
|
super(renderManager, new MawsoniaModel());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MawsoniaEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
|
float scale = animatable.getDinoScale();
|
||||||
|
poseStack.scale(scale, scale, scale);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.client;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.Comparator;
|
||||||
|
|
||||||
|
public enum MawsoniaVariant {
|
||||||
|
MALE(0),
|
||||||
|
FEMALE(1);
|
||||||
|
|
||||||
|
private static final MawsoniaVariant[] BY_ID = Arrays.stream(values()).sorted(
|
||||||
|
Comparator.comparingInt(MawsoniaVariant::getId)).toArray(MawsoniaVariant[]::new);
|
||||||
|
|
||||||
|
private final int id;
|
||||||
|
|
||||||
|
MawsoniaVariant(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static MawsoniaVariant byId(int id) {
|
||||||
|
return BY_ID[id % BY_ID.length];
|
||||||
|
}
|
||||||
|
}
|
||||||
+1
-1
@@ -16,7 +16,7 @@ public class MetriacanthosaurusRenderer extends GeoEntityRenderer<Metriacanthosa
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MetriacanthosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MetriacanthosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class MoganopterusRenderer extends GeoEntityRenderer<MoganopterusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MoganopterusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MoganopterusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class MussasaurusRenderer extends GeoEntityRenderer<MussasaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MussasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, MussasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class NyctosaurusRenderer extends GeoEntityRenderer<NyctosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, NyctosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, NyctosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class OrnitholestesRenderer extends GeoEntityRenderer<OrnitholestesEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OrnitholestesEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OrnitholestesEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class OrnithomimusRenderer extends GeoEntityRenderer<OrnithomimusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OrnithomimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OrnithomimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class OuranosaurusRenderer extends GeoEntityRenderer<OuranosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OuranosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OuranosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class OviraptorRenderer extends GeoEntityRenderer<OviraptorEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OviraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, OviraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class PachycephalosaurusRenderer extends GeoEntityRenderer<Pachycephalosa
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PachycephalosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PachycephalosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ParasaurolophusRenderer extends GeoEntityRenderer<ParasaurolophusEn
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ParasaurolophusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ParasaurolophusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ProceratosaurusRenderer extends GeoEntityRenderer<ProceratosaurusEn
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProceratosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProceratosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ProcompsognathusRenderer extends GeoEntityRenderer<Procompsognathus
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProcompsognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProcompsognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ProtoceratopsRenderer extends GeoEntityRenderer<ProtoceratopsEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProtoceratopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ProtoceratopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class PteranodonRenderer extends GeoEntityRenderer<PteranodonEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PteranodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PteranodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class PterodaustroRenderer extends GeoEntityRenderer<PterodaustroEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PterodaustroEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, PterodaustroEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class QuetzalcoatlusRenderer extends GeoEntityRenderer<QuetzalcoatlusEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, QuetzalcoatlusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, QuetzalcoatlusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class RajasaurusRenderer extends GeoEntityRenderer<RajasaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, RajasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, RajasaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class RugopsRenderer extends GeoEntityRenderer<RugopsEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, RugopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, RugopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class SegisaurusRenderer extends GeoEntityRenderer<SegisaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SegisaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SegisaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ShantungosaurusRenderer extends GeoEntityRenderer<ShantungosaurusEn
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ShantungosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ShantungosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class SpinosaurusRenderer extends GeoEntityRenderer<SpinosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SpinosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SpinosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class StegosaurusRenderer extends GeoEntityRenderer<StegosaurusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, StegosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, StegosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class StyracosaurusRenderer extends GeoEntityRenderer<StyracosaurusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, StyracosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, StyracosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class SuchomimusRenderer extends GeoEntityRenderer<SuchomimusEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SuchomimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, SuchomimusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class TapejaraRenderer extends GeoEntityRenderer<TapejaraEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TapejaraEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TapejaraEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class TherizinosaurusRenderer extends GeoEntityRenderer<TherizinosaurusEn
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TherizinosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TherizinosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ThescelosaurusRenderer extends GeoEntityRenderer<ThescelosaurusEnti
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ThescelosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ThescelosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class TitanosaurusRenderer extends GeoEntityRenderer<TitanosaurusEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TitanosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TitanosaurusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class TriceratopsRenderer extends GeoEntityRenderer<TriceratopsEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TriceratopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TriceratopsEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class TroodonRenderer extends GeoEntityRenderer<TroodonEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TroodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TroodonEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class TropeognathusRenderer extends GeoEntityRenderer<TropeognathusEntity
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TropeognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TropeognathusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class TupuxuaraRenderer extends GeoEntityRenderer<TupuxuaraEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TupuxuaraEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TupuxuaraEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class TyrannosaurusRexRenderer extends GeoEntityRenderer<TyrannosaurusRex
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TyrannosaurusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, TyrannosaurusRexEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class UtahraptorRenderer extends GeoEntityRenderer<UtahraptorEntity> {
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, UtahraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, UtahraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class VelociraptorRenderer extends GeoEntityRenderer<VelociraptorEntity>
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, VelociraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, VelociraptorEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -16,7 +16,7 @@ public class ZhenyuanopterusRenderer extends GeoEntityRenderer<ZhenyuanopterusEn
|
|||||||
@Override
|
@Override
|
||||||
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ZhenyuanopterusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
public void scaleModelForRender(float widthScale, float heightScale, PoseStack poseStack, ZhenyuanopterusEntity animatable, BakedGeoModel model, boolean isReRender, float partialTick, int packedLight, int packedOverlay) {
|
||||||
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
super.scaleModelForRender(widthScale, heightScale, poseStack, animatable, model, isReRender, partialTick, packedLight, packedOverlay);
|
||||||
float scale = animatable.getTotalModelScale();
|
float scale = animatable.getDinoScale();
|
||||||
poseStack.scale(scale, scale, scale);
|
poseStack.scale(scale, scale, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -309,7 +309,7 @@ public class AchillobatorEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -309,7 +309,7 @@ public class AlbertosaurusEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,395 @@
|
|||||||
|
package net.cmr.jurassicrevived.entity.custom;
|
||||||
|
|
||||||
|
import net.cmr.jurassicrevived.Constants;
|
||||||
|
import net.cmr.jurassicrevived.entity.ModEntities;
|
||||||
|
import net.cmr.jurassicrevived.entity.ai.DinoData;
|
||||||
|
import net.cmr.jurassicrevived.entity.ai.DinoEntityBase;
|
||||||
|
import net.cmr.jurassicrevived.entity.ai.IDinoData;
|
||||||
|
import net.cmr.jurassicrevived.entity.client.AlligatorGarVariant;
|
||||||
|
import net.minecraft.Util;
|
||||||
|
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.server.level.ServerLevel;
|
||||||
|
import net.minecraft.util.Mth;
|
||||||
|
import net.minecraft.world.DifficultyInstance;
|
||||||
|
import net.minecraft.world.entity.*;
|
||||||
|
import net.minecraft.world.entity.ai.attributes.AttributeSupplier;
|
||||||
|
import net.minecraft.world.entity.ai.attributes.Attributes;
|
||||||
|
import net.minecraft.world.entity.ai.attributes.DefaultAttributes;
|
||||||
|
import net.minecraft.world.entity.ai.control.SmoothSwimmingMoveControl;
|
||||||
|
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.level.Level;
|
||||||
|
import net.minecraft.world.level.ServerLevelAccessor;
|
||||||
|
import net.minecraft.world.level.block.Block;
|
||||||
|
import org.jetbrains.annotations.Nullable;
|
||||||
|
import software.bernie.geckolib.animatable.GeoEntity;
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
import software.bernie.geckolib.core.animatable.instance.AnimatableInstanceCache;
|
||||||
|
import software.bernie.geckolib.core.animatable.instance.SingletonAnimatableInstanceCache;
|
||||||
|
import software.bernie.geckolib.core.animation.AnimatableManager;
|
||||||
|
import software.bernie.geckolib.core.animation.Animation;
|
||||||
|
import software.bernie.geckolib.core.animation.AnimationController;
|
||||||
|
import software.bernie.geckolib.core.animation.RawAnimation;
|
||||||
|
import software.bernie.geckolib.core.object.PlayState;
|
||||||
|
/*?} else {*/
|
||||||
|
/*import software.bernie.geckolib.animatable.instance.AnimatableInstanceCache;
|
||||||
|
import software.bernie.geckolib.animatable.instance.SingletonAnimatableInstanceCache;
|
||||||
|
import software.bernie.geckolib.animation.*;
|
||||||
|
*//*?}*/
|
||||||
|
|
||||||
|
public class AlligatorGarEntity extends DinoEntityBase implements GeoEntity {
|
||||||
|
private AnimatableInstanceCache cache = new SingletonAnimatableInstanceCache(this);
|
||||||
|
|
||||||
|
public static final int BABY_TO_ADULT_AGE_TICKS = 28800;
|
||||||
|
private static final float ANIMAL_SCALE = 1.0F;
|
||||||
|
private static final float MIN_ANIMAL_SCALE = !Constants.DEBUG_SIZES ? (ANIMAL_SCALE - 0.2F) : ANIMAL_SCALE;
|
||||||
|
private static final float MAX_ANIMAL_SCALE = !Constants.DEBUG_SIZES ? (ANIMAL_SCALE + 0.2F) : ANIMAL_SCALE;
|
||||||
|
|
||||||
|
private float lastDimensionsScale = 1.0F;
|
||||||
|
|
||||||
|
private static final EntityDataAccessor<Integer> VARIANT =
|
||||||
|
SynchedEntityData.defineId(AlligatorGarEntity.class, EntityDataSerializers.INT);
|
||||||
|
private static final EntityDataAccessor<Integer> DATA_SYNCED_AGE =
|
||||||
|
SynchedEntityData.defineId(AlligatorGarEntity.class, EntityDataSerializers.INT);
|
||||||
|
private static final EntityDataAccessor<Float> DATA_ANIMAL_SCALE =
|
||||||
|
SynchedEntityData.defineId(AlligatorGarEntity.class, EntityDataSerializers.FLOAT);
|
||||||
|
|
||||||
|
// Procedural tail sway state (client-side use for rendering)
|
||||||
|
private float tailSwayOffset; // Smoothed offset in range roughly [-1, 1]
|
||||||
|
private float tailSwayVelocity; // Internal velocity for spring-damper
|
||||||
|
private float tailSwayPrev; // Previous frame value for interpolation
|
||||||
|
|
||||||
|
public AlligatorGarEntity(EntityType<? extends Animal> pEntityType, Level pLevel) {
|
||||||
|
super(pEntityType, pLevel);
|
||||||
|
|
||||||
|
this.dinoData = new DinoData(
|
||||||
|
getAIConfig().maxHunger(),
|
||||||
|
getAIConfig().maxThirst(),
|
||||||
|
IDinoData.Mood.NEUTRAL,
|
||||||
|
IDinoData.Aggression.TERRITORIAL,
|
||||||
|
0.75f,
|
||||||
|
IDinoData.DietaryClassification.CARNIVORE,
|
||||||
|
IDinoData.Type.MARINE,
|
||||||
|
IDinoData.Group.PISCINE,
|
||||||
|
IDinoData.BirthType.EGG_LAYING,
|
||||||
|
IDinoData.ActivityPattern.CATHEMERAL
|
||||||
|
);
|
||||||
|
|
||||||
|
// Replaces the default move control with 3D swimming mechanics
|
||||||
|
this.moveControl = new SmoothSwimmingMoveControl(this, 85, 10, 0.02F, 0.1F, true);
|
||||||
|
|
||||||
|
// Tells the pathfinder that water is perfectly safe to navigate through
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
this.setPathfindingMalus(net.minecraft.world.level.pathfinder.BlockPathTypes.WATER, 0.0F);
|
||||||
|
/*?} else {*/
|
||||||
|
/*this.setPathfindingMalus(net.minecraft.world.level.pathfinder.PathType.WATER, 0.0F);
|
||||||
|
*//*?}*/
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected PathNavigation createNavigation(Level pLevel) {
|
||||||
|
return new WaterBoundPathNavigation(this, pLevel);
|
||||||
|
}
|
||||||
|
|
||||||
|
//@Override
|
||||||
|
//public ItemStack getPickResult() {
|
||||||
|
// return new ItemStack(ModItems.ALLIGATOR_GAR_SPAWN_EGG.get());
|
||||||
|
//}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isCarnivore() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isMarine() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isAmphibious() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isSimpleFish() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Block getEggBlock() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DinoAIConfig getAIConfig() {
|
||||||
|
return new DinoAIConfig(0.3D, 1.1D, 1.5D, 100, 100, 0.05f, 0.1f, 20);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setBaby(boolean baby) {
|
||||||
|
this.setAge(baby ? -BABY_TO_ADULT_AGE_TICKS : 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static AttributeSupplier.Builder createAttributes() {
|
||||||
|
return Animal.createLivingAttributes()
|
||||||
|
.add(Attributes.MAX_HEALTH, 30D)
|
||||||
|
.add(Attributes.MOVEMENT_SPEED, 0.3D)
|
||||||
|
.add(Attributes.ARMOR, 0D)
|
||||||
|
.add(Attributes.FOLLOW_RANGE, 32D)
|
||||||
|
.add(Attributes.ATTACK_DAMAGE, 8D)
|
||||||
|
.add(Attributes.KNOCKBACK_RESISTANCE, 0.3D)
|
||||||
|
.add(Attributes.ATTACK_KNOCKBACK, 0D);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Nullable
|
||||||
|
@Override
|
||||||
|
public AgeableMob getBreedOffspring(ServerLevel pLevel, AgeableMob pOtherParent) {
|
||||||
|
AgeableMob child = ModEntities.ALLIGATOR_GAR.get().create(pLevel);
|
||||||
|
if (child instanceof AlligatorGarEntity baby) {
|
||||||
|
AlligatorGarVariant randomVariant = Util.getRandom(AlligatorGarVariant.values(), this.random);
|
||||||
|
baby.setVariant(randomVariant);
|
||||||
|
baby.setBaby(true);
|
||||||
|
baby.setAnimalScale(Mth.nextFloat(this.random, MIN_ANIMAL_SCALE, MAX_ANIMAL_SCALE));
|
||||||
|
}
|
||||||
|
return child;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean doHurtTarget(Entity target) {
|
||||||
|
boolean hit = super.doHurtTarget(target);
|
||||||
|
if (!level().isClientSide && hit && target instanceof LivingEntity) {
|
||||||
|
if (this.level() instanceof ServerLevel serverLevel) {
|
||||||
|
this.triggerAnim("attackController", "attack");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return hit;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void registerControllers(AnimatableManager.ControllerRegistrar controllers) {
|
||||||
|
controllers.add(new AnimationController<>(this, "SwimController", 5, state -> {
|
||||||
|
// 1. Highest Priority: Out of water flapping
|
||||||
|
if (!this.isInWater()) {
|
||||||
|
return state.setAndContinue(RawAnimation.begin().then("anim.alligator_gar.flop", Animation.LoopType.LOOP));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2. Aquatic movement: Just swim
|
||||||
|
return state.setAndContinue(RawAnimation.begin().then("anim.alligator_gar.swim", Animation.LoopType.LOOP));
|
||||||
|
}));
|
||||||
|
|
||||||
|
controllers.add(new AnimationController<>(this, "attackController", 5, state -> PlayState.STOP)
|
||||||
|
.triggerableAnim("attack", RawAnimation.begin().then("anim.alligator_gar.attack", Animation.LoopType.PLAY_ONCE)));
|
||||||
|
|
||||||
|
controllers.add(new AnimationController<>(this, "mouthController", 5, state -> PlayState.STOP)
|
||||||
|
.triggerableAnim("mouth", RawAnimation.begin().then("anim.alligator_gar.mouth", Animation.LoopType.PLAY_ONCE)));
|
||||||
|
}
|
||||||
|
|
||||||
|
private float getSignedTurnDelta() {
|
||||||
|
// Only consider the body (torso) rotation so head look does not affect tail sway
|
||||||
|
return Mth.wrapDegrees(this.yBodyRot - this.yBodyRotO);
|
||||||
|
}
|
||||||
|
|
||||||
|
private int mouthAnimCooldown = 0;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void tick() {
|
||||||
|
super.tick();
|
||||||
|
|
||||||
|
if (!level().isClientSide) {
|
||||||
|
this.entityData.set(DATA_SYNCED_AGE, this.getAge());
|
||||||
|
var maxHealthAttr = getAttribute(Attributes.MAX_HEALTH);
|
||||||
|
if (maxHealthAttr != null) {
|
||||||
|
double baseAdult = DefaultAttributes.getSupplier((EntityType<? extends LivingEntity>) this.getType()).getValue(Attributes.MAX_HEALTH);
|
||||||
|
double desired = this.isBaby() ? baseAdult * 0.10D : baseAdult;
|
||||||
|
if (maxHealthAttr.getBaseValue() != desired) {
|
||||||
|
double oldMax = maxHealthAttr.getBaseValue();
|
||||||
|
double healthRatio = this.getHealth() / (float) oldMax;
|
||||||
|
maxHealthAttr.setBaseValue(desired);
|
||||||
|
this.setHealth((float) (desired * Mth.clamp(healthRatio, 0.0F, 1.0F)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
updateDynamicDimensions();
|
||||||
|
|
||||||
|
if (!level().isClientSide) {
|
||||||
|
if (mouthAnimCooldown > 0) {
|
||||||
|
mouthAnimCooldown--;
|
||||||
|
} else {
|
||||||
|
this.triggerAnim("mouthController", "mouth");
|
||||||
|
// 30s–60s in ticks
|
||||||
|
mouthAnimCooldown = this.random.nextInt(1200 - 600 + 1) + 600;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (level().isClientSide) {
|
||||||
|
// Capture previous for smooth interpolation between ticks
|
||||||
|
this.tailSwayPrev = this.tailSwayOffset;
|
||||||
|
updateProceduralTailSway();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void updateProceduralTailSway() {
|
||||||
|
// Turn input derived from rotation deltas; works even when standing still and turning
|
||||||
|
float turnDegrees = getSignedTurnDelta();
|
||||||
|
|
||||||
|
// Deadzone to ignore tiny jitter so the tail can return to center cleanly
|
||||||
|
float deadzoneDeg = 0.6f; // smaller deadzone for more responsiveness
|
||||||
|
float turnInput = 0.0f;
|
||||||
|
if (Math.abs(turnDegrees) >= deadzoneDeg) {
|
||||||
|
// Higher sensitivity so small in-place turns still affect the model
|
||||||
|
turnInput = Mth.clamp(turnDegrees / 15.0f, -1.0f, 1.0f);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Target offset: keep intuitive sign (positive input -> positive sway)
|
||||||
|
float target = turnInput;
|
||||||
|
|
||||||
|
// One-pole low-pass (no bounce). Larger alpha => snappier and less "stiff".
|
||||||
|
float alpha = 0.24f; // try 0.20–0.30 to taste
|
||||||
|
|
||||||
|
tailSwayOffset += (target - tailSwayOffset) * alpha;
|
||||||
|
|
||||||
|
// Snap tiny residuals to zero so it visibly settles
|
||||||
|
if (Math.abs(tailSwayOffset) < 0.003f) {
|
||||||
|
tailSwayOffset = 0.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// No oscillation velocity retained
|
||||||
|
tailSwayVelocity = 0.0f;
|
||||||
|
|
||||||
|
tailSwayOffset = Mth.clamp(tailSwayOffset, -1.5f, 1.5f);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Expose to the model for bone rotation
|
||||||
|
public float getTailSwayOffset() {
|
||||||
|
return tailSwayOffset;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Interpolated sway for smooth rendering between ticks
|
||||||
|
public float getTailSwayOffset(float partialTick) {
|
||||||
|
return Mth.lerp(Mth.clamp(partialTick, 0.0f, 1.0f), tailSwayPrev, tailSwayOffset);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
@Override
|
||||||
|
protected void defineSynchedData() {
|
||||||
|
super.defineSynchedData();
|
||||||
|
this.entityData.define(VARIANT, 0);
|
||||||
|
this.entityData.define(DATA_SYNCED_AGE, 0);
|
||||||
|
this.entityData.define(DATA_ANIMAL_SCALE, 1.0F);
|
||||||
|
}
|
||||||
|
/*?} else {*/
|
||||||
|
/*@Override
|
||||||
|
protected void defineSynchedData(SynchedEntityData.Builder pBuilder) {
|
||||||
|
super.defineSynchedData(pBuilder);
|
||||||
|
pBuilder.define(VARIANT, 0);
|
||||||
|
pBuilder.define(DATA_SYNCED_AGE, 0);
|
||||||
|
pBuilder.define(DATA_ANIMAL_SCALE, 1.0F);
|
||||||
|
}
|
||||||
|
*//*?}*/
|
||||||
|
|
||||||
|
public int getSyncedAge() {
|
||||||
|
return this.entityData.get(DATA_SYNCED_AGE);
|
||||||
|
}
|
||||||
|
|
||||||
|
public float getAnimalScale() {
|
||||||
|
return this.entityData.get(DATA_ANIMAL_SCALE);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void setAnimalScale(float animalScale) {
|
||||||
|
this.entityData.set(DATA_ANIMAL_SCALE, animalScale);
|
||||||
|
}
|
||||||
|
|
||||||
|
public float getGrowthScale() {
|
||||||
|
if (!this.isBaby()) {
|
||||||
|
return 1.0F;
|
||||||
|
}
|
||||||
|
|
||||||
|
int age = this.level().isClientSide ? this.getSyncedAge() : this.getAge();
|
||||||
|
float growthProgress = Mth.clamp((BABY_TO_ADULT_AGE_TICKS + age) / (float) BABY_TO_ADULT_AGE_TICKS, 0.0F, 1.0F);
|
||||||
|
return Mth.lerp(growthProgress, 0.2F, 1.0F);
|
||||||
|
}
|
||||||
|
public float getTotalModelScale() {
|
||||||
|
return this.getAnimalScale() * this.getGrowthScale();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void updateDynamicDimensions() {
|
||||||
|
float dimensionsScale = this.getTotalModelScale();
|
||||||
|
if (Math.abs(dimensionsScale - this.lastDimensionsScale) > 0.01F) {
|
||||||
|
this.lastDimensionsScale = dimensionsScale;
|
||||||
|
this.refreshDimensions();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public float getLiveDinoScale() {
|
||||||
|
return this.getTotalModelScale();
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getTypeVariant() {
|
||||||
|
return this.entityData.get(VARIANT);
|
||||||
|
}
|
||||||
|
|
||||||
|
public AlligatorGarVariant getVariant() {
|
||||||
|
return AlligatorGarVariant.byId(this.getTypeVariant() & 255);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void setVariant(AlligatorGarVariant variant) {
|
||||||
|
this.entityData.set(VARIANT, variant.getId() & 255);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean canMate(Animal other) {
|
||||||
|
if (!super.canMate(other)) return false;
|
||||||
|
if (!(other instanceof AlligatorGarEntity that)) return false;
|
||||||
|
return this.getVariant() != that.getVariant();
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public void addAdditionalSaveData(CompoundTag pCompound) {
|
||||||
|
super.addAdditionalSaveData(pCompound);
|
||||||
|
pCompound.putInt("Variant", this.getTypeVariant());
|
||||||
|
pCompound.putFloat("AnimalScale", this.getAnimalScale());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void readAdditionalSaveData(CompoundTag pCompound) {
|
||||||
|
super.readAdditionalSaveData(pCompound);
|
||||||
|
this.entityData.set(VARIANT, pCompound.getInt("Variant"));
|
||||||
|
if (pCompound.contains("AnimalScale")) {
|
||||||
|
this.setAnimalScale(pCompound.getFloat("AnimalScale"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*? if <=1.20.1 {*/
|
||||||
|
@Override
|
||||||
|
public SpawnGroupData finalizeSpawn(ServerLevelAccessor pLevel, DifficultyInstance pDifficulty, MobSpawnType pReason, @Nullable SpawnGroupData pSpawnData, @Nullable CompoundTag pDataTag) {
|
||||||
|
AlligatorGarVariant variant = Util.getRandom(AlligatorGarVariant.values(), this.random);
|
||||||
|
this.setVariant(variant);
|
||||||
|
this.setAnimalScale(Mth.nextFloat(this.random, MIN_ANIMAL_SCALE, MAX_ANIMAL_SCALE));
|
||||||
|
return super.finalizeSpawn(pLevel, pDifficulty, pReason, pSpawnData, pDataTag);
|
||||||
|
}
|
||||||
|
/*?} else {*/
|
||||||
|
/*@Override
|
||||||
|
public SpawnGroupData finalizeSpawn(ServerLevelAccessor level, DifficultyInstance difficulty, MobSpawnType spawnType, @Nullable SpawnGroupData spawnGroupData) {
|
||||||
|
AlligatorGarVariant variant = Util.getRandom(AlligatorGarVariant.values(), this.random);
|
||||||
|
this.setVariant(variant);
|
||||||
|
this.setAnimalScale(Mth.nextFloat(this.random, MIN_ANIMAL_SCALE, MAX_ANIMAL_SCALE));
|
||||||
|
return super.finalizeSpawn(level, difficulty, spawnType, spawnGroupData);
|
||||||
|
}
|
||||||
|
*//*?}*/
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public AnimatableInstanceCache getAnimatableInstanceCache() {
|
||||||
|
return cache;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public double getFluidJumpThreshold() {
|
||||||
|
return this.getEyeHeight();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -312,7 +312,7 @@ public class AllosaurusEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
public int getTypeVariant() {
|
public int getTypeVariant() {
|
||||||
|
|||||||
@@ -316,7 +316,7 @@ public class AlvarezsaurusEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
public int getTypeVariant() {
|
public int getTypeVariant() {
|
||||||
|
|||||||
@@ -315,7 +315,7 @@ public class AnkylosaurusEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
public int getTypeVariant() {
|
public int getTypeVariant() {
|
||||||
|
|||||||
@@ -319,7 +319,7 @@ public class ApatosaurusEntity extends DinoEntityBase implements GeoEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
public int getTypeVariant() {
|
public int getTypeVariant() {
|
||||||
|
|||||||
+1
-1
@@ -355,7 +355,7 @@ public class ArambourgianiaEntity extends DinoEntityBase implements GeoEntity, F
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float getDinoScale() {
|
public float getLiveDinoScale() {
|
||||||
return this.getTotalModelScale();
|
return this.getTotalModelScale();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user