pagefaultgames / pokerogue

A browser based Pokémon fangame heavily inspired by the roguelite genre.
https://pokerogue.net
GNU Affero General Public License v3.0
4.42k stars 1.78k forks source link

[Bug] Gigaton Hammer and Blood Moon can be Selected and Fail when Chosen Successively. #4289

Open Snailman11 opened 3 weeks ago

Snailman11 commented 3 weeks ago

Describe the bug

-Gigaton Hammer and Blood Moon can be chosen on the cooldown turn. Instead of not being able to be chosen, (selecting them should send them back to the player menu) the moves fail.

-When encored into Gigaton Hammer or Blood Moon, the move fails on the second turn. After the second turn, the user is able to execute Gigaton/Blood instead of being forced to struggle.

-Calling Gigaton or Blood Moon with Sleep talk does not let the user use the move normally the turn after it was summoned.

Link to Discord's Bug Report (blood moon and gigaton hammer can be selected when they shouldnt) https://discord.com/channels/1125469663833370665/1285167628373069854

Session export file

No response

User data export file

No response

Expected behavior

Gigaton Hammer inflicts damage. The user cannot select Gigaton Hammer in succession unless the move failed. If the player attempts to use Gigaton Hammer twice in a row, they will be prevented from doing so, and will be allowed to select another move. Once another move is used, Gigaton Hammer can be used again.

If the user cannot select another move (due to Choice items or having no other usable moves), it will use Struggle every other turn.

Instruct and Sleep Talk allow Gigaton Hammer to be used twice in a row. Encore allows Gigaton Hammer to be used twice in a row, but on subsequent turns of the Encore the user will be forced to Struggle.

https://youtu.be/SgLDCml8UZY?feature=shared

When Called, Gigaton Hammer and Blood Moon's counter should be separate from normal usage of the move.

https://replay.pokemonshowdown.com/gen9customgame-2203228437-sw7lpgwynfqjgsyjncpemd36pot0r3lpw

Screenshots / Videos

No message/return to menu if Gigaton is selected successively

https://github.com/user-attachments/assets/25d69758-25f3-485e-8fcb-5bf449a1b37a

Encore does not allow a second usage of the move

https://github.com/user-attachments/assets/340eab93-d512-4262-8fe4-e8139d3024f9

Sleep talk does let it be used repeatedly (correct), but prevents the user from using it normally after waking up.

https://github.com/user-attachments/assets/180dbbaa-5d5e-4d7e-a4c7-dc58f5058b19

What OS did you observe the bug on?

Other

If other please specify

gameplay

Which browser do you use?

Other

If other please specify

gameplay

Additional context

Sleep Talk can currently correctly call Gigaton Hammer/Blood Moon without suffering a recharge turn.

-When called by a Move that Calls Other Moves, certain moves lose their "secondary effects" (the heal part of rest, the charge of future sight, the recharge for Hyper beam) If that is fixed in this PR, then the Sleep Talk interaction could become incorrect, where Sleep talk incorrectly prevents successive uses of summoned Gigaton Hammer/Blood Moon. https://github.com/pagefaultgames/pokerogue/pull/3974 #3380

DayKev commented 3 weeks ago

3974 should only fix the bug with multi-hits and Metronome/etc that was introduced in the strict-null refactor (#3259). #3380 is more likely to fix this bug.