Difference between revisions of "Apiary Helper Component"
DeamonHunter (Talk | contribs) (Initial commit.) |
(No difference)
|
Revision as of 22:37, 19 July 2017
Category:Component Modding are all optional properties that can be added to any file. Components are useful in extending the original files with even more information, such as the cost of the item or whether the block can be broken by a weapon.
On this page, we go over the Apiary Helper component, signified by the following;
"apiaryHelper": { =Content= }
Apiary Helper components are used to specify functionality on items that will be used on an apiary. This component includes purely functional changes. This Apiary Helper component also complements the Apiary component, which provides information on the apiaries themselves.
When and How to use
Apiary Helper component is needed whenever you want an item to interact with an Apiary. Specifically, this includes the items that will count as the Queen, Drone, Smoker and the Collector.
To start off with first, you will need to create a Item. Once that is done, you can add the following below the last property of the file;
"apiaryHelper": { "type": "", },
This is rather simple. "type" can only be 1 of 4 different values. "Queen" for queen, "Worker" for Worker, "Smoker" for the smoker and finally "Collector" for things that collect from the apiary. This is all that is needed for the queen, worker or smoker.
However the collector needs one more property, outlined below;
"apiaryHelper": { "type": "collector", "collectedItem": "staxel.item.gatherable.HoneyPotFull" },
"collectedItem" is the code of the Item you want to replace the item doing the collecting.
With that, this component is complete. You may want to also look into Apiary Component for making the apiary.
Config Options
All config options must be inside the body of;
"apiaryHelper": { =Config Here= }
"type"
Valid options (String): "Queen", "Worker", "Smoker", "Collector"
Default Value: No default value is specified. Always need to provide your own.
This is the type of item the Apiary will think it is. "Queen" adds a queen to the apiary. "Worker" adds a worker to the apiary. "Smoker" will calm the bee's down. "Collector" will collect honey. If collector is used "collectedItem" has to be included.
"collectedItem"
Valid options (String): A string that contains the code to an Item
Default Value: Must be filled if "type" is collector.
This will be the item it will spawn in place of the collector item. The collector item will be destroyed, allowing this new item to act as a "filled" item.