[MISSED MIRROR] Giant Spider action fixes & Action feedback (#17439)

* missed mirror 70848

* SR modular
This commit is contained in:
Tastyfish
2022-11-11 06:42:28 -08:00
committed by GitHub
parent 69a3ed3d7f
commit 69df5a8320
51 changed files with 237 additions and 175 deletions
+2 -13
View File
@@ -123,19 +123,8 @@
return ..()
/datum/action/cooldown/spell/IsAvailable()
return ..() && can_cast_spell(feedback = FALSE)
/datum/action/cooldown/spell/Trigger(trigger_flags, atom/target)
// We implement this can_cast_spell check before the parent call of Trigger()
// to allow people to click unavailable abilities to get a feedback chat message
// about why the ability is unavailable.
// It is otherwise redundant, however, as IsAvailable() checks can_cast_spell as well.
if(!can_cast_spell())
UpdateButtons(TRUE)
return FALSE
return ..()
/datum/action/cooldown/spell/IsAvailable(feedback = FALSE)
return ..() && can_cast_spell(feedback)
/datum/action/cooldown/spell/set_click_ability(mob/on_who)
if(SEND_SIGNAL(on_who, COMSIG_MOB_SPELL_ACTIVATED, src) & SPELL_CANCEL_CAST)
@@ -31,7 +31,7 @@
/datum/action/cooldown/spell/pointed/swap/InterceptClickOn(mob/living/caller, params, atom/click_target)
if(LAZYACCESS(params2list(params), RIGHT_CLICK))
if(!IsAvailable())
if(!IsAvailable(feedback = TRUE))
return FALSE
if(!target)
return FALSE
@@ -38,7 +38,7 @@
invocation_says_area = FALSE
/datum/action/cooldown/spell/teleport/area_teleport/wizard/scroll/IsAvailable()
/datum/action/cooldown/spell/teleport/area_teleport/wizard/scroll/IsAvailable(feedback = FALSE)
return ..() && owner.is_holding(target)
/datum/action/cooldown/spell/teleport/area_teleport/wizard/scroll/before_cast(atom/cast_on)