Json Entity Animation
Json Entity Animation(简称 JsonEA)是一个库模组,供其他模组通过 JSON 而非代码来定义动画使用。我们还提供了一个 Blockbench 插件(也可在 Blockbench 插件浏览器中找到),用于将你的动画导出为该格式。
给开发者
使用 Modrinth Maven 将该模组作为依赖项添加。
dependencies {
include(modImplementation("maven.modrinth:json-entity-animation:0.2.1+1.19.4"))
}
添加后,请将你的动画 JSON 文件放入 assets/modid/jsonea 目录中。要加载这些动画,你的实体模型必须继承自 SinglePartEntityModel/HierarchicalModel。然后定义一个 JsonAnimator 字段以及动画 ID。
public class MyEntityModel extends SinglePartEntityModel<MyEntity> {
private static final Identifier PUNCH_ANIMATION = new Identifier("modid", "my_entity/punch");
private final JsonAnimator animator = new JsonAnimator(this);
// ...
@Override
public void setAngles(MyEntity entity, float limbAngle, float limbDistance, float animationProgress, float headYaw, float headPitch) {
getPart().traverse().forEach(ModelPart::resetTransform);
animator.animate(entity.punchState, PUNCH_ANIMATION, animationProgress);
}
}
你是这个资源的作者?登录后可认领此资源。
相似资源
Woot Revived
pharuxtan
一个用于收集生物掉落物的多区块模组。
生物科技
349
玉Jade ?
Snownee
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
实用前置
339
物品管理器Just Enough Items (JEI)
mezz
查看物品与配方
前置实用
239
KubeJS
Lat
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
前置实用
239
AAA Particles
ChloePrime
适用于 MC 1.18+ 的 Effekseer 加载器
前置装饰
186
WTHIT
deirn
那是什么?一个 Waila/Hwyla 的分支。
前置实用
165
评论 0
登录后参与评分
还没有评论,来抢沙发吧