mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-19 22:51:40 +00:00
Adds ability to sort the spells section of the catalog into categories. The categories available are 'All', 'Offensive', 'Defensive', 'Utility', and 'Support'. Removes preset section on catalog as it was unused. Projectile spells now have a sound when fired. Haste lasts five seconds instead of three. Repel Missiles lasts for five minutes instead of two. All healing spells work five times as fast, healing in five seconds instead of twenty five seconds. The amount of instability and healing done has been multiplied to remain consistent. Passwall can now be used on more than just walls, if there's something dense on the same tile. Force Missile is now 25% cheaper to cast, and has a cooldown of .5 seconds instead of one second, and does 5 more damage. Beam's damage is increased by 10, and energy cost decreased by 25%. Lightning's warm-up time is now one second instead of two. Overload now costs 10% of total energy instead of 15%, and damage scaled with 4% of their current energy reserves, and 5% with the Scepter, instead of 3%/4%. Additionally, instability per shot is lowered to 12 from 15. Track now costs 25 points instead of 30 in the catalog, because roundness. Fire Aura should look more impressive without a Scepter. Fixes bug where shooting Lightning made you motionless for twenty seconds.
71 lines
2.2 KiB
Plaintext
71 lines
2.2 KiB
Plaintext
/datum/technomancer/spell/blink
|
|
name = "Blink"
|
|
desc = "Force the target to teleport a short distance away. This target could be anything from something lying on the ground, to someone trying to \
|
|
fight you, or even yourself. Using this on someone next to you makes their potential distance after teleportation greater."
|
|
enhancement_desc = "Blink distance is increased greatly."
|
|
cost = 100
|
|
obj_path = /obj/item/weapon/spell/blink
|
|
category = UTILITY_SPELLS
|
|
|
|
/obj/item/weapon/spell/blink
|
|
name = "blink"
|
|
desc = "Teleports you or someone else a short distance away."
|
|
icon_state = "blink"
|
|
cast_methods = CAST_RANGED | CAST_MELEE | CAST_USE
|
|
aspect = ASPECT_TELE
|
|
|
|
/proc/safe_blink(atom/movable/AM, var/range = 3)
|
|
if(AM.anchored || !AM.loc)
|
|
return
|
|
var/turf/starting = get_turf(AM)
|
|
var/list/targets = list()
|
|
|
|
valid_turfs:
|
|
for(var/turf/simulated/T in range(AM, range))
|
|
if(T.density || istype(T, /turf/simulated/mineral)) //Don't blink to vacuum or a wall
|
|
continue
|
|
for(var/atom/movable/stuff in T.contents)
|
|
if(stuff.density)
|
|
continue valid_turfs
|
|
targets.Add(T)
|
|
|
|
if(!targets.len)
|
|
return
|
|
var/turf/simulated/destination = null
|
|
|
|
destination = pick(targets)
|
|
|
|
if(destination)
|
|
if(ismob(AM))
|
|
var/mob/living/L = AM
|
|
if(L.buckled)
|
|
L.buckled.unbuckle_mob()
|
|
AM.forceMove(destination)
|
|
AM.visible_message("<span class='notice'>\The [AM] vanishes!</span>")
|
|
AM << "<span class='notice'>You suddenly appear somewhere else!</span>"
|
|
new /obj/effect/effect/sparks(destination)
|
|
new /obj/effect/effect/sparks(starting)
|
|
return
|
|
|
|
/obj/item/weapon/spell/blink/on_ranged_cast(atom/hit_atom, mob/user)
|
|
if(istype(hit_atom, /atom/movable))
|
|
var/atom/movable/AM = hit_atom
|
|
if(check_for_scepter())
|
|
safe_blink(user, 6)
|
|
else
|
|
safe_blink(AM, 3)
|
|
|
|
/obj/item/weapon/spell/blink/on_use_cast(mob/user)
|
|
if(check_for_scepter())
|
|
safe_blink(user, 10)
|
|
else
|
|
safe_blink(user, 6)
|
|
|
|
/obj/item/weapon/spell/blink/on_melee_cast(atom/hit_atom, mob/living/user, def_zone)
|
|
if(istype(hit_atom, /atom/movable))
|
|
var/atom/movable/AM = hit_atom
|
|
visible_message("<span class='danger'>\The [user] reaches out towards \the [AM] with a glowing hand.</span>")
|
|
if(check_for_scepter())
|
|
safe_blink(user, 10)
|
|
else
|
|
safe_blink(AM, 6) |