Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!wuarchive!uwm.edu!linac!att!pacbell.com!tandem!zorch!sega0!mykes From: mykes@sega0.SF-Bay.ORG (Mike Schwartz) Newsgroups: comp.sys.amiga.programmer Subject: Re: Lemmings - a tutorial Part IV Message-ID: Date: 26 Mar 91 11:30:05 GMT References: <23787@well.sf.ca.us> <1991Mar25.050519.29068@mintaka.lcs.mit.edu> Organization: Amiga makes it possible Lines: 108 In article <1991Mar25.050519.29068@mintaka.lcs.mit.edu> rjc@geech.gnu.ai.mit.edu (Ray Cromwell) writes: >> Well, I don't care much for multitasking while playing a game, but there >>is NO excuse for not making a version of a game that can be HD installable. >>There is NO excuse for not working on 68010,68020,68030, etc. There is >>NO excuse for not working when a user has extra ram, or a different >>system configuration (e.g. Amiga 3000). >> There is only ONE excuse for making a game trash the current state of >>the system, and that is if you want to make it run for 512k ram A500's and >>need the extra 80k or so. >> >> Any sane programmer can make a game that >>1) is HD installable >>2) not copy protected >>3) saves the state of the OS and restores it when the game is exited >>4) works on any hardware configuration >> I want to point out that when you take over the machine, and get rid of the OS, there are a number of powerful programming tricks that you can use. For example, the 68000 provides an addressing mode called "ABSOLUTE SHORT" which normally you can't use on the Amiga. I rely heavily on this addressing mode by putting all my variables and jump tables in low memory, which frees up a register (normally the A4 register is used to provide a short addressing mode). I also use the 68000 in supervisor mode all the time, which frees up the USP register for a fast place to save an address register. Copy protection is something that I do not like, myself. I wrote my own set of floppy disk drivers that read and write standard trackdisk format. This means that you CAN use diskcopy to copy the disks. For software that use custom formats, diskcopy doesn't work, but that does not mean that the software is truly copy protected. Copy protection implies that the software attempts to make sure that the ORIGINAL disks are being used. A nybble copier can copy custom formatted disks. I have only once implemented a copy protection scheme in a product and I do not like the policy at all and won't use it again. You are also wrong about the 80 lines of assembly code to restore the system. If you want to use the floppy disk, keyboard, and CIA directly, you really hose the OS when you try to restore it. You end up with a LOT of code to restore things (like allocating/dealocating resource structures, etc.). Once you have kicked the OS out, you can't read from hard disks without writing drivers for each of the controllers around. Commodore could have made things easy for us hardware programmers by providing low level access routines for floppy and hard disk that can be called in ROM without the operating system, but they didn't. I'd like to see your 80 lines of code, and with your permission, I would gladly use it in my next product, and you will be happy. I am extremely pleased with the floppy disk routines I wrote. You can see them in action in Budokan and the Immortal for the Amiga. They are extremely fast, because they use the blitter in NASTY mode to do the encoding and decoding of the MFM. These routines are an order of magnitude faster than AmigaDos. I also detect and use memory above 512K to cache data from the floppy disk. My caching algorithm is hard coded to make sure that the most important sectors from disk are guaranteed to be in RAM. If you play budokan, you will find that it only goes to disk ONCE for 90% of the data in the game (a RAM cache is faster than Hard disk!). >> I don't care how many excuses euro-hack programmers can give, it IS >>possible to bang on the hardware and save the state of the OS for >>restoration. It takes about 30 lines of assembly code to do. Processor >>detection is easy. Timing is easy, just steal a CIA register and use >>it instead of CPU delay loops. Running the blitter concurrently with a >>timed CPU loop is easy, just use the blitter interupt and run the code in chip >>ram. (note, need to detect the A3000's 32bit chip access and supply >>a seperate routine) >> I have seen quite a few programs not written by "euro-hack" programmers that fail to work on all amigas, too, even when they use the OS. What you are really getting at is that ANY kind of programming requires good programming practices. I agree with you. I would also love to work on a game that requires more than 512K, but the MARKET is just not there for them. I am not a euro-hack programmer. I am an American programmer. There are lots of American programmers that make games the same way the Europeans do. As a matter of fact, if you are aware of how big the Pirate network is for the Amiga and have seen how they pirate software, you'd see some of the best programming being done for the Amiga. It is really a shame that some pirate is going to make a intro screen for Mike Farren's game that makes the game look bad (the intros I've seen are that good). And to top it off, this pirate is going to compress his game down to half its size on disk... This is not intended as a slam against Mike, just to illustrate how a better approach can make a better product. In my book, CinemaWare started out making some pretty lame games. But over the years, their designs got quite good. I like Wings (although if I had a 68000, I'd want my money back because it is too slow). I liked It Came from the Desert, TV Sports Football, and Sinbad. These games are all more playable than most of the Psygnosis games. But Psygnosis is now the premier original game development company for the Amiga, and CinemaWare is out of business. It makes sense to me to emulate Psygnosis and make KICK ASS Amiga games with lots of sizzle. >>-- >>/~\_______________________________________________________________________/~\ >>|n| rjc@albert.ai.mit.edu Amiga, the computer for the creative mind. |n| >>|~| .-. .-. |~| >>|_|________________________________| |_| |________________________________|_| > >-- >******************************************************* >* Assembler Language separates the men from the boys. * >******************************************************* -- ******************************************************* * Assembler Language separates the men from the boys. * *******************************************************