Fixes #19331 Teleportation spell no longer grants free smoke when cancelled (#19384)

* no more smoke/shouting when not selecting a tp location

* Apply suggestions from code review

Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>

* redundant else

* resolving conflict

* removed silence

Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>
This commit is contained in:
Henri215
2022-10-21 20:21:45 +02:00
committed by GitHub
co-authored by S34N
parent b56dc871a6
commit f00232d5d6
2 changed files with 8 additions and 13 deletions
+8 -11
View File
@@ -19,6 +19,7 @@
A = pick(SSmapping.teleportlocs)
if(!A)
smoke_type = SMOKE_NONE
return
var/area/thearea = SSmapping.teleportlocs[A]
@@ -34,6 +35,7 @@
revert_cast(user)
return
smoke_type = SMOKE_HARMLESS
playsound(get_turf(user), sound1, 50,1)
for(var/mob/living/target in targets)
var/list/L = list()
@@ -78,15 +80,10 @@
/obj/effect/proc_holder/spell/area_teleport/invocation(mob/user)
if(!invocation_area || !selected_area)
..()
else
switch(invocation_type)
if("shout")
user.say("[invocation] [uppertext(selected_area.name)]")
if(user.gender==MALE)
playsound(user.loc, pick('sound/misc/null.ogg','sound/misc/null.ogg'), 100, 1)
else
playsound(user.loc, pick('sound/misc/null.ogg','sound/misc/null.ogg'), 100, 1)
if("whisper")
user.whisper("[invocation] [uppertext(selected_area.name)]")
return
switch(invocation_type)
if("shout")
user.say("[invocation] [uppertext(selected_area.name)]")
if("whisper")
user.whisper("[invocation] [uppertext(selected_area.name)]")
-2
View File
@@ -181,9 +181,7 @@
invocation_type = "shout"
cooldown_min = 200 //100 deciseconds reduction per rank
smoke_type = SMOKE_HARMLESS
smoke_amt = 5
action_icon_state = "spell_teleport"
sound1 = 'sound/magic/teleport_diss.ogg'