Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Magic Coat incorrect message #5579

Open
Pawkkie opened this issue Oct 25, 2024 · 1 comment · Fixed by #5645
Open

Magic Coat incorrect message #5579

Pawkkie opened this issue Oct 25, 2024 · 1 comment · Fixed by #5645
Labels
bug Bug category: battle-mechanic Pertains to battle mechanics status: unconfirmed This bug has not been reproduced yet

Comments

@Pawkkie
Copy link
Collaborator

Pawkkie commented Oct 25, 2024

Description

Another issue found as a result of writing sleep clause tests. When you Magic Bounce a move back at an opposing battler, the message you get should be "[yourMon] bounced the [move] back!"

In this specific case for whatever reason, the message instead reads " The opposing [theirMon] bounced the [move] back!" in spite of Magic Coat being used by the player's mon.

Here's a test you can use to reproduce this behaviour with the sleep clause stuff removed (it's unrelated to sleep clause).

    GIVEN {
        ASSUME(gMovesInfo[MOVE_SPORE].effect == EFFECT_SLEEP);
        ASSUME(gMovesInfo[MOVE_MAGIC_COAT].effect == EFFECT_MAGIC_COAT);
        PLAYER(SPECIES_ZIGZAGOON);
        PLAYER(SPECIES_ZIGZAGOON);
        OPPONENT(SPECIES_ZIGZAGOON);
        OPPONENT(SPECIES_ZIGZAGOON);
    } WHEN {
        TURN { MOVE(player, MOVE_MAGIC_COAT); MOVE(opponent, MOVE_SPORE); }
        TURN { SWITCH(opponent, 1); }
        TURN { MOVE(player, MOVE_SPORE); }
    } SCENE {
        ANIMATION(ANIM_TYPE_MOVE, MOVE_MAGIC_COAT, player);
        MESSAGE("Zigzagoon bounced the Spore back!");
        MESSAGE("The opposing Zigzagoon fell asleep!");
        STATUS_ICON(opponent, sleep: TRUE);
        ANIMATION(ANIM_TYPE_MOVE, MOVE_SPORE, player);
        ANIMATION(ANIM_TYPE_STATUS, B_ANIM_STATUS_SLP, opponent);
        MESSAGE("The opposing Zigzagoon fell asleep!");
        STATUS_ICON(opponent, sleep: TRUE);
    }

Here's a video if the weird message resulting from this test

2024-10-24.21-43-02.mp4

This message seems to print properly for every other one of the sleep clause tests and the Magic Coat tests I read through. Not sure why it gets messed up in this case.

Version

1.9.3 (Latest release)

Upcoming/master Version

No response

Discord contact info

No response

@Pawkkie Pawkkie added bug Bug category: battle-mechanic Pertains to battle mechanics status: unconfirmed This bug has not been reproduced yet labels Oct 25, 2024
@Pawkkie Pawkkie reopened this Dec 3, 2024
@Pawkkie
Copy link
Collaborator Author

Pawkkie commented Dec 3, 2024

I know #5645 was meant to fix this, but I don't think it did entirely.

Because this issue was discovered during the sleep clause test writing there's a test that references it, "Sleep Clause: Reflection moves (ie. Magic Coat) fail if sleep clause is active and they reflect a sleep move". That test should have failed as soon as#5645 was PR'd because it's using the incorrect message with a note to update after the bugfix. This test is unfortunately still displaying the incorrect message after a Magic Coat.

This is on current upcoming:

2024-12-02.20-49-11.mp4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug category: battle-mechanic Pertains to battle mechanics status: unconfirmed This bug has not been reproduced yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant