The Making Of...: Tractor Tycoon
by Alex Jones

I'm writing this article so all the fans of Tractor Tycoon out there can have a look at the production progress. It gives history about the game,methods used to create as well as examining the code,graphics and sound production.

History

Spring 2002

The Beginning

While me and a friend were discussing computer games we somehow got on to the subject of tycoon games. You know, Rollercoaster Tycoon,Transport Tycoon,Railroad Tycoon etc. He went on to say what he thought the next would be - a game where you bought Tractors but always ended up in the game ending with bankruptcy. In a robot style voice he made a few options and I decided to program it. That was how Tractor Tycoon originally came around.

The First Game

Originally I wrote out the entire code as best I could in my basic Blitz Basic code in a 30 minute session. On typing it in that night it failed to work, and further editing proved fruitless. At this point no graphics or sound were in the game, and there was only one menu so if this wouldn't work, there was no chance of writing a full game. The project was indefinitely put on hold.

Summer 2002

The Stupidest Game Compo

When this was announced only one game came to my mind - Tractor Tycoon. Using my now improved knowledge of the Blitz Basic language, I set about retrying. It seemed the perfect game. The first thing to be changed was the three if's - changed to if/else, as I had yet to discover Select/Case command. The game now ran so i added more Print's,Input's and Goto's and the game was more or less complete. Sound was added and some Tractor Clip Art as I couldn't do my own. The game was first released on the 6th August 2002. By the 11th of August it had clocked up an amazing 100 downloads and I had many comments.

The Result

Tractor Tycoon failed in the competition, not making the judging list. I'll never know what position it got out of the 40 entries. Since the competition ended, traffic to the area of the showcase has been low, yet as of 15th January 2003 it had reached 210 downloads and 625 reads.

The Code

The code distributed with the game is very messy. I've tided it up for the tutorial but they should both be the same thing. It starts with the usual graphics and apptitle commands:


There were a lot of files to load into memory, taking about 10-20 seconds depending on the computer so a loading screen was added. Simply a case of loading and drawing an image before loading the rest of the files and clearing the screen.


Here are all the files loaded


After this was completed the screen was cleared to get rid of the loading screen and the splash screen and sound were displayed and played with a 3 second delay before moving on


.goat is used in this next piece because in George Bray's Beginner's Manual he quotes:


And now so do I! If I wanted to be economical with memory I should release the loading screen and sounds as well.


The first input piece is used here. Sadly the numbers and the tractors they relate to are images, I should have turned them into code. Notice how you must enter 1 to get tractor one but anything (except 1) will get Tractor two. This is because of the If Input=1 then goto Tractor A Else (Anything but 1) goto tractorb. God only knows why there is and end there? It's not needed and only there because it was in my original source code.


Should the user chosen the goto tractora option the following code would have been processed, ending in another goto to skip the tractorb code.


Here is the other option. The Goto backtothegame command here is also useless as it is right after it, it doesn't need to skip code like the first one does.


Both options come back to here, therefore it doesn't keep a record of which tractor you choose, and therefore is absoulotely pointless and stupid. Luckily that was the point of the game so no problem there. More print's delay's and drawimages. Really those should be released after using them (FreeImage) to save memory


Another If/Else option here relying on the user command above. Same method as eariler


Here is cashone, the first option to end the game


And cashtwo, the other option.


Labels used in the goto sections were


All (ignoring goat) are simple descriptions of what they are, a method I find useful as the labes bar on the right allows you to jump through code easily. Also with the sounds name's being plain I had a list of what each sound said so I could see what each one was. This was commented out and later deleted from the code.


That's really all there is to the code. Next up:

The Graphics

The graphics were always going to be basic, the game relied on funny text and sound to make it work. In the end for the compo I took two royalty-free clipart images and stuck them on. Some text also ended up as images for some reason but that wasn't really needed. Since the game was released i've been meaning to replace the tractors with my own versions drawn in MS Paint with the circle,square and fill tools. There isn't much more to say about the graphics. Very basic and ugly but doing the job in the end. More important was:

The Sound

The game wouldn't work without the Robot voice. The way this was done I have kept secret until now, although someone did guess correctly I denied it. I couldn't find a free PC app that would to what I wanted, but remembered one came with the Amiga. "Say" came with the Amiga on the WorkBench disk. So after experimenting with the Pitch and getting a voice I thought would sound good, I wired in my Amiga to my PC. Using a R/L Phone to 3.5mm Stereo Jack lead, usually used to transfer sound from my sound card to my stereo, I plugged one end in the Amiga and another to the PC sound card's Line In port. Then using Windows' Sound Recorder I recorded all of the sounds onto the computer.The below pictures show what I mean:



There wasn't much more to do with the sound although the .wav files were a little large. Using a wav-mp3 converter (in this case AudioWriter off the PC Plus Feb 2002 CoverDisc - Same Issue as Blitz Basic Cover Version) and I was ready to add them to the code.

The End

Well that's about it - Tractor Tycoon is complete, and now you know how. Who knows what could happen next. Merchandise? Sequel? Publisher? Anything is possible :) Just want to say thanks to Scott for the original idea, Cyberseth for starting the compo which made me finish the game and to everyone at BlitzCoder for your help and coding advice. Download the game,source code,graphics, and sounds here Thanks For Reading! Alex Jones/alexj2002


For a printable copy of this article, please click HERE.


This site is Copyright© 2000-2004, BlitzCoder. All rights reserved.