med-material / Whack_A_Mole_VR

Whack-A-Mole in VR
MIT License
3 stars 15 forks source link

Location unknown : FPS loss when pausing/unpausing the game multiple times in the same game #217

Open lucasmnt opened 1 year ago

lucasmnt commented 1 year ago

While working on the fading in & out effects for the pause menu, and the countdown when launching a game, I found out that if one clicks on the pause button multiple times via the therapist UI in the same game, the frames per second go lower and lower as you pause/unpause the game.

In this first screencapture, you can see on the top right corner the FPS going lower and lower and the CPU latency going higher and higher as I click on pause button. I want to note that it isn't because I click rapidly on the button that this happens, indeed it also happens when you do this much slower.

BugFPSLOSS

The problem also seems to get "fixed" when you quit the game to launch another one. In this second screencapture, top right corner, you can the the FPS / lacency getting back to normal when I quit. If you don't quit the game, the FPS will stay locked higher, the higher you go.

BugFPSLOSS2

Firstly, we will need to figure out where is this problem coming from, and then we will be able to decide what to do to resolve the issue.