[RnD 4.1.0.0] Key presses occasionally repeat themselves when transitioning between menu and gameplay

Found a bug in R'n'D? Report it here!

Moderators: Flumminator, Zomis

Post Reply
ncrecc
Posts: 154
Joined: Thu Jul 12, 2018 12:59 am

[RnD 4.1.0.0] Key presses occasionally repeat themselves when transitioning between menu and gameplay

Post by ncrecc »

If I press esc while in-level to bring up the "return to menu" prompt, and then hold enter until the screen begins fading to black, the "select game" option will immediately be selected once the menu fully fades in, even if I'm not still holding enter.

The issue here is mainly that the game does not wait until the menu fully fades in before it starts receiving your controls again, instead there's a period of time before the menu fades in where if it receives an input, it will immediately act upon that input once the menu is fully faded in.
User avatar
Holger
Site Admin
Posts: 4073
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: [RnD 4.1.0.0] Key presses occasionally repeat themselves when transitioning between menu and gameplay

Post by Holger »

Thank you for reporting this bug/misbehaviour! I was able to reproduce it, and it should be easy to fix it.

You are right about your observations: The key release event from releasing the "Enter" key used to confirm the "want to quit" dialog, when happening during the "fade out", will be handled in the main menu to immediately start the game again!

I'll drop a note here once it's fixed, but this bug should be fixed in the next version of the game.
ncrecc
Posts: 154
Joined: Thu Jul 12, 2018 12:59 am

Re: [RnD 4.1.0.0] Key presses occasionally repeat themselves when transitioning between menu and gameplay

Post by ncrecc »

Looking back, this might actually be useful for certain hotkeys, like enabling 1-step mode before the level starts. Perhaps disable it for keys that perform "regular" functions like pause the game, drop dynamite, move, etc. but keep it for all of the functions under Setup>Key Shortcuts.
User avatar
Holger
Site Admin
Posts: 4073
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: [RnD 4.1.0.0] Key presses occasionally repeat themselves when transitioning between menu and gameplay

Post by Holger »

First I handled this issue by just throwing away all key events entered while fading, but this indeed prevented intentional key presses during fading.

The current solution only throws away those key events produced by key auto-repeat, like the "Return" key that was pressed down too long from your example above.

This should result in expected behaviour in both cases.
Post Reply