feat(effect-list): cooldowns for spells that lock out their targets - #2464
Conversation
Five spells stop a character from receiving them again for a while, and nothing in the effect list said so, leaving the caster with no way to know who they can still cast on. Two shapes, so two attributes: group-cooldown is the lockout a group (EVOKE) casting puts on each target -- Bravery (211) and Heroism (215) at 180s, Spell Shield (219) at 360s. The caster's own message names the group, which is how the casting is told apart from a self-cast. target-cooldown is the lockout a spell puts on the one character it lands on -- Wall of Force (140) at 270s, Celerity (506) at 240s. It belongs to that character whoever cast it, so it pairs with a target-start message: the third-person line that names them, with the name captured as (?<noun>...). Lengths are from the spell pages on the wiki. Verified in game against Wall of Force: casting it on a character reads 268.98 seconds left a moment later, and a misfire leaves the existing cooldown running rather than restarting it, since the cooldown follows the effect message and not the cast command. Requires the Lich-side support in elanthia-online/lich-5. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
would it be better served to do: <spell availability='all' name='Wall of Force' number='140' type='defense'>
<duration cast-type='self' span='refreshable'>1.5</duration>
<duration cast-type='target' span='refreshable'>1</duration>
<cost type='mana'>40</cost>
<bonus type='bolt-ds'>100</bonus>
<bonus type='physical-ds'>100</bonus>
<cooldown type='target'>270</cooldown>
<cooldown type='group'>270</cooldown>
<message type='start'>A wall of force surrounds you\.</message>
<message type='end'>The wall of force disappears from around you\.</message>
<message type='target-start'>A wall of force surrounds (?<noun>[A-Z][a-z]+)\.</message>
</spell> |
Move the group and target cooldowns off the <spell> tag's attributes and onto <cooldown type='group'> and <cooldown type='target'> children, per review feedback on elanthia-online#2464. Matches how duration, cost and bonus are already carried, and takes a further cooldown kind without adding an attribute per kind. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Agreed, that reads better and matches how Parsing side updated to match in elanthia-online/lich-5#1597, which now reads them with a Worth landing the lich-5 side first or close to this one. Each is harmless alone, but if this merges first, anyone pulling a fresh effect-list before the parsing change ships would see these cooldowns read as nil. |
mrhoribu
left a comment
There was a problem hiding this comment.
would it be better served to do:
<spell availability='all' name='Wall of Force' number='140' type='defense'>
<duration cast-type='self' span='refreshable'>1.5</duration>
<duration cast-type='target' span='refreshable'>1</duration>
<cost type='mana'>40</cost>
<bonus type='bolt-ds'>100</bonus>
<bonus type='physical-ds'>100</bonus>
<cooldown type='target'>270</cooldown>
<cooldown type='group'>270</cooldown>
<message type='start'>A wall of force surrounds you\.</message>
<message type='end'>The wall of force disappears from around you\.</message>
<message type='target-start'>A wall of force surrounds (?<noun>[A-Z][a-z]+)\.</message>
</spell>
Summary
Five spells stop a character from receiving them again for a while, and nothing in the effect list said so. Companion to elanthia-online/lich-5#1597, which reads these and tracks the cooldowns per character; without that PR these attributes are inert, and without this one its code has no data to act on. Either can merge first.
Two shapes, so two attributes.
group-cooldown-- the lockout a group (EVOKE) casting puts on each target. Bravery (211) and Heroism (215) at 180s, Spell Shield (219) at 360s. The caster's own start message names the group, which is how Lich tells a group casting apart from a self-cast.target-cooldown-- the lockout a spell puts on the one character it lands on. Wall of Force (140) at 270s, Celerity (506) at 240s. It belongs to that character whoever cast it, so it pairs with atarget-startmessage: the third-person line naming them, with the name captured as(?<noun>...).Lengths are from the spell pages on the wiki. Existing attributes and messages are untouched, so a Lich that does not know these names ignores them.
Deliberately left out: Rapid Fire (515), whose recovery starts when the effect ends and scales with the target's Elemental Mana Control rather than being a constant; Barkskin (605), whose cooldown starts when the spell absorbs a hit, an event with no fixed relationship to the casting; and Invisibility (916) and Resist Nature (620), whose group versions have no per-target lockout.
Test plan
mode: :generic, skip: :skip_none)target-startpatterns match the real game lines and capture the name, and do not match the second-person lines, the group-casting line, or a pet's line🤖 Generated with Claude Code