[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Framerate Normalizer



Ian Mallett wrote:
((0.0075/(IdealFPS**2))*((IdealFPS/TargetFPS)**2))*(TargetFPS**2)
...doesn't work.

Be careful with data types and division. If IdealFPS and
TargetFPS are integers and you're not using future division,
then (IdealFPS/TargetFPS) will be doing integer division.

--
Greg