ModelHelper

public abstract class ModelHelper

Collection of utilities for model implementations.

Functions

faceFromIndex
Link copied to clipboard
@Contract(value = null -> null)
static Direction faceFromIndex(int faceIndex)
Use to decode a result from toFaceIndex.Return value will be null if encoded value was null.
toFaceIndex
Link copied to clipboard
static int toFaceIndex(Direction face)
Convenient way to encode faces that may be null.
toQuadLists
Link copied to clipboard
static Array<List<BakedQuad>> toQuadLists(Mesh mesh)
Converts a mesh into an array of lists of vanilla baked quads.Useful for creating vanilla baked models when required for compatibility.

Properties

MODEL_TRANSFORM_BLOCK
Link copied to clipboard
public final static ModelTransformation MODEL_TRANSFORM_BLOCK
Mimics the vanilla model transformation used for most vanilla blocks,and should be suitable for most custom block-like models.
NULL_FACE_ID
Link copied to clipboard
public final static int NULL_FACE_ID
Result from toFaceIndex for null values.
TRANSFORM_BLOCK_1ST_PERSON_LEFT
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_1ST_PERSON_LEFT
TRANSFORM_BLOCK_1ST_PERSON_RIGHT
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_1ST_PERSON_RIGHT
TRANSFORM_BLOCK_3RD_PERSON_RIGHT
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_3RD_PERSON_RIGHT
TRANSFORM_BLOCK_FIXED
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_FIXED
TRANSFORM_BLOCK_GROUND
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_GROUND
TRANSFORM_BLOCK_GUI
Link copied to clipboard
public final static Transformation TRANSFORM_BLOCK_GUI

Sources

jvm source
Link copied to clipboard