Class PoseRegistry

java.lang.Object
foundry.veil.api.client.registry.PoseRegistry

public class PoseRegistry extends Object
  • Field Details

    • poses

      public static Map<Predicate<net.minecraft.world.item.Item>,ExtendedPose> poses
    • BOW

      public static ExtendedPose BOW
      An example pose registered by Veil. This pose is applied when the player is using a bow. It slowly raises the arms as the bow is drawn.
    • CROSSBOW

      public static ExtendedPose CROSSBOW
    • TRIDENT

      public static ExtendedPose TRIDENT
      An example pose registered by Veil. This pose is applied when the player is using a trident. It captures some model data and uses it to pose the body.
  • Constructor Details

    • PoseRegistry

      public PoseRegistry()
  • Method Details

    • registerPose

      public static ExtendedPose registerPose(net.minecraft.world.item.Item item, ExtendedPose pose)
      Add a ExtendedPose to the registry.
      Parameters:
      item - The item that triggers the pose.
      pose - The pose.

      Create an ExtendedPose, either using an anonymous class or a separate class. You are given a PoseData object which contains various state data of the model.

    • registerPose

      public static ExtendedPose registerPose(Predicate<net.minecraft.world.item.Item> itemPredicate, ExtendedPose pose)
      Add a ExtendedPose to the registry.
      Parameters:
      itemPredicate - A predicate that determines if the pose should be applied to the item.
      pose - The pose.

      Create an ExtendedPose, either using an anonymous class or a separate class. You are given a PoseData object which contains various state data of the model.