Thread: Tyrian fix
View Single Post
  #8  
Old 21-01-2003, 06:20
Joe Forster/STA's Avatar
Joe Forster/STA Joe Forster/STA is offline
Senior forum member
 
Join Date: Nov 2000
Location: Hungary
Posts: 9,836
Thanks: 20
Thanked 342 Times in 224 Posts
Joe Forster/STA is on a distinguished road
Hi Rincewind, yeah, yeah, it's just that that only Borland _Pascal_ programs have this problem, you know...

In short, when you use the CRT unit in your program, the initialization routine of the CRT unit computes a delay value from the actual CPU speed so that the Delay() routine will delay program execution for the same time on all PC's, e.g. Delay(100) waits for a tenth second. Unfortunately, the delay value is computed as the _16-bit_ result of a division which causes an overflow on too fast PC's (where a 32-bit result would work).

Joe
__________________
Joe Forster/STA
For more information, see the FileForums forum rules and the PC Games forum FAQ!
Don't contact me via E-mail or PM to ask for help with anything other than patches (or software in general) done by me, otherwise your request may be deleted without any reply!
Homepage: http://sta.c64.org, E-mail: [email protected]; for attachments, send compressed (ZIP or RAR) files only, otherwise your E-mail will bounce back!
Reply With Quote