five-on-it / packages/net-client/src/clock / frameElapsed
Function: frameElapsed()
frameElapsed(
now,last):number
Defined in: packages/net-client/src/clock.ts:137
The seconds a frame owes since the last one (both in milliseconds), never negative: a frame's own timestamp is the moment the frame began, which lies before the moment the loop was started when the page spent seconds building a level inside that frame. A negative time would grow whatever decays by the frame (the correction smoothing) without bound.
Parameters
now
number
last
number
Returns
number