Class TransformCopyingModel<S,D>
java.lang.Object
net.minecraft.client.model.Model<com.mojang.datafixers.util.Pair<S,D>>
net.fabricmc.fabric.api.client.rendering.v1.TransformCopyingModel<S,D>
- Type Parameters:
S- type of the source model stateD- type of the delegate model state
public final class TransformCopyingModel<S,D>
extends net.minecraft.client.model.Model<com.mojang.datafixers.util.Pair<S,D>>
A model that copies transforms from a source model to a delegate model.
Useful in cases where an overlay model may not be a subclass of its base model.
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.client.model.Model
net.minecraft.client.model.Model.Simple -
Field Summary
Fields inherited from class net.minecraft.client.model.Model
renderType, root -
Method Summary
Modifier and TypeMethodDescriptionstatic <S,D> TransformCopyingModel <S, D> create(net.minecraft.client.model.Model<? super S> source, net.minecraft.client.model.Model<? super D> delegate, boolean setDelegateAngles) voidMethods inherited from class net.minecraft.client.model.Model
allParts, renderToBuffer, renderToBuffer, renderType, resetPose, root
-
Method Details
-
create
public static <S,D> TransformCopyingModel<S,D> create(net.minecraft.client.model.Model<? super S> source, net.minecraft.client.model.Model<? super D> delegate, boolean setDelegateAngles) - Parameters:
source- the model whose transforms will be copieddelegate- the model that will be rendered with transforms copied from the source modelsetDelegateAngles-trueif theModel.setupAnim(Object)method should be called for the delegate model after it is called for the source model
-
setupAnim
-