mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-20 11:31:12 +01:00
Refactored the projectile code, mostly in line with TG's now. Refactored various procs that are used or depends on it. Projectiles can now ricochet if enabled to. Damage falloffs with distance. Homing projectiles can now have accuracy falloff with distance. Projectiles have a maximum range. Muzzle flash is configurable per projectile. Impact effect of the projectile is configurable per projectile. Accuracy decreases with distance. Projectiles work with signals and emits them, for easy hooking up from other parts of the code. Meatshielding is now less effective . Impact sound is now configurable per projectile. High risk.
48 lines
1.4 KiB
Plaintext
48 lines
1.4 KiB
Plaintext
/datum/technomancer/spell/lightning
|
|
name = "Lightning Strike"
|
|
desc = "This uses a hidden electrolaser, which creates a laser beam to ionize the enviroment, allowing for ideal conditions \
|
|
for a directed lightning strike to occur. The lightning is very strong, however it requires a few seconds to prepare a \
|
|
strike. Lightning functions cannot miss due to distance."
|
|
cost = 150
|
|
ability_icon_state = "tech_chain_lightning"
|
|
obj_path = /obj/item/spell/projectile/lightning
|
|
category = OFFENSIVE_SPELLS
|
|
|
|
/obj/item/spell/projectile/lightning
|
|
name = "lightning strike"
|
|
icon_state = "lightning_strike"
|
|
desc = "Now you can feel like Zeus."
|
|
cast_methods = CAST_RANGED
|
|
aspect = ASPECT_SHOCK
|
|
spell_projectile = /obj/projectile/beam/lightning
|
|
energy_cost_per_shot = 2500
|
|
instability_per_shot = 10
|
|
cooldown = 20
|
|
pre_shot_delay = 10
|
|
fire_sound = 'sound/effects/psi/thunderstrike.ogg'
|
|
|
|
/obj/projectile/beam/lightning
|
|
name = "lightning"
|
|
icon_state = "lightning"
|
|
damage = 25
|
|
armor_penetration = 25
|
|
damage_type = DAMAGE_BURN
|
|
|
|
muzzle_type = /obj/effect/projectile/muzzle/tesla
|
|
tracer_type = /obj/effect/projectile/tracer/tesla
|
|
impact_type = /obj/effect/projectile/impact/tesla
|
|
|
|
var/power = 6000
|
|
|
|
/obj/projectile/beam/lightning/small
|
|
name = "shock"
|
|
damage = 15
|
|
armor_penetration = 15
|
|
|
|
power = 1000
|
|
|
|
|
|
/obj/projectile/beam/lightning/on_hit(atom/target, blocked, def_zone)
|
|
. = ..()
|
|
tesla_zap(target, 3, power)
|