mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-30 08:29:57 +01:00
Away Mission Events (#12802)
This commit is contained in:
@@ -189,18 +189,25 @@ Works together with spawning an observer, noted above.
|
||||
|
||||
//Teleports the observer away from z-levels they shouldnt be on, if needed.
|
||||
/mob/abstract/observer/proc/teleport_if_needed()
|
||||
//If we dont have a observe restriction we dont need to teleport
|
||||
if(!config.observe_restriction)
|
||||
return
|
||||
|
||||
//If we are not on a restricted level we dont need to get rid of them
|
||||
if(!on_restricted_level())
|
||||
return
|
||||
|
||||
//If we have observe restriction 1 and they are following a living non-animal mob we dont need to do anything.
|
||||
if(config.observe_restriction == 1 && following && isliving(following) && !isliving(following))
|
||||
return
|
||||
|
||||
//In case we have observe restriction 2 (or 1 and they are following something, then teleport them back.)
|
||||
if(following)
|
||||
if(!isliving(following) || isanimal(following)) //If they are following something other than a living non-animal mob, teleport them
|
||||
var/message = "You can not follow \the [following] on this level."
|
||||
stop_following()
|
||||
teleport_to_spawn(message)
|
||||
else
|
||||
return
|
||||
//If they are moving around freely, teleport them
|
||||
teleport_to_spawn()
|
||||
stop_following()
|
||||
teleport_to_spawn("You can not follow \the [following] on this level.")
|
||||
else
|
||||
teleport_to_spawn()
|
||||
|
||||
//And update their sight settings
|
||||
updateghostsight()
|
||||
|
||||
@@ -328,7 +335,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
|
||||
if(ishuman(following))
|
||||
health_scan_mob(following, usr, TRUE, TRUE)
|
||||
else
|
||||
else
|
||||
to_chat(src, SPAN_WARNING("This isn't a scannable target."))
|
||||
|
||||
/mob/abstract/observer/verb/toggle_antagHUD()
|
||||
@@ -976,4 +983,4 @@ mob/abstract/observer/MayRespawn(var/feedback = 0, var/respawn_type = null)
|
||||
/mob/abstract/observer/can_hear_radio(speaker_coverage = list())
|
||||
if(client && (client.prefs.toggles & CHAT_GHOSTRADIO))
|
||||
return TRUE
|
||||
return ..()
|
||||
return ..()
|
||||
|
||||
Reference in New Issue
Block a user