-
Notifications
You must be signed in to change notification settings - Fork 4
Adding GenerateCreativeStacks behavior
Important
Make sure to familiarize yourself with the library's syntax: Attribute‐based Matching
Here are listed all the properties that can be used for blocks and items with the GenerateCreativeStacks collectible behavior.
Add the following behavior:
Note
Everything listed below can only be used in behavior's own properties
This property is equivalent to the base game's VariantGroups, which defines all groups from which the itemstacks in the creative inventory will be created. The main difference is that unlike the base game, which creates unique items, these variant groups will show up in the attributes instead. Example:
"variantgroups": [
{ "code": "a", "states": [ "a1", "a2", "a3" ] },
{ "code": "b", "states": [ "b1", "b2", "b3"] },
{ "code": "c", "loadFromProperties": "game:block/metal", "combine": "multiply" }
]All functionality and requirements from RegistryObjectVariantGroup apply.
This property performs the same functionality as the base game's CreativeInventory property, but uses attribute-based matching syntax instead. It allows you to define which itemstacks will end up in what tab in the creative menu. Example:
"creativeinventory": {
"general": [ "*" ], // All generated itemstacks will show up in the general tab
"decorative": [ "c-copper", "a-a1::b-b2" ] // itemstacks with c = copper, and itemstacks with
// a = a1 and b = b2 will show up in the decorative tab
}This property performs the same functionality as the base game's AllowedVariants property, but uses attribute-based matching syntax instead. It can be used to only allow variants that match any entry in the list. Example:
"allowedvariants": [
"a-a1::b-b2::c-*", // any variant with a = a1, b = b2 and c any value
"a-a2::b-b2::c-*", // any variant with a = a2, b = b2 and c any value
"c-iron" // any variant with c = iron
]This property performs the same functionality as the base game's SkipVariants property, but uses attribute-based matching syntax instead. It can be used to exclude variants that match any entry in the list. Example:
"skipvariants": [
"c-steel", // any variant with c = steel excluded
"c-gold", // any variant with c = gold excluded
"c-bismuth" // any variant with c = bismuth excluded
]