kamakazi Posted January 3, 2012 Share Posted January 3, 2012 Hi All, I have been out of practice when it comes to programming in Atari BASIC. As well, I have been trying to discover new ways to produce graphics in Atari BASIC. Is there an easier way to produce graphics in a bit format without having to invoke the PMG of the computer? Is there a way to use portions of assembly to incorporate graphics in a BASIC game program? I am wanting to use real hardware I have on hand (XEGS & a just acquired 810 drive from V61). Reason why I ask is because I have a game I developed for Windows PCs using DarkBASIC and I would like to try and port it over to the 8-bits. I want to use the best graphic method possible that the machine will allow without going into Assembly too heavily. I know BASIC can do most of what I need, I just need a way to do better graphics. I am including a screenshot of the Windows version to show kind of what I am trying to do. I know the 8-bits won't be able to perform on this level, but if I can make the paddle and blocks more like what is in the image it would help the game. Oh...game will use joystick controllers. Thanks in advance! Quote Link to comment Share on other sites More sharing options...
Synthpopalooza Posted January 3, 2012 Share Posted January 3, 2012 (edited) Well there are several methods available to you, but each with it's own drawbacks and advantages. 1. Using Antic 4 character mode, and using PMG overlays on the bricks. This will give you 4 color by 5 level shading. You would also use missiles for your balls and a DLI on player 0 to create an extra paddle on the bottom. 2. Using Graphics 10 in char mode. With Graphics 10 you can get anywhere from 9 individual colors to 4 colors by 2 level shading. Disadvantages are lower horizontal resolution, and you can't use Player 0 as that is the background color. 3. Using Graphics 9 in char mode, and using PMG overlays on the bricks, combined maybe with color DLI's on the background. You get 16 level shading, plus with PMG overlays you can get 5 colors of bricks per line. I believe you can use priority blending on mode 9 to get the extra colors. Use a DLI again on player 0 to make your paddle on the bottom, Disadvantage is again lower resolution than Antic 4. 4. Using Super IRG ... you basically alter your character set every VBLANK to get 14 colors in ANTIC 4. The disadvantage here is it can get really flickery if you don't choose your colors right, but you can dither to reduce the flicker and create solid color fields. You could also do the character set change on every scanline rather than having to flip the character set on the whole screen. All of these use Char mode. You can also adapt some of these methods to bitmap mode (Graphics 7, 9, 10, or 15) as well, with varying results. Edited January 3, 2012 by Synthpopalooza Quote Link to comment Share on other sites More sharing options...
kamakazi Posted January 4, 2012 Author Share Posted January 4, 2012 Thanks for the reply Synthpopalooza. I don't have to worry about a ball as this game doesn't have one . Once the BASIC code is finished, I plan to convert it to binary using Atari DOS functions to create a stand-alone, self-loading disk. I plan to use Atari DOS' function for saving the program as a binary. Quote Link to comment Share on other sites More sharing options...
kamakazi Posted January 10, 2012 Author Share Posted January 10, 2012 I also need to add that once the game is complete, I plan to put it in cartridge form as well. So far, I have this much completed: Working paddle Joystick controls Playfield Player's block changes colors when fire button is pressed Score & Left text I still need to complete: Randomly colored and placed blocks in playfield Player's block to be placed in playfield working score working left title screen working start button The game is using Graphics mode 9 mainly for the amount of colors that can be used. Project is coming along smoothly. However, I've lost or misplaced the source code to the Windows version so I am having to perform the game's logic from scratch again. I will post pics as soon as I get them off my cell phone. Quote Link to comment Share on other sites More sharing options...
kamakazi Posted January 10, 2012 Author Share Posted January 10, 2012 I can't seem to remember how, but I do remember there is a memory location using POKE that disables the screen saver on Atari 8-bits. Does anyone remember that location? Quote Link to comment Share on other sites More sharing options...
Roydea6 Posted January 10, 2012 Share Posted January 10, 2012 77 Quote Link to comment Share on other sites More sharing options...
kamakazi Posted January 10, 2012 Author Share Posted January 10, 2012 Thank you, rdea6! That's been buggin' me. I don't know why I couldn't remember it. Quote Link to comment Share on other sites More sharing options...
+therealbountybob Posted January 10, 2012 Share Posted January 10, 2012 Just wanted to wish you luck with your programming kamakazi You might consider using Turbo BASIC from the off if you haven't done so already Quote Link to comment Share on other sites More sharing options...
+Stephen Posted January 10, 2012 Share Posted January 10, 2012 I can't seem to remember how, but I do remember there is a memory location using POKE that disables the screen saver on Atari 8-bits. Does anyone remember that location? If I am not mistaken though, you have to continually strobe this register, as it gets updated during the VBI. Just poking to it once will not turn the color cycling off. Quote Link to comment Share on other sites More sharing options...
Rybags Posted January 11, 2012 Share Posted January 11, 2012 (edited) Attract mode takes little over 9 minutes NTSC, about 11 minutes PAL. If your levels expect to take less time, hitting it once per level will be enough. If you have a pause system, then just reset it when pause mode is exited. If the game uses keyboard for anything, then hitting a key resets it anyway. Re Basic - if you're using Atari Basic you won't get much joy without needing to resort to Assembler routines. Turbo Basic will give somewhat more leeway. Edited January 11, 2012 by Rybags Quote Link to comment Share on other sites More sharing options...
kamakazi Posted January 11, 2012 Author Share Posted January 11, 2012 Hmmm...never heard of Turbo BASIC. I stuck with Atari BASIC mainly because it is built in. And I can use Atari DOS to convert to binary when my project is finished. I had done this one years ago when I first obtained a used XEGS with 2 floppy drives and a modem. It also came with one of the books on Atari Archives I think was 101 Microcomputer Games (the yellow one). One of my favorite text games in the book was Bombardment. So I converted it using graphics instead of text. I also strictly used the joystick. If I remember correctly, I used Autoexec to load the binary file created once the project was finished. I couldn't believe the speed difference from a BASIC file and a BINARY file. Sadly, I'm using a 810 Single Density drive now as all that other Atari stuff I had my ex kept and sold off. So, I'm having to start over but it's been years since I have programmed this way. I'm a little rusty But, I'm having fun doing it again. My only issue is I'm using Graphics Mode 9 and am having to come up with a way to place the score on the screen along side the playfield. I've got the numbers already mapped out and they display OK. I'm not doing so well coming up with a way to keep the score display accurate. I'm trying to use an array for it. DIM SC(6) This would allow for all 6 numbers (possible score is 999,999). The thought was that once the ones place hits 10, subtract 10 from it and add one to the tens place and so forth and place the remainder back into the ones place. Good news is that I have managed to get some blocks placed in the playfield at random positions and of random colors (can only be one of 5 colors). Due to the speed of BASIC, however, the game is almost unplayable due to slow responses from the interpreter. I am hoping that this will be eliminated when converted to binary. Quote Link to comment Share on other sites More sharing options...
Rybags Posted January 11, 2012 Share Posted January 11, 2012 Convert to binary? You mean compile. Saving a Basic program by writing out the memory from Dos won't make it run faster. For a score display in Gr. 9 you'd be best off with a text line, which would need a DLI to change from normal to GTIA mode. Quote Link to comment Share on other sites More sharing options...
Roydea6 Posted January 11, 2012 Share Posted January 11, 2012 turbobasic.zip 2 versions of Turbo basic 2.0 and 1.5 and one atr has all the document files. Load with Basic off. Autorun files will load Turbobasic. @kamakazi Hmmm...never heard of Turbo BASIC. Quote Link to comment Share on other sites More sharing options...
Synthpopalooza Posted January 11, 2012 Share Posted January 11, 2012 There is a command in Turbobasic which will display text in bitmap mode: TEXT X,Y,"TEXT" One thing to keep in mind: Characters will display as 8 pixels wide unless you precede the command with POKE 87,8. Doing this method, you can design a custom character set using 2x8 pixels and then write it to the Graphics 9 screen. You will have a 20 column wide character display. Keep in mind you can also use Graphics 9 from text mode by doing POKE 623,64 while in GRAPHICS 0 and then using a custom character set. Quote Link to comment Share on other sites More sharing options...
+therealbountybob Posted January 16, 2012 Share Posted January 16, 2012 You might checkout Page 6 have the Turbo Basic Programmers Kit disks and compiler etc. I have really useful Turbo Basic enthusiasts guide (Western New York Atari Users Group) can't find this on atariarchives.org - Is this scanned somewhere? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.