Project Zomboid

Project Zomboid

82 평점
JB Max Capacity Override
2
   
어워드
즐겨찾기
즐겨찾기됨
즐겨찾기 해제
파일 크기
게시일
업데이트일
572.128 KB
2025년 3월 25일 오후 4시 36분
2025년 7월 31일 오후 6시 14분
업데이트 노트 12개 (보기)

다운로드 위해 구독하기
JB Max Capacity Override

설명
Pure Lua Max Capacity Override (v1.1)
🚀 Now with 98.355% less jank!

Compatible ONLY with Build 42 — does NOT work with Build 41.



📝 Summary
This mod provides a pure Lua MAX_CAPACITY override without needing any Java mod installations. It works on:
  • "Equipable" Bags
  • Crates / Containers
  • Truck beds / Trunks
  • Sprite containers (with some limitations)



Regarding the "require=\StarlitLibrary" line in the mod.info: As of Build 42, the backslash is required. https://pzwiki.net/wiki/Mod.info



⚠️ This mod does nothing on its own. It’s intended for your friendly neighborhood modder.



Requires Starlit Library by albion for correct tooltip capacity display.



🆕 07/31/25
Re-added mod data override for single containers. Example usage:
yourContainer:getModData()["JB_MaxCapacityOverride"] = { capacity = 75 }

✅ Works if the container type exists in the lookup table
✅ Compatible with bags and sprite containers
❌ Mod data override not yet compatible with trunks (WIP)



⚒️ Current To-Do List
  • [ ] Add equipped weight override
  • [ ] Handle right-click grab bug
  • [ ] Consider player inventory capacity override (probably not)
  • [ ] Fix transfer times for heavy items in world context (borked right now)



📌 Side note: The World Object Context Menu can eat me.



💨 Performance Boost
Includes Nepenthe's speed fix from Remove Bag Slowdown (used with permission).

💌 Drop likes and awards on Nepenthe’s workshop:
https://gtm.steamproxy.vip/id/drstalker/myworkshopfiles/

⚠️ This fix does NOT bypass the “Heavy Load” moodle slowdown.



🧪 Argument Structure (for addContainer)
("type", capacity, preventNesting, _equippedWeight, _transferTimeSpeed)

type | string | Container type (use getType() to find it)
capacity | number | Max weight container can hold
preventNesting | boolean | Prevents nesting same type containers
_equippedWeight | number | (optional) Weight of equipped container
_transferTimeSpeed | number | (optional) Transfer time override

✅ Error checking included for capacity and preventNesting.
❓ Equipped weight and transfer speed are optional — defaults to nil.

📦 How To Use
[ ] Create a new Lua file
[ ] Add and customize the following code:

local JB_MaxCapacityOverride = require("JB_MaxCapacityOverride")

JB_MaxCapacityOverride.addContainer("Bag_ShotgunDblSawnoffBag", 125, true, nil, 30)
JB_MaxCapacityOverride.addContainer("militarycrate", 180, true)
JB_MaxCapacityOverride.addContainer("TruckBedOpen", 500, false)

[ ] Add to your mod.info: require=JB_MaxCapacityOverride

[ ] Upload to the workshop



🐛 Found a bug? No you didn't. Really? Aight, report it here please:
🔗 https://github.com/mikej1977/JB_MaxCapacityOverride



Mod Name: JB_MaxCapacityOverride
Mod ID: 3452113500
인기 토론 모두 보기(1)
12
2025년 4월 8일 오후 12시 05분
Players Inventory
Flexible Games
댓글 80
neobenmike 2025년 8월 15일 오후 10시 56분 
No worries, already got it working, thanks
jbdiablo  [작성자] 2025년 8월 15일 오후 8시 33분 
@neobenmike - which version of 42 are you running?
neobenmike 2025년 8월 15일 오후 6시 11분 
Can't enable mod due to requirement typo: \StarlitLibrary instead of just StarlitLibrary
jbdiablo  [작성자] 2025년 7월 31일 오전 10시 58분 
Re-uploaded the mod data enhancement. See description on how to use it and the limitations.

Thank you Eizen for the inspiration and testing!
jbdiablo  [작성자] 2025년 7월 30일 오전 7시 57분 
no worries, go ahead and hit me up on discord @jimbeamdiablo
Eizen 2025년 7월 30일 오전 4시 16분 
@jbdiablo thank you for all the help. I managed to solve my issue except when equipping the backpack the capacity reverts back. Can I message you in discord? Btw I saw the thread in the discord link that you gave me. I'm really sorry for the clutter that I made in your comment section
jbdiablo  [작성자] 2025년 7월 29일 오후 5시 05분 
I broke it. Reverting until I can figure it out
jbdiablo  [작성자] 2025년 7월 29일 오후 2시 56분 
Added a mod data capacity override for single containers. To use:

yourContainer:getModData()["JB_MaxCapacityOverride"] = { capacity = 75 }

It still checks if your container type is in the lookup table first. Let me know if there are any issues with it. Cheers!
jbdiablo  [작성자] 2025년 7월 29일 오후 12시 13분 
@Eizen - I don't know what you're cooking but I tested and mod data was persistent on the item. I'll mess around with my code in a bit to check for mod data when patching capacities.
jbdiablo  [작성자] 2025년 7월 29일 오전 11시 34분 
I was trying to find a work around to preserve mod data, because that's messed up.