Fix Skill Swap messages
Some checks failed
Node.js CI / build (18.x) (push) Has been cancelled

This commit is contained in:
Karthik99999 2026-03-07 02:35:15 -05:00
parent 59709dba6c
commit cb47056b1b

View File

@ -1312,9 +1312,9 @@ export class Battle {
if (!sourceCanBeSet) return sourceCanBeSet;
if (this.gen <= 4 || source.isAlly(target)) {
this.add('-activate', source, 'Skill Swap');
this.add('-activate', source, 'Skill Swap', '', '', `[of] ${target}`);
} else {
this.add('-activate', source, 'Skill Swap', target, `[ability] ${targetAbility.name}`, `[ability2] ${sourceAbility.name}`);
this.add('-activate', source, 'Skill Swap', targetAbility.name, sourceAbility.name, `[of] ${target}`);
}
this.singleEvent('End', sourceAbility, source.abilityState, source);
this.singleEvent('End', targetAbility, target.abilityState, target);