44. Added 5,000 more trees to the Tornado ground landscape
Mod: Increased the number of landscape trees
By Frankie
Description: ADDING MORE TREES to the default Tornado landscape is
something I wanted to do in Tornado for years! The desire to see more trees whiz by me at low-level is what started off on the quest to modify the Tornado source code. It had always been my dream to add forests to the game. Well, I have good news and bad news. The good news is that, TODAY, I finally figured out how to do this in Tornado, and I can add in any ground object anywhere on the landscape. The bad news is that I have at my disposal only 16,200 bytes with which to add my objects in Tornado. The number of trees is not limited by the computer's speed - it is limited by the 640Kb Conventional Memory cap of the 1993 x86 ASM programming language. Did Bill Gates really once say ""640K ought to be enough for anybody"? Doesn't work for someone trying to extend the game in 2018! Haha. Anyway, I had a lot of fun and excitement editing these 2 files in order to add more trees to Tornado: \visual\SECDATA1.ASM and \visual\map\sectors\OBSECDEF.INC.
Tornado uses 256 sectors in its default landscape. Each sector is divided into a grid of 64x64 tiles. The default game has 10,000 objects (trees, buildings, pipelines, bunkers, airfields etc.) defined.
More trees than you can shake a stick at in the 1993 DOS game Tornado!
This is not a mockup. Rather it is the result of adding more Tree objects inside
the \visual\map\sectors\OBSECDEF.INC file. I discovered that the 1993 x86 ASM code supports up to a maximum of only 15,000 3D ground and sky-layered. So I added another 5,000 tree objects divided among 203 out of the 256 sectors. This gives an average of 25 additional trees per sector. I could have chosen to add a few hundred trees to selected sectors, but instead chose to even out the spread for uniformity sake. Below is one Sector that has more than a hundred tree copses (a copse is a few trees huddled/bundled together).
To be brutally honest, 15,000 ground objects is nothing at all by modern standards. Most modern flight simulations have millions of objects rendered. However back in 1993/1994, Tornado had the most dense landscape of all flight sims. Being able to add 5,000 more trees is a big deal for me as it proves that the game, sorry I mean simulator, can be still be extended,albeit to a limit.
Tornado is a mud-moving DOS flight simulator. IMHO, the more ground objects
whizzing by me at high speed, the better the experience. In the process of adding more greenery to the landscape, I modified the Moving Map display (see the screenshots below) so that the trees show up as a dot in the color of COL_HUD. This adds additional load cycles on the CPU (running under DosBox) but so far I haven't encountered any game breaking problems with the additional pixels.
See those florescent green dots? Them there dots are trees!
You can see the forest for the trees in the large Moving Map (M key) Trees show up as green pixels inside both TV-Tabs. There's a dense forest of trees west of my Tornado. Note: the TV-Tab Moving Map display screenshots above show a very green landscape devoid of clutter because I commented off the display of the othe map objects (mountains, etc.) so that I could clearly see the tree pixels. I later added back all the map display elements so that the Moving Map shows everything up like this:
Tornado surrounded by lotsa hills and trees. Woodman, spare that tree! This line from \VISUAL\SECDATA1.ASM is crucial! Sample code from the file \VISUAL\MAP\SECTOR\OBSECDEF.INC. It shows that:
The Sector 11, 1 contains FOUR tree copses. The LATEST FLIGHT.EXE incorporating 15,000 landscape objects is attached. 607Kb.
Watch this space.
Update, Thursday 22 Mar 2018I had to reduce the number of landscape objects from 16,200 to 15,000. The FLIGHT.EXE with 16,200 landscape objects weighs in at 612Kb and it only runs fine under the DOSBox command prompt. E.g., C:\>FLIGHT /a
If I run FLIGHT.EXE under the normal GUI menu system, it fails to load my SoundBlaster driver. Not enough memory to load the driver. If I switch the soundcard from SoundBlaster to Adlib, it works. I love Tornado's SoundBlaster sounds and effects, so I had to do something! I reduced the number of landscape objects to 15,000. After compiling and linking, the resultant FLIGHT.EXE now weighs in at 607Kb. I have tested this reduced FLIGHT.EXE and I can confirm that it works when played from the GUI menu. As a result of this, I have renamed the subject of this post from "Added 6,200 more trees to the Tornado ground landscape" to "Added
5,000 more trees to the Tornado ground landscape".