You know what you might be on the right track. Shamblar does have a pretty fast machine. The machines of run this on are P4 2.4ghz with Qruadro4 200NVS, and a 850mhz P3 with Geforce2.
The code i'm using for frame limiting is:
Aliens are moved with this code:
The code i'm using for frame limiting is:
; TYPE FOR FRAME LIMITING ; ------------------------ Type Frame_Rate Field TargetFPS# Field FPS# Field TicksPerSecond Field CurrentTicks Field FrameDelay Field SpeedFactor# Field AccumTicks End Type ; FRAME LIMITING STUFF ; --------------------- Global FLMode = True Global Target_FPS# = 30.0 Global FL.Frame_Rate = New Frame_rate Frame_Limit_Init(Target_FPS#) While True Goto Set_Speed_Factor .Set_Speed_Return ThisFrameTime = FL\CurrentTicks Delta_Time = ThisFrameTime-LastFrameTime LastFrameTime = ThisFrameTime . . . Wend ; LABEL & CODE ADDED FOR FRAME LIMITING ; -------------------------------------------------------------- .Set_Speed_Factor If FLMode = False Then Goto Set_Speed_Return FL\CurrentTicks = MilliSecs() FL\SpeedFactor = (FL\CurrentTicks - FL\FrameDelay) / (FL\TicksPerSecond / FL\TargetFPS) If FL\SpeedFactor <= 0 Then FL\SpeedFactor = 1 FL\FPS = FL\TargetFPS / FL\SpeedFactor FL\FrameDelay = FL\CurrentTicks Goto Set_Speed_Return ; FUNCTION ADDED TO INITIALIZE THE FRAMERATE DEVICE ; -------------------------------------------------------------- Function Frame_Limit_Init(target_FPS#) FL\TargetFPS# = target_FPS# FL\TicksPerSecond = 1000 FL\FrameDelay = MilliSecs() End Function
Aliens are moved with this code:
TranslateEntity(a\entity, xDelta * alienSpeed * FL\SpeedFactor, yDelta * FL\SpeedFactor, 0)