Ultimate Backpacks - REQUIRES ANOMALY 1.5.2
!!!!!!!!!! IMPORTANT READ ME !!!!!!
IF YOU DONT WANT FDDA YOU CAN TURN IT OFF IN THE MCM
"Upgradeable Backpack" and "Open Backpacks" are not compatible with this mod as this mod basically enhances those mods. If you used "open backpacks" then empty your backpacks before switching to this mod! Consider saving before adding this mod to your load order.
Ultimate Backpacks - REQUIRES ANOMALY 1.5.2
Features
- Upgrade backpacks for additional inventory weight
- Open backpacks and store items inside!
- Holding the modifier key (set in mcm) while taking an item will put the item directly into your worn backpack
- Holding the modifier key and pressing the inventory key will directly open your backpack
- Backpacks can have a weight limit (MCM setting) (works like backpack volume)
- Backpacks can reduce the weight of items carried inside (like in project zomboid) (MCM setting)
- Weight limit and weight reducement can be upgraded at your local mechanic
- Creating a stash with your backpack will put the items directly into your stash
- Having radioactive items in your backpack will also poison you
- FDDA Support
Disclaimer
This addon uses "STALKER UPGRADEABLE BACKPACK by AeroFW" and "Open Backpacks 1.3 by Junx" as base mods, merges them and adds additional functionality. If any of the mod authors have something against me uploading this mod than please reach out to me.
Known Issues
- Changing of MCM-Settings results in some values not updating accordingly -> Save and load the game after changing settings
- Backpack and inventory weight sometimes not updating accordingly -> Reopen the inventory / backpack once or twice will fix the issue for now
- "MOUSE OVER TRANSFER ITEMS" mod works but should not be used to transfer items into your backpack or it will start spamming your inventory with plastic jars
- GAMMA: Item upgrades not showing on backpack hover (upgrades still working!!!) [(if someone knows why this is happening pls reach out to me)]
- EFP: Not tested
Future Plans
Changelog
[06-09-2022] v1.0
[07-09-2022] v1.1
- FDDA support is now optional (not required anymore, remember to turn off the fdda flag in mcm!)
- Open/Close Backpack string is now translateable in the xml files
- Crouching on open is now optional, look in mcm
[30-01-2023] v1.2
- Fix CTD when upgrading backpack in work station - thx to Nikita S.
- Fix CTD when creating stash
RESERVED
Hello, that's a very cool and immersive mod but backpacks open with standart texture, without faction patches. Is there any way to fix this issue? I tried to fix it myself but couldn't find anything
I guess this should be compatible with FDDA, right?
Yes, FDDA is required
Outfit Attachment Overhaul Compatibility?
Havent tested it but should work fine.
hello friend I have a question, how do I make my character not crouch when opening the backpack? I remember that the last time I had to edit something in the script since the FDDA option did not work with the other backpack open plugin, I would like to know what line I should edit so as not to crouch when opening the backpack, I guess it must be the bind_container script
Ps:I would also like to know which is the key that you mention in the description, I am not referring to the modifier key, but to the "main" key, which is used simultaneously to store things in the backpack directly
Crouching is now a flag you can turn on/off in mcm. Regarding the "main key" it is the same as for opening the backpack directly. It only works when you are looting things.
oh I understand, I thought it would also be used in the inventory, thank you very much
A very cool idea for an addon and execution at a high level, thank you for sharing with us! Please add the possibility to translate the context menu line "Open Backpack"
The strings are now in the xml and open for translation :)
Thank you very much, ideally, also divide the name in the MCM line on the left menu and top right title into two different lines in xml so that the left one can be shortened
Any way to have this without FDDA?
FDDA is now optional, just download the new version
Thanks man, appreciate the effort.
I wonder if something is possible, make it so items in backpack don't get automatically arranged, meaning make backpacks "and maybe all stashes?" work just like EFT, you manually position them in the square you want and they stay there. A long stretch but a thought.
Edit: May I ask what's with the Jar spawning and despawning?
Haha yes. For now its a very_diry_hack to ensure the carry weight of the inventory is updated accordingly. It will be changed once I have found a better way.
Edit: Regarding your idea. It sounds very good but for now I would have zero clue how to do it.
Yeah I noticed the inventory issue as well even without your addon, sometimes it forgets updating if you consume something, food, drugs, etc, especially canteen, but once you pick or drop something it changes. With your dirty hack I end up with about 10 jars if I double click fast.
When I right-click and pick "open backpack," the menu opens for a split second and then goes away. I can place things in the pack and make stashes fine though.
Do you have any other addons that could interfere with the same mechanic ? Hard to tell from here whats going on.
Actually what I don't have is 1.5.2 and I don't know how I missed that in the description. Could that actually be the reason it works except for one part?
Its a little weird that it has worked after all with 1.5.1 since the code is using hooks only available in 1.5.2... hmmm best bet is to update to 1.5.2 and try it out again. If the problem is still there then reach out to me again and I will see what I can do
FATAL ERROR
[error]Expression : <no expression>
[error]Function : CScriptEngine::lua_pcall_failed
[error]File : ..\xrServerEntities\script_engine.cpp
[error]Line : 204
[error]Description : fatal error
[error]Arguments : LUA error: f:/anomaly-1.5.2\gamedata\scripts\_g.script:779: attempt to perform arithmetic on local 'num' (a nil value)
Mo shows that there is no file conflict, but the backpack cannot be upgraded and crashed.
Could run the game in debug mode and then bring it to a crash again and send me via pm the whole .log file ?
Well, I get it, the only way to upgrade the backpack is to spend money at the mechanic.
aaaah so have tried to upgrade the backpack yourself then I suppose. Good you mention it. I have not implemented nor tested if it would work with upgrading it yourself. Good point here :) something for the next version. Thx
Playing this with Gamma mod I don't understand why I have phantom plastic appearing and disappearing when I put stuff into the backpack
Read the description
Hi, using Ano 1.5.2, MCM and your mod. Each attempt to create a stash ends in CTD.
Here an excerpt from the crash log:
[error]Arguments : LUA error: .../bin/..\gamedata\scripts\ultimate_backpacks_stash.script:5: attempt to index local 'container' (a nil value).
With simple workaround i could fix it:
if container ~= nil
local inv_box = level.object_by_id(container.id)
else
break
end
TBH i don't know why it works this way, actually it doesn't change anything. Some timing issues ? Maybe it would be clever to move 'inv_box' to own function and return a value ?
Thx, it really helps!
is this incompatible with 1.5.1?
Hello, I got this error when trying to dismount ammo while backpack was open
! [LUA] SCRIPT RUNTIME ERROR
! [LUA] ...1.5.1\gamedata\scripts\ultimate_backpacks_manager.script:121: attempt to index local 'container' (a nil value)
! [SCRIPT ERROR]: ...1.5.1\gamedata\scripts\ultimate_backpacks_manager.script:121: attempt to index local 'container' (a nil value)
FATAL ERROR
[error]Expression : <no expression>
[error]Function : CScriptEngine::lua_error
[error]File : ..\xrServerEntities\script_engine.cpp
[error]Line : 191
[error]Description : fatal error
[error]Arguments : LUA error: ...1.5.1\gamedata\scripts\ultimate_backpacks_manager.script:121: attempt to index local 'container' (a nil value)
stack trace:
Maybe make it so when you talk to a trader and, well, trade with him, that all contents in the backpack appear on your side of the screen. Else you would have to put everything out of the backpack to be able to trade with all your items.
Great mod! Is it possible for you to remove bonus weight gained from wearing backpack?
This mod is great! It's pretty much everything I was looking for in Open Backpacks, the weight system included!
I am having an issue utilizing the key modifier functionality. I set the modifier key to "shift", but pressing "shift+I" to bring up the backpack doesn't work. It just opens the regular inventory. Same for picking up items and placing them directly in to the backpack. No crashes or errors. I also did a save and reload after to see if that would fix it, no change.
Any idea what might be causing it?
EDIT: I also noticed that every backpack has 9 upgrades, three separate tiers with three upgrades of their own. Is this supposed to be this way? Even if they're all around 24K, 90KG on a single backpack seems like overkill. If this was intended, by all means, I'll just ignore it, just wanted to make sure.
Could be that it is a little unbalanced yes. I built this mod particular with gamma in mind where you have to carry around tons of stuff. But be aware that the upgrades do different things. You can upgrade your inventory weight, your backpack weight (volume) and the multiplier for the weight reduction inside the backpack.
As a user of the openable backpack mod for a bit now, you may want to work on ensuring that loading doesn't... unload the backpack.
To explain if you dump all your gear in your back, save and load, it won't check the bag for your weight until you open the bag again. Allowing you to carry infinite gear as long as you save scum a bit.
A godsend for say, a Bandit run where you wipe all the soliders at the X18 factory, buuuut... not very fair obviously. As Mp5ing up there mentioned I tend to prefer a more Tarkov esk approach of leaving where the gear is stored specifically to imagination for the sake of convenience.
Great mod though! This is the holy grail of backpack realism!
Why do my backpacks open without faction patches and how can I fix it?
Hi, did you solve this problem? I have the same one
doesn't work with shift bro (set it as my sprint key)
also the jar thing is weird bro
but good work bro
Could be then conflicting with sprint action I have never tried to double bind the same key so not sure if it is possible to fix. The jar thing to update the inventory weight since anomaly only reacts when items are added/removed from your inventory. Yeah it can become a little buggy sometimes but was the only solution I was able to find. Thanks for the compliment, bro.
Hi, can you add double tap or long press to directly open worn backpack, instead of only shift or alt modifier?
Please, can you release the 1.5.1 ver as an optional download?
I can't update the version of my game because many of the mods I have installed haven't been updated yet to the latest version yet (1.5.2)
I wish I could but a lot of hooks I am using inside the code are only available in 1.5.2 so releasing a 1.5.1 version would lack a lot of features to the point the addon becomes useless. Maybe you could use "open backpack" + "upgradeable backpack" to cover some of the features at least.
The game crashes when trying to upgrade the backpack with workshop.
Mods:
- MCM
- FDDA
- Ultimate Backpack
For full log check your GitLab.
FATAL ERROR
[error]Expression : <no expression>
[error]Function : CScriptEngine::lua_pcall_failed
[error]File : ..\xrServerEntities\script_engine.cpp
[error]Line : 204
[error]Description : fatal error
[error]Arguments : LUA error: e:/locallibrary/stalker anomaly\gamedata\scripts\_g.script:779: attempt to perform arithmetic on local 'num' (a nil value)
stack trace:
I have created a merge request on your GitLab that fixes the issue. Take a look when you can.
It is merged. Thank you very much for the support!
If u have a crash:
Expression : <no expression>
Function : CScriptEngine::lua_pcall_failed
File : ..\xrServerEntities\script_engine.cpp
Line : 204
Description : fatal error
Arguments : LUA error: .../bin/..\gamedata\scripts\ultimate_backpacks_stash.script:5: attempt to index local 'container' (a nil value)
Change ultimate_backpacks_stash.script to the:
function move_items_to_stash(stash_id, id) local c
local inv_box = level.object_by_id(container.id)
local se_stash = level.object_by_id(stash_id)
if(container and inv_box and se_stash) then
local map = {}
local it = 0
function iterate_inventory(box, item)
it = it + 1
map[it] = item
if container ~= nil
local inv_box = level.object_by_id(container.id)
else
break
end
end
inv_box:iterate_inventory_box(iterate_inventory, inv_box)
for i, item in ipairs(map) do
inv_box:transfer_item(item, se_stash)
end
alife_release_id(id)
return true
end
return false
end
Hi. I'm using this mod and when i click on Open Backpack the menu close, opens and immediatly closes, product of this i cant change to my weapons.
Fixed: just disable FDDA Open backpack and couch animations
Hey Bluber2, we're still having this crash when making a stash.
Expression : <no expression>
Function : CScriptEngine::lua_pcall_failed
File : ..\xrServerEntities\script_engine.cpp
Line : 204
Description : fatal error
Arguments : LUA error: .../bin/..\gamedata\scripts\ultimate_backpacks_stash.script:5: attempt to index local 'container' (a nil value)
I created an issue on your Gitlab for this mod 3 weeks ago.
Just thought I'd update you.
It is fixed with the last update. Thanks for keeping me updated :)