BL Coding Workshop with created item showing error, what I'm missing?

Users who are viewing this thread


I wanted to add some trade goods and have a new workshops that will create those items. After seeting the core xml I was able to get the workshop in the game then used one of the existing food to create a new item, but while testing during gameplay in the workshop page the output shows "ERROR: Text with id str_item_category doesn't exist!", the workshop doesn't buy the input item and just sits there doing nothing.

For now I only have two xml files, one for workshop and another for the item, I can get the item with console commands and it works just like any other food, both xml files in the end for reference.

I tried searching an xml that hold item categories but didn't find any place where those are declared, searching the internet the only thing I found was that item categories might be hardcoded.

What I should do to make the workshop actually produce the new item? Is there more xml that I need to add?

<?xml version="1.0" encoding="utf-8"?>
  <WorkshopType id="test" name="Test Workshop" frequency="1" equipment_cost="2000" jobname="Tester" description="Test workshop">
    <Meshes sign_mesh_name="shop_sign_merchantpottery" shop_prop_mesh_name_1="shop_prop_merchantpottery_a" shop_prop_mesh_name_2="shop_prop_merchantpottery_b" shop_prop_mesh_name_3_1="shop_prop_merchantpottery_c" shop_prop_mesh_name_4="shop_prop_merchantpottery_d" shop_prop_mesh_name_5="shop_prop_merchantpottery_e" shop_prop_mesh_name_6="shop_prop_merchantpottery_f" />
    <Production conversion_speed="1">
        <Input input_item="grain" />
        <Output output="ItemCategory.test" output_count="50" />

<?xml version="1.0" encoding="utf-8"?>
  <Item id="test"
        name="Test{@Plural}testing of tests{\@}"
      <Trade morale_bonus="1" />
    <Flags Civilian="true" />


Downloaded a decompiler and had a look at the dll, found where the default item categories are created.

I believe for the next step I'm going to learn how to run my own code and see if I can add a custom category.

Just for reference if someone in the future searches for something related here is where the default item categories are created.

Item category
...\Mount & Blade II Bannerlord\bin\Win64_Shipping_Client\TaleWorlds.Core.dll
TaleWorlds.Core > DefaultItemCategories.cs
Upvote 0
Top Bottom