Mechanics Endless Battle Clause violations in Pure Hackmons

Bread Sandwich

UMPL Champion
What type of bug are you reporting? Unsure

What is the bug?
Endless battle clause is not triggered in gen 9 when a pokemon has two or more copies of the same move and isn't able to struggle after losing all pp.

Are you able to replicate it? If so, how?
Bring a pokemon with 2 or more copies of the same move to battle, the opponent brings in a shadow tag pokemon with leppa berry and recycle. Once the pokemon with 2 copies of the same attack runs out of pp it will be unable to attack or struggle and will be forced in to an endless loop
https://replay.pokemonshowdown.com/gen9purehackmons-2383304976-0wppva7tjvqgfnltfb5241com9qkqo9pw?p2
https://replay.pokemonshowdown.com/gen9purehackmons-2376497428?p2
 
This isn't yet coded as a case for the Endless Battle Clause, but my proposal to add it was met with no objections, so I'd consider it safe to add.

If anyone wants to beat me to the punch: a Pokemon should be marked as stale if it gets the "There was no PP left for the move!" message from a double move, and the staleness should be considered external if the Pokemon is transformed into an opponent. Please add a unit test for the specific strat that's being exploited in the battles above.
 
Back
Top