Extending Placeable Properties
Last updated
Last updated
Just for the overview here is a example of the scriptable
The grid type and object group info are simple enums which can be found under Scripts → Enums. Simply extend the enums as you like to add more groups or grid types. You can have as many as you want. Adding a third grid type would allow you having up to 3 objects at the same grid position.
The Remove UI dropdown will automatically handle the new type at the same time you add it to the enum. It just shows all enums in the dropdown, so nothing to adapt here.
For the tab based shop UI, you would need to add a new sub-shop. The tab creation is handled automatically. The only thing you need to do is to locate the Grid Shop UI prefab and navigate to the Sub Shops. Then simply duplicate one of the sub-shops (I duplicated the Terrains one). Select the duplicated shop, rename it as you want and change the object group in the attached shop initializer script
After you create new placeables for your new group and add them to the database, everything should work fine with the shop and the remove-UI.