mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-23 21:12:24 +01:00
Bugfix persistence of items in inventories and persistent charge card location (#22426)
# Summary This PR fixes two bugs with persistent items, trash and the persistent charge card. ## Changes - Fixed the prevention of trash in inventories becoming persistent also preventing any items on characters becoming persistent. - Fixed persistent charge card location on init. If the card is not in an command area, it will be moved into the XO office, if it is in a command area, it will stay there.
This commit is contained in:
@@ -495,7 +495,7 @@
|
||||
if(!persistency_considered_trash)
|
||||
return
|
||||
|
||||
if(in_storage) // Items getting moved into storages (lunchboxes, backpacks) triggers the dropped handler and requires no persistency as a result
|
||||
if(in_storage || in_inventory) // Items getting moved into storages (lunchboxes, backpacks) triggers the dropped handler and requires no persistency as a result
|
||||
SSpersistence.objectsDeregisterTrack(src)
|
||||
return
|
||||
|
||||
@@ -543,6 +543,7 @@
|
||||
addtimer(CALLBACK(src, PROC_REF(check_maptext)), 1) // invoke async does not work here
|
||||
in_inventory = TRUE
|
||||
do_pickup_animation(user)
|
||||
try_make_persistent_trash()
|
||||
|
||||
// called when this item is removed from a storage item, which is passed on as S. The loc variable is already set to the new destination before this is called.
|
||||
/obj/item/proc/on_exit_storage(obj/item/storage/S as obj)
|
||||
|
||||
Reference in New Issue
Block a user