Skip to content

Commit

Permalink
Fix interaction of Transform and entrance Abilities (smogon#9163)
Browse files Browse the repository at this point in the history
  • Loading branch information
benstensen committed Dec 13, 2022
1 parent 80dcc74 commit 97708b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sim/pokemon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1776,7 +1776,7 @@ export class Pokemon {
}
this.ability = ability.id;
this.abilityState = {id: ability.id, target: this};
if (ability.id && this.battle.gen > 3) {
if (ability.id && this.battle.gen > 3 && !(oldAbility === ability.id && this.battle.gen > 4)) {
this.battle.singleEvent('Start', ability, this.abilityState, this, source);
}
this.abilityOrder = this.battle.abilityOrder++;
Expand Down
2 changes: 1 addition & 1 deletion test/sim/moves/transform.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ describe('Transform', function () {
assert.statStage(battle.p2.active[0], 'atk', -1);
});

it.skip(`should copy, but not activate the target's Ability if it is the same as the user's pre-Transform`, function () {
it(`should copy, but not activate the target's Ability if it is the same as the user's pre-Transform`, function () {
battle = common.createBattle([[
{species: 'Ditto', ability: 'intimidate', moves: ['transform']},
], [
Expand Down

0 comments on commit 97708b6

Please sign in to comment.