mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 21:18:37 +01:00
[MIRROR] Fixes an issue with COMSIG_MOB_ABILITY_STARTED for spells [MDB IGNORE] (#24137)
* Fixes an issue with COMSIG_MOB_ABILITY_STARTED for spells (#78775) ## About The Pull Request The signal `COMSIG_MOB_ABILITY_STARTED` is used by both cooldown actions and spells, which are a subtype of cooldown actions. However, cooldown actions pass two values, `src` and the action's target. Spells only passed `src`, even though its the exact same signal. This caused issues with the ability telegraph component, as it has to interrupt the casting of spells and actions to add a delay, and most if not all spells won't work without the target being passed with the signal. Closes #78715. ## Why It's Good For The Game It caused bugs and is just bad design in general. ## Changelog 🆑 fix: Ice whelps can now use spells given to them by admins, and people who have polymorphed into ice whelps can now polymorph back to normal. /🆑 * Fixes an issue with COMSIG_MOB_ABILITY_STARTED for spells --------- Co-authored-by: GPeckman <21979502+GPeckman@users.noreply.github.com>
This commit is contained in:
@@ -140,7 +140,7 @@
|
||||
|
||||
// Where the cast chain starts
|
||||
/datum/action/cooldown/spell/PreActivate(atom/target)
|
||||
if(SEND_SIGNAL(owner, COMSIG_MOB_ABILITY_STARTED, src) & COMPONENT_BLOCK_ABILITY_START)
|
||||
if(SEND_SIGNAL(owner, COMSIG_MOB_ABILITY_STARTED, src, target) & COMPONENT_BLOCK_ABILITY_START)
|
||||
return FALSE
|
||||
if(target == owner)
|
||||
target = get_caster_from_target(target)
|
||||
|
||||
Reference in New Issue
Block a user