mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
Fixed Issue 897
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4654 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -144,7 +144,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
|||||||
if(overlay)
|
if(overlay)
|
||||||
for(var/atom/target in targets)
|
for(var/atom/target in targets)
|
||||||
var/location
|
var/location
|
||||||
if(istype(target,/mob))
|
if(istype(target,/mob/living))
|
||||||
location = target.loc
|
location = target.loc
|
||||||
else if(istype(target,/turf))
|
else if(istype(target,/turf))
|
||||||
location = target
|
location = target
|
||||||
@@ -159,11 +159,11 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
|||||||
/obj/effect/proc_holder/spell/proc/after_cast(list/targets)
|
/obj/effect/proc_holder/spell/proc/after_cast(list/targets)
|
||||||
for(var/atom/target in targets)
|
for(var/atom/target in targets)
|
||||||
var/location
|
var/location
|
||||||
if(istype(target,/mob))
|
if(istype(target,/mob/living))
|
||||||
location = target.loc
|
location = target.loc
|
||||||
else if(istype(target,/turf))
|
else if(istype(target,/turf))
|
||||||
location = target
|
location = target
|
||||||
if(istype(target,/mob) && message)
|
if(istype(target,/mob/living) && message)
|
||||||
target << text("[message]")
|
target << text("[message]")
|
||||||
if(sparks_spread)
|
if(sparks_spread)
|
||||||
var/datum/effect/effect/system/spark_spread/sparks = new /datum/effect/effect/system/spark_spread()
|
var/datum/effect/effect/system/spark_spread/sparks = new /datum/effect/effect/system/spark_spread()
|
||||||
@@ -235,9 +235,13 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
|||||||
if(range < 0)
|
if(range < 0)
|
||||||
targets += user
|
targets += user
|
||||||
else
|
else
|
||||||
var/possible_targets = view_or_range(range, user, selection_type)
|
var/possible_targets = list()
|
||||||
if(!include_user && user in possible_targets)
|
|
||||||
possible_targets -= user
|
for(var/mob/living/M in view_or_range(range, user, selection_type))
|
||||||
|
if(!include_user && user == M)
|
||||||
|
continue
|
||||||
|
possible_targets += M
|
||||||
|
|
||||||
targets += input("Choose the target for the spell.", "Targeting") as mob in possible_targets
|
targets += input("Choose the target for the spell.", "Targeting") as mob in possible_targets
|
||||||
else
|
else
|
||||||
var/list/possible_targets = list()
|
var/list/possible_targets = list()
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
return thearea
|
return thearea
|
||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/area_teleport/cast(list/targets,area/thearea)
|
/obj/effect/proc_holder/spell/targeted/area_teleport/cast(list/targets,area/thearea)
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
var/list/L = list()
|
var/list/L = list()
|
||||||
for(var/turf/T in get_area_turfs(thearea.type))
|
for(var/turf/T in get_area_turfs(thearea.type))
|
||||||
if(!T.density)
|
if(!T.density)
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/emplosion/cast(list/targets)
|
/obj/effect/proc_holder/spell/targeted/emplosion/cast(list/targets)
|
||||||
|
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
empulse(target.loc, emp_heavy, emp_light)
|
empulse(target.loc, emp_heavy, emp_light)
|
||||||
|
|
||||||
return
|
return
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
var/jaunt_duration = 50 //in deciseconds
|
var/jaunt_duration = 50 //in deciseconds
|
||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/cast(list/targets) //magnets, so mostly hardcoded
|
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/cast(list/targets) //magnets, so mostly hardcoded
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
spawn(0)
|
spawn(0)
|
||||||
var/mobloc = get_turf(target.loc)
|
var/mobloc = get_turf(target.loc)
|
||||||
var/obj/effect/dummy/spell_jaunt/holder = new /obj/effect/dummy/spell_jaunt( mobloc )
|
var/obj/effect/dummy/spell_jaunt/holder = new /obj/effect/dummy/spell_jaunt( mobloc )
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/explosion/cast(list/targets)
|
/obj/effect/proc_holder/spell/targeted/explosion/cast(list/targets)
|
||||||
|
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
explosion(target.loc,ex_severe,ex_heavy,ex_light,ex_flash)
|
explosion(target.loc,ex_severe,ex_heavy,ex_light,ex_flash)
|
||||||
|
|
||||||
return
|
return
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/genetic/cast(list/targets)
|
/obj/effect/proc_holder/spell/targeted/genetic/cast(list/targets)
|
||||||
|
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
for(var/x in mutations)
|
for(var/x in mutations)
|
||||||
target.mutations.Add(x)
|
target.mutations.Add(x)
|
||||||
target.disabilities |= disabilities
|
target.disabilities |= disabilities
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ Also, you never added distance checking after target is selected. I've went ahea
|
|||||||
user << "Too many minds! You're not a hive damnit!"//Whaa...aat?
|
user << "Too many minds! You're not a hive damnit!"//Whaa...aat?
|
||||||
return
|
return
|
||||||
|
|
||||||
var/mob/target = targets[1]
|
var/mob/living/target = targets[1]
|
||||||
|
|
||||||
if(!(target in oview(range)))//If they are not in overview after selection. Do note that !() is necessary for in to work because ! takes precedence over it.
|
if(!(target in oview(range)))//If they are not in overview after selection. Do note that !() is necessary for in to work because ! takes precedence over it.
|
||||||
user << "They are too far away!"
|
user << "They are too far away!"
|
||||||
@@ -53,7 +53,7 @@ Also, you never added distance checking after target is selected. I've went ahea
|
|||||||
user << "Their mind is resisting your spell."
|
user << "Their mind is resisting your spell."
|
||||||
return
|
return
|
||||||
|
|
||||||
var/mob/victim = target//The target of the spell whos body will be transferred to.
|
var/mob/living/victim = target//The target of the spell whos body will be transferred to.
|
||||||
var/mob/caster = user//The wizard/whomever doing the body transferring.
|
var/mob/caster = user//The wizard/whomever doing the body transferring.
|
||||||
|
|
||||||
//SPELL LOSS BEGIN
|
//SPELL LOSS BEGIN
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/projectile/cast(list/targets, mob/user = usr)
|
/obj/effect/proc_holder/spell/targeted/projectile/cast(list/targets, mob/user = usr)
|
||||||
|
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
spawn(0)
|
spawn(0)
|
||||||
var/obj/effect/proc_holder/spell/targeted/projectile
|
var/obj/effect/proc_holder/spell/targeted/projectile
|
||||||
if(istext(proj_type))
|
if(istext(proj_type))
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
..()
|
..()
|
||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/trigger/cast(list/targets)
|
/obj/effect/proc_holder/spell/targeted/trigger/cast(list/targets)
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
for(var/obj/effect/proc_holder/spell/spell in contents)
|
for(var/obj/effect/proc_holder/spell/spell in contents)
|
||||||
spell.perform(list(target),0)
|
spell.perform(list(target),0)
|
||||||
for(var/obj/effect/proc_holder/spell/spell in linked_spells)
|
for(var/obj/effect/proc_holder/spell/spell in linked_spells)
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
var/include_dense = 0 //whether it includes dense tiles in possible teleport locations
|
var/include_dense = 0 //whether it includes dense tiles in possible teleport locations
|
||||||
|
|
||||||
/obj/effect/proc_holder/spell/targeted/turf_teleport/cast(list/targets)
|
/obj/effect/proc_holder/spell/targeted/turf_teleport/cast(list/targets)
|
||||||
for(var/mob/target in targets)
|
for(var/mob/living/target in targets)
|
||||||
var/list/turfs = new/list()
|
var/list/turfs = new/list()
|
||||||
for(var/turf/T in range(target,outer_tele_radius))
|
for(var/turf/T in range(target,outer_tele_radius))
|
||||||
if(T in range(target,inner_tele_radius)) continue
|
if(T in range(target,inner_tele_radius)) continue
|
||||||
|
|||||||
Reference in New Issue
Block a user