So, I'm creating a game where all the systems push events onto the event queue. Those events are then dispatched at the start of the next frame. This works fine, but there are some situations where the delay between a player's action and the effects of the actions can be upto 3 frames.

3 frames for a 60fps is around 50ms. Is this kind of "lag" noticeable to a player?


200ms of delay (between input and response) can be considered to be the point at which things get annoying. Sensitivity to the issue varies from person-to-person, of course, so it's not really possible to give a concrete number.

A delay of 50ms is well under that, and is probably not going to be that noticeable. It may be a problem if your event dispatch is tied to frame rate and you have sustained dips below 60, or if anything else occurs to change the delay from your theoretical worst-case noted in your question.

In general, user testing can give you a more complete picture of whether or not the effect of the latency matters. I suspect you'll be fine, however, unless you're making a game for which reaction time is very important (fighting games, rhythm games).

| improve this answer | |
  • 1
    \$\begingroup\$ Note that the tolerance for latency can also vary between high and low-skill players (new players will tend to react to stimuli as they see them, operating on human reaction time intervals in the 200 ms range, while experts can anticipate game events some time ahead and give inputs timed to tighter time intervals), and the type of feedback — players can detect much smaller latencies in auditory feedback, for example. \$\endgroup\$ – DMGregory Oct 2 '19 at 18:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.