News:

Welcome to World of Banished!

Main Menu

Apiary Mod with two choices

Started by dmax, February 24, 2019, 03:17:58 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

dmax

Hi, I try to create an apiary mod with two food's production (honey and honeyvinegar), modify the apiary in the developer kit. I have 6 folders (Dialog, Models, Profession, Template, Texture and UI). In the Dialog, Profession and Texture folder I haven't modified any files. In Models and UI folders i added/create for each "honey" files or text-string, its corresponding "honeyvinegar" files (both ".rsc" and ".png") or text-string; in Template folder i create a "RawMaterialHoneyVinegar.rsc" file and in the "Apiary.rsc" i added ConsumeProduceDescription consumeproduce
{
Product _products
[
{
ComponentDescription _produceMaterial = "Template/RawMaterialHoney.rsc";
ResourceLimit _resourceLimit = Food;
String _requirements = "HoneyRequire";
}
{
ComponentDescription _produceMaterial = "Template/RawMaterialHoneyVinegar.rsc";
ResourceLimit _resourceLimit = Food;
String _requirements = "HoneyVinegarRequire";
}
]

StringTable _stringTable = "UI/ApiaryStringTable.rsc";

float _workTime = 4.0;
ToolType _toolType = Hoe;
int _workRequired = 10;
}


i modify also, apiary.rsc, apiaryResources.rsc and Package.rsc files and i create my apiary mod with bat file. No errors during the packagin and i have my Apiary.pkm file, but in game I can't choose between the two products (honey and honeyvinegar), because there isn't any menu for selection.

where am I wrong?

thanks

Gatherer

I'm not a modder myself but this topic might give a nudge in the right direction  - - > http://worldofbanished.com/index.php?topic=2866.0
There's never enough deco stuff!!!
Fiat panis.

Discrepancy

You will need to add the consume produce UI element into the Template file to show up the product selector on the building if desired for selection of product vs random.


UIDescription ui
{
ObjectType _type = ConsumeProduceUI;
ElementDescription _element = "Dialog/ConsumeProduce.rsc";
String _insertAt = "userGroup0";
}




dmax

QuoteI'm not a modder myself but this topic might give a nudge in the right direction  - - > http://worldofbanished.com/index.php?topic=2866.0
Thanks Gatherer. That topic help me to understand more on the mod and the correct operation.

QuoteYou will need to add the consume produce UI element into the Template file to show up the product selector on the building if desired for selection of product vs random.
Yes, this strings show the menu. Thanks Discrepancy