Entity Variants
What is an Entity Variant?
Entity variants are a vanilla Minecraft feature and allow you to add retextured variants of existing entities to the game. (Minecraft Wiki)
Registering a custom entity variant
You can register a custom entity variant like this:
@Init(stage = InitStage.PRE_PACK) // (1)!
object EntityVariants {
val BLUE_COW by ExampleAddon.cowVariant("blue") {
spawnConditions {
// (2)!
}
texture(CowModelType.WARM /*(3)!*/) {
texture("entity/cow/blue")
}
}
}
- Nova will load this class during addon initialization, causing your variants to be registered.
- The conditions for your custom variant to be selected when spawning. See Minecraft Wiki - Spawn Conditions for more information.
- Some entities offer multiple model types. For example, the warm cow has horns. You can select the model type here.