This commit is contained in:
GearShocky 2025-03-03 03:20:42 +05:00
parent 36a16ac9d2
commit 2ee6c7e923
25 changed files with 834 additions and 4 deletions

1
src/bb/loader.bbmodel Normal file

File diff suppressed because one or more lines are too long

View File

@ -226,6 +226,7 @@ fun addDecorativeData(blockStateProvider: MatteryBlockStateProvider, itemModelPr
}
DataGen.decorativePillar(MBlocks.METAL_BEAM, "metal_beam_side", "metal_beam_top")
blockModelProvider.decorativeCubeAll(MBlocks.METAL_BEAM_CENTER, "metal_beam_top")
var labLampOn: BlockModelBuilder? = null
var labLampOff: BlockModelBuilder? = null
@ -259,6 +260,9 @@ fun addDecorativeData(blockStateProvider: MatteryBlockStateProvider, itemModelPr
itemModelProvider.block(MItems.DANGER_STRIPE_BLOCK, MItems.DANGER_STRIPE_BLOCK.registryName!!.path + "_0")
itemModelProvider.block(MItems.METAL_BEAM)
blockStateProvider.block(MBlocks.METAL_BEAM_CENTER)
itemModelProvider.block(MItems.METAL_BEAM_CENTER)
blockStateProvider.exec {
blockStateProvider.getVariantBuilder(MBlocks.LABORATORY_LAMP).forAllStates {
return@forAllStates ConfiguredModel.builder()

View File

@ -47,6 +47,18 @@ class SoundDataProvider(event: GatherDataEvent) : SoundDefinitionsProvider(event
.stream()
))
add(
MSoundEvents.LOADER_AMBIENT,
definition().subtitle("otm.sound.entity.loader.loader_ambient")
.with(
SoundDefinition.Sound.sound(modLocation("entity/loader/loader_ambient"), SoundDefinition.SoundType.SOUND)
.attenuationDistance(32)
.stream(),
SoundDefinition.Sound.sound(modLocation("entity/loader/loader_ambient2"), SoundDefinition.SoundType.SOUND)
.attenuationDistance(32)
.stream()
))
add(
MSoundEvents.ANDROID_PROJ_PARRY,
definition().subtitle("otm.sound.android.projectile_parry")

View File

@ -115,6 +115,7 @@ fun addItemModels(provider: MatteryItemModelProvider) {
provider.handheld(MItems.CHEST_UPGRADER)
provider.generated(MItems.BREAD_MONSTER_SPAWN_EGG, modLocation("item/egg/bread_monster"))
provider.generated(MItems.LOADER_SPAWN_EGG, modLocation("item/egg/loader"))
provider.generatedTiered(MItems.BATTERIES, "battery_tier")
provider.generated(MItems.BATTERY_CREATIVE)

View File

@ -681,6 +681,7 @@ private fun blocks(provider: MatteryLanguageProvider) {
add(MBlocks.LABORATORY_LAMP_INVERTED, "Laboratory Lamp (Inverted signal)")
add(MBlocks.DANGER_STRIPE_BLOCK, "Danger Stripes")
add(MBlocks.METAL_BEAM, "Metal Beam")
add(MBlocks.METAL_BEAM_CENTER, "Metal Beam (Center)")
add(MBlocks.TRITANIUM_DOOR[null]!!, "Tritanium Door")
add(MBlocks.TRITANIUM_DOOR[null]!!, "description0", "High blast resistance door with redstone latch...")

View File

@ -684,6 +684,7 @@ private fun blocks(provider: MatteryLanguageProvider) {
add(MBlocks.LABORATORY_LAMP_INVERTED, "Лабораторная лампа (инвентированный сигнал)")
add(MBlocks.DANGER_STRIPE_BLOCK, "Полоски 'опасность'")
add(MBlocks.METAL_BEAM, "Металлическая опора")
add(MBlocks.METAL_BEAM_CENTER, "Металлическая опора (середина)")
add(MBlocks.TRITANIUM_DOOR[null]!!, "Тритановая дверь")
add(MBlocks.TRITANIUM_DOOR[null]!!, "description0", "Взрывоустойчивая дверь с засовом красного камня...")

View File

@ -177,6 +177,11 @@ fun addDecorativesRecipes(provider: MatteryRecipeProvider, consumer: RecipeOutpu
.save(consumer, modLocation("decorative/vent/from_alt/${color?.name?.lowercase() ?: "default"}"))
}
ShapelessRecipeBuilder(RecipeCategory.BUILDING_BLOCKS, MItems.METAL_BEAM_CENTER, 1).requires(MItems.METAL_BEAM)
.unlockedBy(MItems.METAL_BEAM)
ShapelessRecipeBuilder(RecipeCategory.BUILDING_BLOCKS, MItems.METAL_BEAM, 1).requires(MItems.METAL_BEAM_CENTER)
.unlockedBy(MItems.METAL_BEAM_CENTER)
MatteryRecipe(MRegistry.DECORATIVE_CRATE.item, 24, category = RecipeCategory.BUILDING_BLOCKS)
.rowB(Tags.Items.INGOTS_IRON)
.row(Tags.Items.INGOTS_IRON, Tags.Items.COBBLESTONES, Tags.Items.INGOTS_IRON)

View File

@ -146,6 +146,7 @@ fun addMineableTags(tagsProvider: TagsProvider) {
tagsProvider.requiresPickaxe(MBlocks.LABORATORY_LAMP, Tiers.IRON)
tagsProvider.requiresPickaxe(MBlocks.LABORATORY_LAMP_INVERTED, Tiers.IRON)
tagsProvider.requiresPickaxe(MBlocks.METAL_BEAM, Tiers.IRON)
tagsProvider.requiresPickaxe(MBlocks.METAL_BEAM_CENTER, Tiers.IRON)
tagsProvider.requiresPickaxe(MBlocks.DANGER_STRIPE_BLOCK)
}

View File

@ -0,0 +1,129 @@
package ru.dbotthepony.mc.otm.client.animation;
import net.minecraft.client.animation.AnimationChannel;
import net.minecraft.client.animation.AnimationDefinition;
import net.minecraft.client.animation.Keyframe;
import net.minecraft.client.animation.KeyframeAnimations;
public class LoaderAnimation {
public static final AnimationDefinition IDLE = AnimationDefinition.Builder.withLength(0.16F).looping()
.addAnimation("Body", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.08F, KeyframeAnimations.posVec(0F, -0.1F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.16F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("Head", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.08F, KeyframeAnimations.posVec(0F, -0.1F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.16F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("LeftArm", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0.1F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, -0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.16F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightArm", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0.1F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, -0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.16F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.build();
public static final AnimationDefinition MOVE = AnimationDefinition.Builder.withLength(0.48F).looping()
.addAnimation("Body", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 0.3F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 0.3F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("Head", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 0.3F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 0.3F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("LeftLeg", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, -2F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 1F, 1F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 2F, -2F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, -2F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("LeftLeg", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightLeg", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 2F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 2F, -2F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 0F, -2F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, 2F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightLeg", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(-22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(22.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("LeftArm", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("LeftArm", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(-6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("ElbowR", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-30F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(-19.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-30F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightArm", new AnimationChannel(AnimationChannel.Targets.POSITION,
new Keyframe(0.0F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.12F, KeyframeAnimations.posVec(0F, 0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.36F, KeyframeAnimations.posVec(0F, 0.2F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.posVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightArm", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-6F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("ElbowL", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-16.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.24F, KeyframeAnimations.degreeVec(-25.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-16.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.build();
public static final AnimationDefinition ATTACK = AnimationDefinition.Builder.withLength(0.48F).looping()
.addAnimation("LeftArm", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.2F, KeyframeAnimations.degreeVec(-135F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("ElbowR", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-2F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.2F, KeyframeAnimations.degreeVec(-24.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-2F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("RightArm", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.2F, KeyframeAnimations.degreeVec(-135F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(0F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.addAnimation("ElbowL", new AnimationChannel(AnimationChannel.Targets.ROTATION,
new Keyframe(0.0F, KeyframeAnimations.degreeVec(-2F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.2F, KeyframeAnimations.degreeVec(-24.5F, 0F, 0F), AnimationChannel.Interpolations.LINEAR),
new Keyframe(0.48F, KeyframeAnimations.degreeVec(-2F, 0F, 0F), AnimationChannel.Interpolations.LINEAR)
))
.build();
}

View File

@ -0,0 +1,100 @@
package ru.dbotthepony.mc.otm.client.model.entity;
import net.minecraft.client.model.HierarchicalModel;
import net.minecraft.client.model.geom.ModelLayerLocation;
import net.minecraft.client.model.geom.ModelPart;
import net.minecraft.client.model.geom.PartPose;
import net.minecraft.client.model.geom.builders.*;
import net.neoforged.neoforge.client.event.EntityRenderersEvent;
import org.jetbrains.annotations.NotNull;
import ru.dbotthepony.mc.otm.client.animation.LoaderAnimation;
import ru.dbotthepony.mc.otm.entity.Loader;
import ru.dbotthepony.mc.otm.registry.MNames;
import static ru.dbotthepony.mc.otm.OverdriveThatMatters.loc;
public class LoaderModel {
public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(loc(MNames.LOADER), "main");
private static HierarchicalModel<Loader> model;
private static LayerDefinition def;
public static HierarchicalModel<Loader> getModel() {
if (def == null) {
def = createBodyLayer(); // Ensure def is created before using it
}
if (model == null) {
return model = new LoaderHierarchicalModel<>(def.bakeRoot());
}
return model;
}
public static LayerDefinition createBodyLayer() {
MeshDefinition meshdefinition = new MeshDefinition();
PartDefinition partdefinition = meshdefinition.getRoot();
PartDefinition root = partdefinition.addOrReplaceChild("root", CubeListBuilder.create(), PartPose.offset(0.0F, 24.0F, 0.0F));
PartDefinition Head = root.addOrReplaceChild("Head", CubeListBuilder.create().texOffs(48, 23).addBox(-3.0F, -1.0F, -2.0F, 6.0F, 3.0F, 3.0F, new CubeDeformation(0.0F)), PartPose.offset(-4.0F, -32.0F, -5.0F));
PartDefinition Body = root.addOrReplaceChild("Body", CubeListBuilder.create().texOffs(0, 0).addBox(-10.0F, -16.0F, -5.0F, 20.0F, 10.0F, 13.0F, new CubeDeformation(0.0F))
.texOffs(0, 50).addBox(-3.0F, -3.0F, -4.0F, 6.0F, 5.0F, 8.0F, new CubeDeformation(0.0F))
.texOffs(112, 52).addBox(10.0F, -13.0F, 0.0F, 2.0F, 6.0F, 6.0F, new CubeDeformation(0.0F))
.texOffs(96, 52).addBox(-12.0F, -13.0F, -1.0F, 2.0F, 6.0F, 6.0F, new CubeDeformation(0.0F))
.texOffs(53, 0).addBox(-5.0F, -1.0F, 4.0F, 10.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)), PartPose.offset(0.0F, -26.0F, -1.0F));
PartDefinition antenna_r1 = Body.addOrReplaceChild("antenna_r1", CubeListBuilder.create().texOffs(76, 6).addBox(0.0F, -7.0F, -1.0F, 0.0F, 14.0F, 2.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(8.0F, -22.0F, 8.0F, -0.2618F, 0.0F, 0.0F));
PartDefinition waist_r1 = Body.addOrReplaceChild("waist_r1", CubeListBuilder.create().texOffs(28, 50).addBox(-2.0F, -5.0F, -4.0F, 4.0F, 7.0F, 7.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(0.0F, -3.0F, 2.0F, -0.2618F, 0.0F, 0.0F));
PartDefinition LeftLeg = root.addOrReplaceChild("LeftLeg", CubeListBuilder.create().texOffs(106, 24).addBox(0.0F, 10.0F, -2.0F, 4.0F, 16.0F, 7.0F, new CubeDeformation(0.0F))
.texOffs(66, 46).addBox(-1.0F, -2.0F, -3.0F, 6.0F, 12.0F, 6.0F, new CubeDeformation(0.0F)), PartPose.offset(4.0F, -26.0F, -1.0F));
PartDefinition RightLeg = root.addOrReplaceChild("RightLeg", CubeListBuilder.create().texOffs(84, 24).addBox(-4.0F, 10.0F, -2.0F, 4.0F, 16.0F, 7.0F, new CubeDeformation(0.0F))
.texOffs(48, 34).addBox(-5.0F, -2.0F, -3.0F, 6.0F, 12.0F, 6.0F, new CubeDeformation(0.0F)), PartPose.offset(-4.0F, -26.0F, -1.0F));
PartDefinition LeftArm = root.addOrReplaceChild("LeftArm", CubeListBuilder.create().texOffs(104, 0).addBox(-1.0F, -7.0F, -4.0F, 4.0F, 16.0F, 8.0F, new CubeDeformation(0.0F)), PartPose.offset(13.0F, -36.0F, 2.0F));
PartDefinition ElbowL = LeftArm.addOrReplaceChild("ElbowL", CubeListBuilder.create().texOffs(24, 23).addBox(-2.0F, -0.2F, -2.0F, 4.0F, 19.0F, 8.0F, new CubeDeformation(-0.1F)), PartPose.offset(1.0F, 9.0F, -1.0F));
PartDefinition RightArm = root.addOrReplaceChild("RightArm", CubeListBuilder.create().texOffs(80, 0).addBox(-3.0F, -7.0F, -4.0F, 4.0F, 16.0F, 8.0F, new CubeDeformation(0.0F)), PartPose.offset(-13.0F, -36.0F, 1.0F));
PartDefinition ElbowR = RightArm.addOrReplaceChild("ElbowR", CubeListBuilder.create().texOffs(0, 23).addBox(-2.0F, -0.2F, -2.0F, 4.0F, 19.0F, 8.0F, new CubeDeformation(-0.1F)), PartPose.offset(-1.0F, 9.0F, -1.0F));
model = null;
return def = LayerDefinition.create(meshdefinition, 128, 64);
}
private static class LoaderHierarchicalModel<T extends Loader> extends HierarchicalModel<T> {
private final ModelPart root;
public LoaderHierarchicalModel(ModelPart root) {
this.root = root.getChild("root");
}
@Override
public void setupAnim(@NotNull T entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) {
this.root().getAllParts().forEach(ModelPart::resetPose);
this.root.getChild("Head").yRot = netHeadYaw * ((float) Math.PI / 180F);
this.root.getChild("Head").xRot = headPitch * ((float) Math.PI / 180F);
if (entity.getAttackAnimationTick() > 0) {
this.animate(entity.getIdleState(), LoaderAnimation.ATTACK, ageInTicks, 1.0F);
}
this.animateWalk(LoaderAnimation.MOVE, limbSwing, limbSwingAmount, 1.0F, 2.5F);
this.animate(entity.getIdleState(), LoaderAnimation.IDLE, ageInTicks, 1.0F);
}
public ModelPart getHead() {
return this.root.getChild("Head");
}
@Override
public @NotNull ModelPart root() {
return this.root;
}
}
public static void register(EntityRenderersEvent.RegisterLayerDefinitions event) {
event.registerLayerDefinition(LAYER_LOCATION, LoaderModel::createBodyLayer);
}
}

View File

@ -0,0 +1,18 @@
package ru.dbotthepony.mc.otm.client.render.entity
import net.minecraft.client.model.HierarchicalModel
import net.minecraft.client.renderer.entity.EntityRendererProvider
import net.minecraft.client.renderer.entity.MobRenderer
import net.minecraft.resources.ResourceLocation
import ru.dbotthepony.mc.otm.OverdriveThatMatters.loc
import ru.dbotthepony.mc.otm.client.model.entity.LoaderModel
import ru.dbotthepony.mc.otm.entity.Loader
class LoaderRenderer(context: EntityRendererProvider.Context)
: MobRenderer<Loader, HierarchicalModel<Loader>>(context, LoaderModel.getModel(), 0.8f) {
override fun getTextureLocation(entity: Loader): ResourceLocation = TEXTURE_LOCATION
companion object {
private val TEXTURE_LOCATION = loc("textures/entity/loader.png")
}
}

View File

@ -0,0 +1,130 @@
package ru.dbotthepony.mc.otm.entity
import net.minecraft.network.syncher.EntityDataAccessor
import net.minecraft.network.syncher.EntityDataSerializers
import net.minecraft.network.syncher.SynchedEntityData
import net.minecraft.sounds.SoundEvent
import net.minecraft.sounds.SoundEvents
import net.minecraft.world.entity.AnimationState
import net.minecraft.world.entity.Entity
import net.minecraft.world.entity.EntityType
import net.minecraft.world.entity.ai.attributes.AttributeSupplier
import net.minecraft.world.entity.ai.attributes.Attributes
import net.minecraft.world.entity.ai.goal.LookAtPlayerGoal
import net.minecraft.world.entity.ai.goal.MeleeAttackGoal
import net.minecraft.world.entity.ai.goal.RandomLookAroundGoal
import net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal
import net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal
import net.minecraft.world.entity.ai.goal.target.NearestAttackableTargetGoal
import net.minecraft.world.entity.ai.navigation.GroundPathNavigation
import net.minecraft.world.entity.ai.navigation.PathNavigation
import net.minecraft.world.entity.monster.Monster
import net.minecraft.world.entity.player.Player
import net.minecraft.world.level.Level
import ru.dbotthepony.mc.otm.registry.game.MSoundEvents
class Loader(type: EntityType<Loader>, level: Level) : Monster(type, level) {
val idleState = AnimationState()
var attackAnimationState = AnimationState()
var attackAnimationTick = 0
companion object {
fun createAttributes() : AttributeSupplier.Builder {
return createMonsterAttributes()
.add(Attributes.MAX_HEALTH, 60.0)
.add(Attributes.MOVEMENT_SPEED, 0.3)
.add(Attributes.ATTACK_DAMAGE, 5.0)
.add(Attributes.KNOCKBACK_RESISTANCE, 0.7)
}
private val DATA_ATTACKING: EntityDataAccessor<Boolean> =
SynchedEntityData.defineId(Loader::class.java, EntityDataSerializers.BOOLEAN)
}
override fun defineSynchedData(builder: SynchedEntityData.Builder) {
super.defineSynchedData(builder)
builder.define(DATA_ATTACKING, false)
}
var isAttacking: Boolean
get() = this.entityData.get(DATA_ATTACKING)
set(value) {
this.entityData.set(DATA_ATTACKING, value)
}
//https://nc.dbotthepony.ru/s/qqKdbQEYy74KyGM
init {
idleState.start(tickCount)
}
override fun registerGoals() {
goalSelector.addGoal(8, RandomLookAroundGoal(this))
goalSelector.addGoal(7, WaterAvoidingRandomStrollGoal(this, 0.8))
goalSelector.addGoal(8, LookAtPlayerGoal(this, Player::class.java, 8f))
goalSelector.addGoal(3, NearestAttackableTargetGoal(this, Player::class.java , true, true))
goalSelector.addGoal(2, MeleeAttackGoal(this, 1.0, true))
targetSelector.addGoal(1, HurtByTargetGoal(this))
}
override fun handleEntityEvent(id: Byte) {
if (id.toInt() == 4) {
this.attackAnimationTick = 7 // Attack animation lasts 10 ticks
} else {
super.handleEntityEvent(id)
}
}
override fun doHurtTarget(target: Entity): Boolean {
level().broadcastEntityEvent(this, 4.toByte())
val success = super.doHurtTarget(target)
if (success) {
this.playSound(SoundEvents.IRON_GOLEM_ATTACK, 1.0f, 1.0f)
//THIS IS FUCKING RETARDED
//fuck everything
level().broadcastEntityEvent(this, 4.toByte())
idleState.stop()
idleState.start(tickCount)
val dirx = target.x - this.x
val dirz = target.z - this.z
val dist = Math.sqrt(dirx * dirx + dirx * dirz)
target.push(dirx / dist * 0.6, 0.3, dirz / dist * 0.6)
}
return success
}
override fun aiStep() {
super.aiStep()
if (attackAnimationTick > 0) {
attackAnimationTick--
if (attackAnimationTick == 0) {
isAttacking = false
}
}
}
override fun getAmbientSound(): SoundEvent {
return MSoundEvents.LOADER_AMBIENT
}
override fun getHurtSound(damageSource: net.minecraft.world.damagesource.DamageSource): SoundEvent {
return SoundEvents.IRON_GOLEM_HURT
}
override fun getDeathSound(): SoundEvent {
return SoundEvents.IRON_GOLEM_DEATH
}
override fun playStepSound(pos: net.minecraft.core.BlockPos, blockState: net.minecraft.world.level.block.state.BlockState) {
this.playSound(SoundEvents.IRON_GOLEM_STEP, 1.0f, 1.0f)
}
override fun createNavigation(level: Level): PathNavigation = GroundPathNavigation(this, level)
}

View File

@ -12,6 +12,7 @@ object MNames {
const val LABORATORY_LAMP_LIGHT = "laboratory_lamp_light"
const val DANGER_STRIPE_BLOCK = "danger_stripe_block"
const val METAL_BEAM = "metal_beam"
const val METAL_BEAM_CENTER = "metal_beam_center"
const val ENGINE = "engine"
const val HOLO_SIGN = "holo_sign"
const val FLUID_TANK = "fluid_tank"
@ -202,6 +203,7 @@ object MNames {
// eg
const val BREAD_MONSTER_SPAWN_EGG = "bead_monster_spawn_egg"
const val LOADER_SPAWN_EGG = "loader_spawn_egg"
// items: crafting components
const val TRITANIUM_DUST = "tritanium_dust"
@ -323,6 +325,7 @@ object MNames {
const val PLASMA = "plasma_projectile"
const val RIDEABLE_DUMMY = "rideable_dummy"
const val BREAD_MONSTER = "bread_monster"
const val LOADER = "loader"
const val PHANTOM_ATTRACTOR = "phantom_attractor"
const val JUMP_BOOST = "jump_boost"

View File

@ -359,6 +359,7 @@ object MBlocks {
val LABORATORY_LAMP_LIGHT: Block by registry.register(MNames.LABORATORY_LAMP_LIGHT) { LaboratoryLampLight() }
val DANGER_STRIPE_BLOCK: Block by registry.register(MNames.DANGER_STRIPE_BLOCK) { Block(BlockBehaviour.Properties.of().mapColor(MapColor.COLOR_GRAY).explosionResistance(6f).destroyTime(1.5f).requiresCorrectToolForDrops()) }
val METAL_BEAM: Block by registry.register(MNames.METAL_BEAM) { RotatedPillarBlock(BlockBehaviour.Properties.of().mapColor(MapColor.COLOR_GRAY).sound(SoundType.METAL).explosionResistance(14f).destroyTime(2.5f).requiresCorrectToolForDrops()) }
val METAL_BEAM_CENTER: Block by registry.register(MNames.METAL_BEAM_CENTER) { RotatedPillarBlock(BlockBehaviour.Properties.of().mapColor(MapColor.COLOR_GRAY).sound(SoundType.METAL).explosionResistance(14f).destroyTime(2.5f).requiresCorrectToolForDrops()) }
val ENGINE: Block by registry.register(MNames.ENGINE) { EngineBlock() }
val HOLO_SIGN: Block by registry.register(MNames.HOLO_SIGN) { HoloSignBlock() }

View File

@ -318,6 +318,7 @@ private fun addDecorativeTabItems(consumer: CreativeModeTab.Output) {
accept(MItems.DANGER_STRIPE_BLOCK)
accept(MItems.METAL_BEAM)
accept(MItems.METAL_BEAM_CENTER)
accept(MItems.ENGINE)
accept(MItems.TRITANIUM_STRIPED_BLOCK.values)

View File

@ -14,11 +14,9 @@ import net.neoforged.bus.api.IEventBus
import net.neoforged.fml.event.lifecycle.FMLClientSetupEvent
import net.neoforged.neoforge.event.entity.EntityAttributeCreationEvent
import ru.dbotthepony.mc.otm.client.render.entity.BreadMonsterRenderer
import ru.dbotthepony.mc.otm.client.render.entity.LoaderRenderer
import ru.dbotthepony.mc.otm.client.render.entity.PlasmaProjectileRenderer
import ru.dbotthepony.mc.otm.entity.BreadMonster
import ru.dbotthepony.mc.otm.entity.MinecartCargoCrate
import ru.dbotthepony.mc.otm.entity.PlasmaProjectile
import ru.dbotthepony.mc.otm.entity.RideableDummy
import ru.dbotthepony.mc.otm.entity.*
import ru.dbotthepony.mc.otm.registry.MDeferredRegister
import ru.dbotthepony.mc.otm.registry.MNames
@ -50,6 +48,15 @@ object MEntityTypes {
.build(MNames.BREAD_MONSTER)
}
val LOADER: EntityType<Loader> by registry.register(MNames.LOADER) {
EntityType.Builder.of(::Loader, MobCategory.MONSTER)
.sized(1.2f, 2.5f)
.eyeHeight(2.0f)
.passengerAttachments(2.5f)
.clientTrackingRange(12)
.build(MNames.LOADER)
}
fun register(bus: IEventBus) {
registry.register(bus)
bus.addListener(this::registerAttributes)
@ -58,6 +65,7 @@ object MEntityTypes {
private fun registerAttributes(event: EntityAttributeCreationEvent) {
event.put(BREAD_MONSTER, BreadMonster.createAttributes().build())
event.put(LOADER, Loader.createAttributes().build())
}
@Suppress("unchecked_cast")
@ -71,6 +79,7 @@ object MEntityTypes {
EntityRenderers.register(RIDEABLE_DUMMY, ::NoopRenderer)
EntityRenderers.register(BREAD_MONSTER, ::BreadMonsterRenderer)
EntityRenderers.register(LOADER, ::LoaderRenderer)
}
}
}

View File

@ -26,6 +26,7 @@ import net.minecraft.world.item.Tiers
import net.minecraft.world.item.crafting.Ingredient
import net.minecraft.world.level.block.Block
import net.neoforged.bus.api.IEventBus
import net.neoforged.neoforge.common.DeferredSpawnEggItem
import net.neoforged.neoforge.common.SimpleTier
import ru.dbotthepony.mc.otm.block.MatteryBlock
import ru.dbotthepony.mc.otm.block.addSimpleDescription
@ -512,6 +513,7 @@ object MItems {
val LABORATORY_LAMP_INVERTED: Item by registry.register(MNames.LABORATORY_LAMP_INVERTED) { BlockItem(MBlocks.LABORATORY_LAMP_INVERTED, DEFAULT_PROPERTIES) }
val DANGER_STRIPE_BLOCK: Item by registry.register(MNames.DANGER_STRIPE_BLOCK) { BlockItem(MBlocks.DANGER_STRIPE_BLOCK, DEFAULT_PROPERTIES) }
val METAL_BEAM: Item by registry.register(MNames.METAL_BEAM) { BlockItem(MBlocks.METAL_BEAM, DEFAULT_PROPERTIES) }
val METAL_BEAM_CENTER: Item by registry.register(MNames.METAL_BEAM_CENTER) { BlockItem(MBlocks.METAL_BEAM_CENTER, DEFAULT_PROPERTIES) }
val ENGINE: Item by registry.register(MNames.ENGINE) { BlockItem(MBlocks.ENGINE, DEFAULT_PROPERTIES) }
val HOLO_SIGN: Item by registry.register(MNames.HOLO_SIGN) { BlockItem(MBlocks.HOLO_SIGN, DEFAULT_PROPERTIES) }
@ -665,6 +667,7 @@ object MItems {
val CHEST_UPGRADER: Item by registry.register(MNames.CHEST_UPGRADER) { ChestUpgraderItem() }
val BREAD_MONSTER_SPAWN_EGG: Item by registry.register(MNames.BREAD_MONSTER_SPAWN_EGG){ SpawnEggItem(MEntityTypes.BREAD_MONSTER, 0xFFFFFF, 0xFFFFFF, Item.Properties())}
val LOADER_SPAWN_EGG: Item by registry.register(MNames.LOADER_SPAWN_EGG){ SpawnEggItem(MEntityTypes.LOADER, 0xFFFFFF, 0xFFFFFF, Item.Properties())}
val ROFLITE_ALLOY_INGOT: Item by registry.register(MNames.ROFLITE_ALLOY_INGOT) { Item(DEFAULT_PROPERTIES) }
val ROFLITE_ALLOY_BLOCK: BlockItem by registry.register(MNames.ROFLITE_ALLOY_BLOCK) { BlockItem(MBlocks.ROFLITE_ALLOY_BLOCK, DEFAULT_PROPERTIES) }

View File

@ -25,6 +25,8 @@ object MSoundEvents {
val BLACK_HOLE by make("black_hole", 32F)
val LOADER_AMBIENT by make("loader_ambient")
fun register(bus: IEventBus) {
registry.register(bus)
}

View File

@ -0,0 +1,75 @@
// Made with Blockbench 4.12.3
// Exported for Minecraft version 1.17 or later with Mojang mappings
// Paste this class into your mod and generate all required imports
public class loader<T extends Entity> extends EntityModel<T> {
// This layer location should be baked with EntityRendererProvider.Context in the entity renderer and passed into this model's constructor
public static final ModelLayerLocation LAYER_LOCATION = new ModelLayerLocation(new ResourceLocation("modid", "loader"), "main");
private final ModelPart root;
private final ModelPart Head;
private final ModelPart Body;
private final ModelPart LeftLeg;
private final ModelPart RightLeg;
private final ModelPart LeftArm;
private final ModelPart ElbowL;
private final ModelPart RightArm;
private final ModelPart ElbowR;
public loader(ModelPart root) {
this.root = root.getChild("root");
this.Head = this.root.getChild("Head");
this.Body = this.root.getChild("Body");
this.LeftLeg = this.root.getChild("LeftLeg");
this.RightLeg = this.root.getChild("RightLeg");
this.LeftArm = this.root.getChild("LeftArm");
this.ElbowL = this.LeftArm.getChild("ElbowL");
this.RightArm = this.root.getChild("RightArm");
this.ElbowR = this.RightArm.getChild("ElbowR");
}
public static LayerDefinition createBodyLayer() {
MeshDefinition meshdefinition = new MeshDefinition();
PartDefinition partdefinition = meshdefinition.getRoot();
PartDefinition root = partdefinition.addOrReplaceChild("root", CubeListBuilder.create(), PartPose.offset(0.0F, 24.0F, 0.0F));
PartDefinition Head = root.addOrReplaceChild("Head", CubeListBuilder.create().texOffs(48, 23).addBox(-3.0F, -1.0F, -2.0F, 6.0F, 3.0F, 3.0F, new CubeDeformation(0.0F)), PartPose.offset(-4.0F, -32.0F, -5.0F));
PartDefinition Body = root.addOrReplaceChild("Body", CubeListBuilder.create().texOffs(0, 0).addBox(-10.0F, -16.0F, -5.0F, 20.0F, 10.0F, 13.0F, new CubeDeformation(0.0F))
.texOffs(0, 50).addBox(-3.0F, -3.0F, -4.0F, 6.0F, 5.0F, 8.0F, new CubeDeformation(0.0F))
.texOffs(112, 52).addBox(10.0F, -13.0F, 0.0F, 2.0F, 6.0F, 6.0F, new CubeDeformation(0.0F))
.texOffs(96, 52).addBox(-12.0F, -13.0F, -1.0F, 2.0F, 6.0F, 6.0F, new CubeDeformation(0.0F))
.texOffs(53, 0).addBox(-5.0F, -1.0F, 4.0F, 10.0F, 4.0F, 4.0F, new CubeDeformation(0.0F)), PartPose.offset(0.0F, -26.0F, -1.0F));
PartDefinition antenna_r1 = Body.addOrReplaceChild("antenna_r1", CubeListBuilder.create().texOffs(76, 6).addBox(0.0F, -7.0F, -1.0F, 0.0F, 14.0F, 2.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(8.0F, -22.0F, 8.0F, -0.2618F, 0.0F, 0.0F));
PartDefinition waist_r1 = Body.addOrReplaceChild("waist_r1", CubeListBuilder.create().texOffs(28, 50).addBox(-2.0F, -5.0F, -4.0F, 4.0F, 7.0F, 7.0F, new CubeDeformation(0.0F)), PartPose.offsetAndRotation(0.0F, -3.0F, 2.0F, -0.2618F, 0.0F, 0.0F));
PartDefinition LeftLeg = root.addOrReplaceChild("LeftLeg", CubeListBuilder.create().texOffs(106, 24).addBox(0.0F, 10.0F, -2.0F, 4.0F, 16.0F, 7.0F, new CubeDeformation(0.0F))
.texOffs(66, 46).addBox(-1.0F, -2.0F, -3.0F, 6.0F, 12.0F, 6.0F, new CubeDeformation(0.0F)), PartPose.offset(4.0F, -26.0F, -1.0F));
PartDefinition RightLeg = root.addOrReplaceChild("RightLeg", CubeListBuilder.create().texOffs(84, 24).addBox(-4.0F, 10.0F, -2.0F, 4.0F, 16.0F, 7.0F, new CubeDeformation(0.0F))
.texOffs(48, 34).addBox(-5.0F, -2.0F, -3.0F, 6.0F, 12.0F, 6.0F, new CubeDeformation(0.0F)), PartPose.offset(-4.0F, -26.0F, -1.0F));
PartDefinition LeftArm = root.addOrReplaceChild("LeftArm", CubeListBuilder.create().texOffs(104, 0).addBox(-1.0F, -7.0F, -4.0F, 4.0F, 16.0F, 8.0F, new CubeDeformation(0.0F)), PartPose.offset(13.0F, -36.0F, 2.0F));
PartDefinition ElbowL = LeftArm.addOrReplaceChild("ElbowL", CubeListBuilder.create().texOffs(24, 23).addBox(-2.0F, -0.2F, -2.0F, 4.0F, 19.0F, 8.0F, new CubeDeformation(-0.1F)), PartPose.offset(1.0F, 9.0F, -1.0F));
PartDefinition RightArm = root.addOrReplaceChild("RightArm", CubeListBuilder.create().texOffs(80, 0).addBox(-3.0F, -7.0F, -4.0F, 4.0F, 16.0F, 8.0F, new CubeDeformation(0.0F)), PartPose.offset(-13.0F, -36.0F, 1.0F));
PartDefinition ElbowR = RightArm.addOrReplaceChild("ElbowR", CubeListBuilder.create().texOffs(0, 23).addBox(-2.0F, -0.2F, -2.0F, 4.0F, 19.0F, 8.0F, new CubeDeformation(-0.1F)), PartPose.offset(-1.0F, 9.0F, -1.0F));
return LayerDefinition.create(meshdefinition, 128, 64);
}
@Override
public void setupAnim(Entity entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) {
}
@Override
public void renderToBuffer(PoseStack poseStack, VertexConsumer vertexConsumer, int packedLight, int packedOverlay, float red, float green, float blue, float alpha) {
root.render(poseStack, vertexConsumer, packedLight, packedOverlay, red, green, blue, alpha);
}
}

View File

@ -0,0 +1,166 @@
{
"format_version": "1.8.0",
"animations": {
"Idle": {
"loop": true,
"animation_length": 0.16,
"bones": {
"Body": {
"position": {
"0.0": [0, 0, 0],
"0.08": [0, -0.1, 0],
"0.16": [0, 0, 0]
}
},
"Head": {
"position": {
"0.0": [0, 0, 0],
"0.08": [0, -0.1, 0],
"0.16": [0, 0, 0]
}
},
"LeftArm": {
"position": {
"0.0": [0, 0.1, 0],
"0.12": [0, -0.2, 0],
"0.16": [0, 0, 0]
}
},
"RightArm": {
"position": {
"0.0": [0, 0.1, 0],
"0.12": [0, -0.2, 0],
"0.16": [0, 0, 0]
}
}
}
},
"Move": {
"loop": true,
"animation_length": 0.48,
"bones": {
"Body": {
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.3, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.3, 0],
"0.48": [0, 0, 0]
}
},
"Head": {
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.3, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.3, 0],
"0.48": [0, 0, 0]
}
},
"LeftLeg": {
"rotation": {
"0.0": [-22.5, 0, 0],
"0.24": [22.5, 0, 0],
"0.48": [-22.5, 0, 0]
},
"position": {
"0.0": [0, 0, -2],
"0.12": [0, 0, 0],
"0.24": [0, 1, 1],
"0.36": [0, 2, -2],
"0.48": [0, 0, -2]
}
},
"RightLeg": {
"rotation": {
"0.0": [22.5, 0, 0],
"0.24": [-22.5, 0, 0],
"0.48": [22.5, 0, 0]
},
"position": {
"0.0": [0, 0, 2],
"0.12": [0, 2, -2],
"0.24": [0, 0, -2],
"0.36": [0, 0, 0],
"0.48": [0, 0, 2]
}
},
"LeftArm": {
"rotation": {
"0.0": [6, 0, 0],
"0.24": [-6, 0, 0],
"0.48": [6, 0, 0]
},
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.2, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.2, 0],
"0.48": [0, 0, 0]
}
},
"ElbowR": {
"rotation": {
"0.0": [-30, 0, 0],
"0.24": [-19.5, 0, 0],
"0.48": [-30, 0, 0]
}
},
"RightArm": {
"rotation": {
"0.0": [-6, 0, 0],
"0.24": [6, 0, 0],
"0.48": [-6, 0, 0]
},
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.2, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.2, 0],
"0.48": [0, 0, 0]
}
},
"ElbowL": {
"rotation": {
"0.0": [-16.5, 0, 0],
"0.24": [-25.5, 0, 0],
"0.48": [-16.5, 0, 0]
}
}
}
},
"Atack": {
"animation_length": 0.48,
"bones": {
"LeftArm": {
"rotation": {
"0.0": [0, 0, 0],
"0.2": [-135, 0, 0],
"0.48": [0, 0, 0]
}
},
"ElbowR": {
"rotation": {
"0.0": [-2, 0, 0],
"0.2": [-24.5, 0, 0],
"0.48": [-2, 0, 0]
}
},
"RightArm": {
"rotation": {
"0.0": [0, 0, 0],
"0.2": [-135, 0, 0],
"0.48": [0, 0, 0]
}
},
"ElbowL": {
"rotation": {
"0.0": [-2, 0, 0],
"0.2": [-24.5, 0, 0],
"0.48": [-2, 0, 0]
}
}
}
}
}
}

View File

@ -0,0 +1,167 @@
{
"format_version": "1.8.0",
"animations": {
"Idle": {
"loop": true,
"animation_length": 0.16,
"bones": {
"Body": {
"position": {
"0.0": [0, 0, 0],
"0.08": [0, -0.1, 0],
"0.16": [0, 0, 0]
}
},
"Head": {
"position": {
"0.0": [0, 0, 0],
"0.08": [0, -0.1, 0],
"0.16": [0, 0, 0]
}
},
"LeftArm": {
"position": {
"0.0": [0, 0.1, 0],
"0.12": [0, -0.2, 0],
"0.16": [0, 0, 0]
}
},
"RightArm": {
"position": {
"0.0": [0, 0.1, 0],
"0.12": [0, -0.2, 0],
"0.16": [0, 0, 0]
}
}
}
},
"Move": {
"loop": true,
"animation_length": 0.48,
"bones": {
"Body": {
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.3, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.3, 0],
"0.48": [0, 0, 0]
}
},
"Head": {
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.3, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.3, 0],
"0.48": [0, 0, 0]
}
},
"LeftLeg": {
"rotation": {
"0.0": [-22.5, 0, 0],
"0.24": [22.5, 0, 0],
"0.48": [-22.5, 0, 0]
},
"position": {
"0.0": [0, 0, -2],
"0.12": [0, 0, 0],
"0.24": [0, 1, 1],
"0.36": [0, 2, -2],
"0.48": [0, 0, -2]
}
},
"RightLeg": {
"rotation": {
"0.0": [22.5, 0, 0],
"0.24": [-22.5, 0, 0],
"0.48": [22.5, 0, 0]
},
"position": {
"0.0": [0, 0, 2],
"0.12": [0, 2, -2],
"0.24": [0, 0, -2],
"0.36": [0, 0, 0],
"0.48": [0, 0, 2]
}
},
"LeftArm": {
"rotation": {
"0.0": [6, 0, 0],
"0.24": [-6, 0, 0],
"0.48": [6, 0, 0]
},
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.2, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.2, 0],
"0.48": [0, 0, 0]
}
},
"ElbowR": {
"rotation": {
"0.0": [-30, 0, 0],
"0.24": [-19.5, 0, 0],
"0.48": [-30, 0, 0]
}
},
"RightArm": {
"rotation": {
"0.0": [-6, 0, 0],
"0.24": [6, 0, 0],
"0.48": [-6, 0, 0]
},
"position": {
"0.0": [0, 0, 0],
"0.12": [0, 0.2, 0],
"0.24": [0, 0, 0],
"0.36": [0, 0.2, 0],
"0.48": [0, 0, 0]
}
},
"ElbowL": {
"rotation": {
"0.0": [-16.5, 0, 0],
"0.24": [-25.5, 0, 0],
"0.48": [-16.5, 0, 0]
}
}
}
},
"Atack": {
"animation_length": 0.48,
"override_previous_animation": true,
"bones": {
"LeftArm": {
"rotation": {
"0.0": [0, 0, 0],
"0.2": [-135, 0, 0],
"0.48": [0, 0, 0]
}
},
"ElbowR": {
"rotation": {
"0.0": [-2, 0, 0],
"0.2": [-24.5, 0, 0],
"0.48": [-2, 0, 0]
}
},
"RightArm": {
"rotation": {
"0.0": [0, 0, 0],
"0.2": [-135, 0, 0],
"0.48": [0, 0, 0]
}
},
"ElbowL": {
"rotation": {
"0.0": [-2, 0, 0],
"0.2": [-24.5, 0, 0],
"0.48": [-2, 0, 0]
}
}
}
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 496 B