Ports Old Citcode Storage Reach (#7182)

This commit is contained in:
Aroliacue
2023-11-07 13:37:46 +01:00
committed by GitHub
parent 6984cab970
commit 1e09111bca
4 changed files with 10 additions and 5 deletions
@@ -27,7 +27,7 @@
//If it isn't on the floor. Do some checks to see if it's in our hands or a box. Otherwise give up.
if(istype(I.loc,/obj/item/weapon/storage)) //in a container.
var/sdepth = I.storage_depth(user)
if (sdepth == -1 || sdepth > 1)
if (sdepth > MAX_STORAGE_REACH) // CHOMPedit: Storage reach depth.
return //too deeply nested to access
var/obj/item/weapon/storage/U = I.loc