-
Notifications
You must be signed in to change notification settings - Fork 1
B Flight
This page describes a DOS-specific hack. It should not be recreated in ported versions of Avalot; it's only described here to help you understand existing code.
DOS games needed to have some way to regulate their speed in order to be playable on the great variety of speeds available on DOS machines. B Flight was a system to provide this regulation. It hooks the DOS 0x09 timer interrupt to increment a word in memory at every tick, which happens at a constant rate of 18.2Hz regardless of the speed of the machine. The game can then inspect this word to find the passage of time.
The word in memory is near the start of the Sundry block provided by Bootstrp; see AVX. Bootstrp also provided the interrupt service routine described above, but it was used only in production; it wasn't suitable for use during development because it needs to run in tandem with the main program. During debugging, a long-running substitute program named Skellern was used instead.
The names come from a BBC musical drama programme called Happy Endings. One episode was about the adventures of "B Flight", a band of musicians, in which the songwriter Peter Skellern sang a song called Slow Down.