SFML community forums

Help => Window => Topic started by: m3nf1s on February 25, 2022, 01:00:38 pm

Title: [SOLVED] Keyboard Input: Actions are running too fast
Post by: m3nf1s on February 25, 2022, 01:00:38 pm
Hello, all!

I wrote my own Tetris https://github.com/m3nf1s/SFML-Tetris (https://github.com/m3nf1s/SFML-Tetris)
When I press the buttons, actions are running too fast

I set low fps, but my Input has Input lags. I set KeyRepeatEnabled(false), but it doesn't work (Idk why)

I read articles about deltaFixedTime, but I think that It doesn't work for me because I move my figure not by pixels, but relative to the gamefield array.

How can I fix it?
Title: Re: Keyboard Input: Actions are running too fast
Post by: m3nf1s on February 25, 2022, 04:18:33 pm
I found answer

It was necessary to move my PlayerInputController move to window.pollEvent loop