Morgue Updating [Hooks P4]

This commit is contained in:
AffectedArc07
2019-05-06 10:08:28 +01:00
parent b403cd3c58
commit 19d8efef68
5 changed files with 5 additions and 30 deletions
+1 -15
View File
@@ -15,18 +15,4 @@
* Called in supervisor.dm when a captain spawns
* Parameters: var/mob/living/carbon/human/captain
*/
/hook/captain_spawned
/**
* Mob login hook.
* Called in login.dm when a player logs in to a mob.
* Parameters: var/client/client, var/mob/mob
*/
/hook/mob_login
/**
* Mob logout hook.
* Called in logout.dm when a player logs out of a mob.
* Parameters: var/client/client, var/mob/mob
*/
/hook/mob_logout
/hook/captain_spawned
+1 -11
View File
@@ -484,14 +484,4 @@
if(istype(C)) //We found our corpse, is it inside a morgue?
morgue = get(C.loc, /obj/structure/morgue)
if(morgue)
morgue.update()
/hook/mob_login/proc/update_morgue(var/client/client, var/mob/mob)
//Update morgues on login
mob.update_morgue()
return 1
/hook/mob_logout/proc/update_morgue(var/client/client, var/mob/mob)
//Update morgues on logout
mob.update_morgue()
return 1
morgue.update()
+1 -2
View File
@@ -70,5 +70,4 @@
AA.display_to(list(src))
update_client_colour(0)
callHook("mob_login", list("client" = client, "mob" = src))
update_morgue()
+1 -1
View File
@@ -16,5 +16,5 @@
send2irc(config.admin_notify_irc, "[key_name(src)] logged out - No active admins, [admincounter[2]] non-admin staff, [admincounter[3]] inactive staff.")
..()
callHook("mob_logout", list("client" = client, "mob" = src))
update_morgue()
return 1
+1 -1
View File
@@ -27,7 +27,7 @@
loc = pick(watch_locations)
*/
callHook("mob_login", list("client" = client, "mob" = src))
update_morgue() // Why is this called for new players that dont even have a morgue
new_player_panel()