mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-19 20:15:47 +01:00
Refactors occupant to use setter (#54373)
This is to make it easier to attach a signal to the setting of the occupant.
This commit is contained in:
@@ -37,12 +37,13 @@
|
||||
|
||||
/obj/machinery/implantchair/ui_data()
|
||||
var/list/data = list()
|
||||
data["occupied"] = occupant ? 1 : 0
|
||||
var/mob/living/mob_occupant = occupant
|
||||
|
||||
data["occupied"] = mob_occupant ? 1 : 0
|
||||
data["open"] = state_open
|
||||
|
||||
data["occupant"] = list()
|
||||
if(occupant)
|
||||
var/mob/living/mob_occupant = occupant
|
||||
if(mob_occupant)
|
||||
data["occupant"]["name"] = mob_occupant.name
|
||||
data["occupant"]["stat"] = mob_occupant.stat
|
||||
|
||||
@@ -65,7 +66,7 @@
|
||||
open_machine()
|
||||
. = TRUE
|
||||
if("implant")
|
||||
implant(occupant,usr)
|
||||
implant(occupant, usr)
|
||||
. = TRUE
|
||||
|
||||
/obj/machinery/implantchair/proc/implant(mob/living/M,mob/user)
|
||||
|
||||
Reference in New Issue
Block a user