spell ![code/modules/spells/spell.dm 92](git.png)
Vars | |
should_recharge_after_cast | Whether an ability should start cooldown after cast or not. |
---|---|
Procs | |
can_target | can_target: Checks if we are allowed to cast the spell on a target. |
should_remove_click_intercept | Called in try_perform before removing the click interceptor. Useful to override if you have a spell that requires more than 1 click |
try_perform | Will try and perform the spell using the given targets and user. Will spend one charge of the spell |
valid_target | Allows for spell specific target validation. Will be used by the spell_targeting datums |
Var Details
should_recharge_after_cast ![code/modules/spells/spell.dm 144](git.png)
Whether an ability should start cooldown after cast or not.
Proc Details
can_target
can_target: Checks if we are allowed to cast the spell on a target.
Arguments:
- target The atom that is being targeted by the spell.
- user The mob using the spell.
- silent If the checks should not give any feedback messages.
should_remove_click_intercept
Called in try_perform
before removing the click interceptor. Useful to override if you have a spell that requires more than 1 click
try_perform
Will try and perform the spell using the given targets and user. Will spend one charge of the spell
Arguments:
- targets - The targets the spell is being performed on
- user - The caster of the spell
valid_target
Allows for spell specific target validation. Will be used by the spell_targeting datums
Arguments:
- target - Who is being considered
- user - Who is the user of this spell