mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-10 17:52:36 +00:00
Base implementation of /datum/persistent_client (#89449)
Converts `/datum/player_details` into `/datum/persistent_client`. Persistent Clients persist across connections. The only time a mob's persistent client will change is if the ckey it's bound to logs into a different mob, or the mob is deleted (duh). Also adds PossessByPlayer() so that transfering mob control is cleaner and makes more immediate sense if you don't know byond-fu. Clients are an abstract representation of a connection that can be dropped at almost any moment so putting things that should be stable to access at any time onto an undying object is ideal. This allows for future expansions like abstracting away client.screen and managing everything cleanly.
This commit is contained in:
@@ -378,7 +378,7 @@
|
||||
if(chosen_one)
|
||||
to_chat(target, span_boldnotice("You have been noticed by a ghost and it has possessed you!"))
|
||||
var/mob/dead/observer/ghosted_target = target.ghostize(FALSE)
|
||||
target.key = chosen_one.key
|
||||
target.PossessByPlayer(chosen_one.key)
|
||||
trauma.add_friend(ghosted_target)
|
||||
else
|
||||
to_chat(target, span_notice("Your mind has managed to go unnoticed in the spirit world."))
|
||||
|
||||
Reference in New Issue
Block a user