The OnIdle method gives you 100% of the CPU idle time, so that's not really 100% of the CPU.
To control the speed, you can either:
1- make some sleep() call in your game loop
2- make all your movements time based : instead of making
write something likeCode:x:=x+5;
Where TimedValue() is a function which ponderates the input value by the frame rendering time.Code:x:=x+TimedValue(5);
Bookmarks