mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-16 01:23:41 +01:00
Merge pull request #13623 from trololiver112/Vision-fix
Fixes Shadowling darksight not giving night vision when toggled
This commit is contained in:
@@ -39,10 +39,10 @@
|
||||
/datum/action/innate/shadow/darkvision/Activate()
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(!H.vision_type)
|
||||
H.vision_type = new /datum/vision_override/nightvision
|
||||
H.set_sight(/datum/vision_override/nightvision)
|
||||
to_chat(H, "<span class='notice'>You adjust your vision to pierce the darkness.</span>")
|
||||
else
|
||||
H.vision_type = null
|
||||
H.set_sight(null)
|
||||
to_chat(H, "<span class='notice'>You adjust your vision to recognize the shadows.</span>")
|
||||
|
||||
/datum/species/shadow/on_species_gain(mob/living/carbon/human/H)
|
||||
|
||||
@@ -1357,6 +1357,12 @@ GLOBAL_LIST_INIT(slot_equipment_priority, list( \
|
||||
SEND_SIGNAL(src, COMSIG_MOB_UPDATE_SIGHT)
|
||||
sync_lighting_plane_alpha()
|
||||
|
||||
/mob/proc/set_sight(datum/vision_override/O)
|
||||
QDEL_NULL(vision_type)
|
||||
if(O) //in case of null
|
||||
vision_type = new O
|
||||
update_sight()
|
||||
|
||||
/mob/proc/sync_lighting_plane_alpha()
|
||||
if(hud_used)
|
||||
var/obj/screen/plane_master/lighting/L = hud_used.plane_masters["[LIGHTING_PLANE]"]
|
||||
|
||||
@@ -327,7 +327,7 @@
|
||||
user.visible_message("[user] shines light onto the tumor in [target]'s [E]!", "<span class='notice'>You cleanse the contamination from [target]'s brain!</span>")
|
||||
if(target.vision_type) //Turns off their darksight if it's still active.
|
||||
to_chat(target, "<span class='boldannounce'>Your eyes are suddenly wrought with immense pain as your darksight is forcibly dismissed!</span>")
|
||||
target.vision_type = null
|
||||
target.set_sight(null)
|
||||
SSticker.mode.remove_thrall(target.mind, 0)
|
||||
target.visible_message("<span class='warning'>A strange black mass falls from [target]'s [E]!</span>")
|
||||
var/obj/item/organ/thing = new /obj/item/organ/internal/shadowtumor(get_turf(target))
|
||||
|
||||
Reference in New Issue
Block a user