makes it plausible to hear most sounds while inside of a VR sleeper (#8034)

This commit is contained in:
deathride58
2019-02-22 09:09:54 -05:00
committed by kevinz000
parent 1f3cbd9ff4
commit 48a0157608
6 changed files with 27 additions and 5 deletions
+1
View File
@@ -35,6 +35,7 @@
/mob/living/carbon/human/virtual_reality/proc/revert_to_reality(deathchecks = TRUE)
if(real_mind && mind)
real_mind.current.audiovisual_redirect = null
real_mind.current.ckey = ckey
real_mind.current.stop_sound_channel(CHANNEL_HEARTBEAT)
if(deathchecks && vr_sleeper)
+2
View File
@@ -93,6 +93,7 @@
to_chat(occupant, "<span class='warning'>Transferring to virtual reality...</span>")
if(vr_human && vr_human.stat == CONSCIOUS && !vr_human.real_mind)
SStgui.close_user_uis(occupant, src)
human_occupant.audiovisual_redirect = vr_human
vr_human.real_mind = human_occupant.mind
vr_human.ckey = human_occupant.ckey
to_chat(vr_human, "<span class='notice'>Transfer successful! You are now playing as [vr_human] in VR!</span>")
@@ -171,6 +172,7 @@
O.equip(vr_human)
if(transfer && H.mind)
SStgui.close_user_uis(H, src)
H.audiovisual_redirect = vr_human
vr_human.ckey = H.ckey
/obj/machinery/vr_sleeper/proc/cleanup_vr_human()