-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
修复了代码中的包导入问题,并添加了新的抽象类StdDriestEffectMagic。
- Loading branch information
1 parent
3970b42
commit 2eb8db6
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
32 changes: 32 additions & 0 deletions
32
src/main/java/com/ictye/the_origin_of_magic/CustomModel/CustomModel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// Made with Blockbench 4.9.4 | ||
// Exported for Minecraft version 1.17+ for Yarn | ||
// Paste this class into your mod and generate all required imports | ||
|
||
package com.ictye.the_origin_of_magic.CustomModel; | ||
|
||
import net.minecraft.client.model.*; | ||
import net.minecraft.client.render.VertexConsumer; | ||
import net.minecraft.client.render.entity.model.EntityModel; | ||
import net.minecraft.client.util.math.MatrixStack; | ||
import net.minecraft.entity.Entity; | ||
|
||
public class CustomModel extends EntityModel<Entity> { | ||
private final ModelPart bb_main; | ||
public CustomModel(ModelPart root) { | ||
this.bb_main = root.getChild("bb_main"); | ||
} | ||
TexturedModelData getTexturedModelData() { | ||
ModelData modelData = new ModelData(); | ||
ModelPartData modelPartData = modelData.getRoot(); | ||
ModelPartData bb_main = modelPartData.addChild("bb_main", ModelPartBuilder.create().uv(-12, -12).cuboid(-7.0F, -14.0F, -7.0F, 14.0F, 14.0F, 14.0F, new Dilation(0.0F)), ModelTransform.pivot(0.0F, 24.0F, 0.0F)); | ||
return TexturedModelData.of(modelData, 16, 16); | ||
} | ||
@Override | ||
public void setAngles(Entity entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch) { | ||
} | ||
@Override | ||
public void render(MatrixStack matrices, VertexConsumer vertexConsumer, int light, int overlay, float red, float green, float blue, float alpha) { | ||
bb_main.render(matrices, vertexConsumer, light, overlay, red, green, blue, alpha); | ||
} | ||
|
||
} |