public class ConnectingModelType extends java.lang.Object implements ModelType<ConnectingModelData>
| Modifier and Type | Field and Description |
|---|---|
static net.minecraft.util.ResourceLocation |
DEFAULT_CONNECTION_KEY |
| Constructor and Description |
|---|
ConnectingModelType() |
| Modifier and Type | Method and Description |
|---|---|
net.minecraft.client.renderer.model.IBakedModel |
bake(ModelBakingContext context,
ConnectingModelData data)
Converts the model data into a baked model.
|
ConnectingModelData |
deserialize(com.google.gson.JsonObject json)
Deserializes the given json to some data.
|
net.minecraft.client.renderer.model.BlockModel |
getAsVanillaModel(ConnectingModelData data)
Represents the model as a vanilla
BlockModel instance. |
java.util.Collection<net.minecraft.util.ResourceLocation> |
getModelDependencies(ConnectingModelData data)
Gets all the dependencies on other model files.
|
java.util.Collection<SpriteIdentifier> |
getTextureDependencies(GatherTexturesContext context,
ConnectingModelData data)
Gets all the dependencies on sprites.
|
com.google.gson.JsonObject |
serialize(ConnectingModelData value)
Serializes the given data to json.
|
public static final net.minecraft.util.ResourceLocation DEFAULT_CONNECTION_KEY
public java.util.Collection<net.minecraft.util.ResourceLocation> getModelDependencies(ConnectingModelData data)
ModelTypegetModelDependencies in interface ModelType<ConnectingModelData>data - custom model datapublic java.util.Collection<SpriteIdentifier> getTextureDependencies(GatherTexturesContext context, ConnectingModelData data)
ModelTypegetTextureDependencies in interface ModelType<ConnectingModelData>context - context for gathering texture dependenciesdata - custom model dataGatherTexturesContext@Nullable public net.minecraft.client.renderer.model.BlockModel getAsVanillaModel(ConnectingModelData data)
ModelTypeBlockModel instance. May be used gather info from other models, such as with the vanilla 'parent' property.
If the model cannot be represented as a BlockModel instance, this method should return null.getAsVanillaModel in interface ModelType<ConnectingModelData>data - custom model dataBlockModel instance, or null if such a representation is not availablepublic net.minecraft.client.renderer.model.IBakedModel bake(ModelBakingContext context, ConnectingModelData data)
ModelTypebake in interface ModelType<ConnectingModelData>context - context for baking the modeldata - custom model dataModelBakingContextpublic ConnectingModelData deserialize(com.google.gson.JsonObject json) throws com.google.gson.JsonParseException
Serializerdeserialize in interface Serializer<ConnectingModelData>com.google.gson.JsonParseException - if the given json does not match the expected formatpublic com.google.gson.JsonObject serialize(ConnectingModelData value)
Serializerserialize in interface Serializer<ConnectingModelData>