From 2d62544496ebc8dafdb92c4d7e15e9be7edcef40 Mon Sep 17 00:00:00 2001 From: Yoshax Date: Wed, 31 Aug 2016 01:58:50 +0100 Subject: [PATCH] Projectile flash rounds will now do the same as a flash when hitting a target --- code/modules/projectiles/projectile/energy.dm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/code/modules/projectiles/projectile/energy.dm b/code/modules/projectiles/projectile/energy.dm index 80112690b3..9a9fa74292 100644 --- a/code/modules/projectiles/projectile/energy.dm +++ b/code/modules/projectiles/projectile/energy.dm @@ -4,6 +4,7 @@ damage = 0 damage_type = BURN check_armour = "energy" + var/flash_strength = 10 //releases a burst of light on impact or after travelling a distance @@ -24,6 +25,15 @@ for (var/mob/living/carbon/M in viewers(T, flash_range)) if(M.eyecheck() < 1) M.flash_eyes() + if(ishuman(M)) + var/mob/living/carbon/human/H = M + flash_strength *= H.species.flash_mod + + if(flash_strength > 0) + H.confused = max(H.confused, flash_strength + 5) + H.eye_blind = max(H.eye_blind, flash_strength) + H.eye_blurry = max(H.eye_blurry, flash_strength + 5) + //snap pop playsound(src, 'sound/effects/snap.ogg', 50, 1) @@ -35,11 +45,13 @@ new /obj/effect/decal/cleanable/ash(src.loc) //always use src.loc so that ash doesn't end up inside windows new /obj/effect/effect/smoke/illumination(T, 5, brightness, brightness, light_colour) + //blinds people like the flash round, but can also be used for temporary illumination /obj/item/projectile/energy/flash/flare damage = 10 flash_range = 1 brightness = 15 + flash_strength = 20 /obj/item/projectile/energy/flash/flare/on_impact(var/atom/A) light_colour = pick("#e58775", "#ffffff", "#90ff90", "#a09030")