various fixes v2

1 - Loadout items no longer duplicate backpack items, and all items get stored into backpacks properly
2 - Fixed a runtime with captain's job on roundstart. They will now be announced when they join at the start of the shift.
3 - Fixed filter runtime when transferring ckeys
4 - Economy SS no longer fires, so it will no longer clutter runtime logs
5 - Fixed laughing peas not being able to be taken out of seed extractors by lazily renaming them
This commit is contained in:
DragonTrance
2021-04-20 00:52:33 -07:00
parent 11a41d1bc1
commit b4039d7cbb
9 changed files with 120 additions and 105 deletions
+15 -6
View File
@@ -29,13 +29,22 @@ Captain
/datum/job/captain/get_access()
return get_all_accesses()
/datum/job/captain/announce(mob/living/carbon/human/H)
..()
var/displayed_rank = H.client.prefs.alt_titles_preferences[title]
if(!displayed_rank)
displayed_rank = "Captain"
SSticker.OnRoundstart(CALLBACK(GLOBAL_PROC, .proc/minor_announce, "[displayed_rank] [H.nameless ? "" : "[H.real_name] "]on deck!"))
/datum/job/captain/announce(mob/living/carbon/human/H, tried=FALSE)
if(!H)
return
if(!H.client && !tried) //Roundstart mobs don't have clients when announce() gets called
SSticker.OnRoundstart(CALLBACK(src, .proc/announce, H, TRUE)) //So we try again...
return
if(tried && !H.client) //We don't want to endlessly call ourselves when we don't have a client
throw EXCEPTION("[H.nameless ? "Captain" : "Captain [H.real_name]"] ([H.x],[H.y],[H.z]) has no client.")
return
var/displayed_rank = H.client.prefs.alt_titles_preferences[title]
if(!displayed_rank) //Default to Captain
displayed_rank = "Captain"
minor_announce("[displayed_rank] [H.nameless ? "" : "[H.real_name] "]on deck!")
..()
/datum/outfit/job/captain
name = "Captain"