Class ArmatureModelAdapter

java.lang.Object
net.minecraft.client.model.Model<ArmatureFrame>
net.ixdarklord.coolcatcanvas.internal.client.armature.render.ArmatureModelAdapter

public final class ArmatureModelAdapter extends net.minecraft.client.model.Model<ArmatureFrame>
Lets a posed armature go through vanilla's model drawing (submitModel), so it gets what vanilla models get for free: the glowing outline, the block-breaking overlay, see-through sorting, and tint and overlay colours. A vanilla model is a tree of boxes; this one is a single "box" whose drawing is the armature's faces for one mesh group, posed by the frame handed to setupAnim(ArmatureFrame). Vanilla sets a model up and draws it straight away, one submit at a time, so one adapter per group serves every armature.
  • 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 Type
    Method
    Description
    forGroup(int group)
    The adapter that draws one mesh group.
    void
     

    Methods inherited from class net.minecraft.client.model.Model

    allParts, renderToBuffer, renderToBuffer, renderType, renderType, resetPose, root

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • forGroup

      public static ArmatureModelAdapter forGroup(int group)
      The adapter that draws one mesh group. Render thread only.
    • setupAnim

      public void setupAnim(ArmatureFrame frame)
      Overrides:
      setupAnim in class net.minecraft.client.model.Model<ArmatureFrame>