- 好友
- 1
- 在线时间
- 0 小时
- 最后登录
- 2026-2-1
随仆

- UID
- 3840361
- 第纳尔
- 0
- 精华
- 0
- 互助
- 0
- 荣誉
- 0
- 贡献
- 0
- 魅力
- 0
- 注册时间
- 2026-1-13
 鲜花( 0)  鸡蛋( 0)
|
发表于 2026-1-14 19:24:18
|
显示全部楼层
If YOU are the modder this is done indirectly:
at header_operations.py notice
(troop_get_inventory_capacity, <destination>, <troop_id>),
and
(store_free_inventory_capacity, <destination>, [troop_id]),
These are indirectly linked to skill "inventory_management" which gives 6 per skill point plus a base of 30
the first 10 inventory slots are items you wear or equip, your horse, and an optional food slot, meaning effectively 20 + (6*inventory management)
notice header_items.py sets a maximum inventory count max_inventory_items
This is important because if troops all are assumed to have an inventory this number sets the number of inventory slots to reserve at every troop line - and you may have 1000s of troops defined.
I like the suggestion of "unlimited chests" but every chest needs to be defined in module_troops, and changing the troops defined will blow away the savegame (been, did that). So best to add the chests early, before anyone wants to keep the savegame they are building, especially if they are not using my Phantasy Calradia (2024) lua assisted intermediate export to skip past save game breaking changes at mods.
Other than this, you could also silently pump all your troops (or just the player) with a boost to inventory management skill.
look up the skill id at ID_skills.py after your last compile and see which skill number to use.
then for example
(troop_raise_skill, "trp_player", skl_inventory_management, 4),
I usually place a menu option such as "Lua test 1" to manually run some one off script fragment like that that I can call later from in the game under the camp menu (and probably several menus under that as menus are limited to 15 choices maximum by Warband)
and at module_scripts.py add a simple script like
("mysimple_script_35", [
(troop_raise_skill, "trp_player", skl_inventory_management, 4),
]),
and I am off with 20 more inventory slots per press of that menu item, except once I hit the maximum I defined any others get clipped. You should make SURE they get clipped so you don't overflow your inventory items and walk all over the rest of your savegame, by the way. Ooops!
But I digress.
Enjoy modding - once you start, you will never see reality the same way (or at least you start appreciating "life" a little more once you see how difficult it is to be "God" for a few minutes). I suck at it, but don't tell anyone -- we all do. That's why mods need more people as they get more complex.
- GS
|
|