How can i retrieve my current frame rate? I thought there was a command in blitz for this but i dont see any
FPS
Blitz3D Forums/Blitz3D Beginners Area/FPS Look in the code archive lots of good stuff there
http://www.blitzbasic.com/codearcs/codearcs.php?code=441
http://www.blitzbasic.com/codearcs/codearcs.php?code=441
Here's the code I use to do it.
; -- Frames Per Second counter. ; Place into the main program loop where it will be executed each frame. The variables used here do not need to be declared globlly as this will occur automatically if the routine is placed in the main program. The value of 'milli_secs' should be set from the 'MilliSecs()' Blitz function at the start of the main program loop. FPS_framecounter = FPS_framecounter + 1 If milli_secs >= FPS_timeout Then FPS_timeout = milli_secs + 1000 FPS_framecount = FPS_framecounter FPS_framecounter = 0 EndIf Color 180, 0, 0 Text 350, 5, "FPS" Color 255, 255, 255 Text 400, 5, FPS_framecount ;^^^^^^
Thanks Arbitrage and Axeman.