Flesh to Stone Fixes (#10134)

This commit is contained in:
Geeves
2020-10-01 18:16:00 +02:00
committed by GitHub
parent 436e1f4670
commit deef6a162e
4 changed files with 18 additions and 3 deletions
@@ -5,6 +5,7 @@
school = "transmutation"
charge_max = 200
spell_flags = NEEDSCLOTHES | SELECTABLE
blacklisted_mob_types = list(/mob/living/heavy_vehicle)
range = 5
max_targets = 1
invocation = "STAUN EI"
@@ -29,6 +29,7 @@ Targeted spells have two useful flags: INCLUDEUSER and SELECTABLE. These are exp
var/amt_eye_blurry = 0
var/list/compatible_mobs = list()
var/list/blacklisted_mob_types
/spell/targeted/choose_targets(mob/user = usr)
@@ -55,6 +56,8 @@ Targeted spells have two useful flags: INCLUDEUSER and SELECTABLE. These are exp
for(var/mob/living/M in starting_targets)
if(!(spell_flags & INCLUDEUSER) && M == user)
continue
if(length(blacklisted_mob_types) && is_type_in_list(M, blacklisted_mob_types))
continue
if(length(compatible_mobs) && !is_type_in_list(M, compatible_mobs))
continue
possible_targets += M
@@ -81,6 +84,8 @@ Targeted spells have two useful flags: INCLUDEUSER and SELECTABLE. These are exp
for(var/mob/living/target in starting_targets)
if(!(spell_flags & INCLUDEUSER) && target == user)
continue
if(length(blacklisted_mob_types) && is_type_in_list(target, blacklisted_mob_types))
continue
if(length(compatible_mobs) && !is_type_in_list(target, compatible_mobs))
continue
possible_targets += target