Skip to content

[Bug]: Patting pets will sometimes make them sit/stand too #22

@Fourmisain

Description

@Fourmisain

I'm reporting this on behalf of @kanapuro who originally reported this issue on Fourmisain/IndyPets#31.
It turned out to be a standalone bug in PatPat, meaning no other mods are involved.

Problem Description

When Shift + Right Clicking a pet, it will always be patted while holding the button as expected.
However, sometimes it will also do the vanilla behavior of standing up / sitting down.
When this happens, you can keep holding the button and it will continue to pat and change sitting/standing, no matter how long you hold for or if you switch pets.

To reproduce this issue spawn a lot of pets (just one is enough, but more is easier), hold shift at all times, then right click and hold on a pet.
Most of the time it gets patted like normal. Let go of right click and try again (maybe with a different pet).
Eventually a pet will sit down/stand up, now you are in a state where both patting and vanilla action are going through.
(Took me about a full minute to reproduce this in singleplayer.)

Due to the random nature of this bug, this seems like a race condition of the vanilla action going through even though patting is supposed to "block" it.

I also suspect that this bug might have been introduced in 1.2.0 with the Keybinding Update, though you're a better judge for that.

Environment

  • Minecraft Version: Fabric 1.21.5, Fabric Loader 0.17.2
  • Mod Version: 1.2.2

Attachments

Log shows 0 abnormality.

Video from @kanapuro demonstrating the issue (with Control + Right Click as the keybind):

8mb.video-xyl-TtIbLmLN.mp4

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions