SignTypes
100s of signs? no! 1000s of signs? no! 1000000 signs? STILL NOT ENOUGH.
Road Signs need some way to have a texture, name and a way to tell the Dynamic Sign which model shape to use. This is made easy by using SignTypes, a custom registry that uses datapack functions and such.
SignTypes are a Data-Driven feature. You can add as much as you want (within limits of course).
All that is required is a resource pack and a datapack, and you can get building!
All sign textures must go into this directory:
"thingamajigslongroads:textures/entity/signs"
, otherwise, the textures won't be found by SignTypes!
The datapack structure is this (from top level 'datapacks' in a world folder):
"datapackname > data > thingamajigslongroads > thingamajigslongroads > sign_types > put your sign types here"
Sign Types have the following formatting in JSON:
{
"asset_id": "thingamajigslongroads:sign_texture_name",
"sign_model_type": "square",
"translation_key": "sign_type.sign_type_title.name"
}
The asset_id
is the ResourceLocation
to be used for the SignType
. Since most of the work is done for you, just put your textures in the thingamajigslongroads:textures/entity/signs
folder and make sure that your texture file name is the same as the asset_id
.
The sign_model_type
is the kind of sign model you want to use for your texture. It can be any of the following:
square
double_square
rectangle
Square is the standard 1x1 block shape, double square is the 2x2 sign, and rectangle is the 2x1 sign.
The translation_key
is the title of the SignType, shown in the Dynamic Sign GUI. You must provide a translation for this or key will be used as the text in the GUI instead.
These are the basics of SignTypes, just experiment and see what you can make!
Last updated