Files
CHOMPStation2/code/game/gamemodes/technomancer/spells/spawner/pulsar.dm
Neerti bb7be9b628 Tweaks instability
Instability should now feel more responsive and less sluggish to go away.  Instead of it being removed at a semi-random and slow rate, it now has a semi-defined half life of about 46 seconds (IE 100 instability will be around 50 in 46 seconds).  The radiate pulse now occurs every Life() tick as well, and by extension the light radius update, so you should be able to see your purple halo adjust faster.

This unfortunately necessitated tweaking to the strength of instability events.  Instability events should happen more often to compensate for it going away faster.  It may need to be tweaked further.

Instability Glow (IE radiating) now radiates the instability decayed in the Life() tick instead of a third of the current instability.  This means people have more time to get out of the purple light before they start glowing themselves.  Two glowing people tend to equalize their instability if adjacent for awhile, while a third person can cause runaway instability, as normal.

Glowing now starts at 10 instability instead of 30.

Technomancer cores show the instability delta in their stat panel.

Message for standing in purple made bigger and purple-er.

Fixes bug with certain spells which waited for the effect to go off before qdeling the hand item.

Fixes leftover Xenobio tests in example map defines.
2017-09-11 11:46:35 -04:00

52 lines
1.4 KiB
Plaintext

/datum/technomancer/spell/pulsar
name = "Pulsar"
desc = "Emits electronic pulses to destroy, disable, or otherwise harm devices and machines. Be sure to not hit yourself with this."
cost = 100
obj_path = /obj/item/weapon/spell/spawner/pulsar
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/spawner/pulsar
name = "pulsar"
desc = "Be sure to not hit yourself!"
icon_state = "radiance"
cast_methods = CAST_RANGED | CAST_THROW
aspect = ASPECT_EMP
spawner_type = /obj/effect/temporary_effect/pulsar
/obj/item/weapon/spell/spawner/pulsar/New()
..()
set_light(3, 2, l_color = "#2ECCFA")
/obj/item/weapon/spell/spawner/pulsar/on_ranged_cast(atom/hit_atom, mob/user)
if(within_range(hit_atom) && pay_energy(4000))
adjust_instability(8)
..()
/obj/item/weapon/spell/spawner/pulsar/on_throw_cast(atom/hit_atom, mob/user)
empulse(hit_atom, 1, 1, 1, 1, log=1)
/obj/effect/temporary_effect/pulsar
name = "pulsar"
desc = "Not a real pulsar, but still emits loads of EMP."
icon = 'icons/effects/effects.dmi'
icon_state = "shield2"
time_to_die = null
invisibility = 0
new_light_range = 4
new_light_power = 5
new_light_color = "#2ECCFA"
var/pulses_remaining = 3
/obj/effect/temporary_effect/pulsar/New()
..()
spawn(0)
pulse_loop()
/obj/effect/temporary_effect/pulsar/proc/pulse_loop()
while(pulses_remaining)
sleep(2 SECONDS)
empulse(src, 1, 1, 2, 2, log = 1)
pulses_remaining--
qdel(src)