rsiddall Posted June 14, 2021 Share Posted June 14, 2021 (edited) If choosing to use multicolored sprites, is the kernel required to be DPC+? Is there a section where kernel choices are explained? Thanks in advance! Update - I was able to cobble together the attached by using some of the examples people have provided: multicolored/animated sprites, collision detection, room scrolling, etc. I've got the "elf" shooting but think I may go with picking up treasures and just avoiding the enemies (no shooting).Awakening.bin Edited June 20, 2021 by rsiddall Quote Link to comment Share on other sites More sharing options...
+SpiceWare Posted June 14, 2021 Share Posted June 14, 2021 @Random Terrain's bB pages has a section on kernel_options and a Kernel Options Chart that should help. Quote These are options for customizing the kernel for various needs. Generally, adding options will mean that some objects will not be displayed. Currently the options only apply to the standard kernel. These options will not work with the DPC+ kernel or the multisprite kernel. player1colors Set to use multicolored P1. Cost: loss of missile1. playercolors Set to use both multicolored players. Must be used with above (player1colors). Cost: loss of missile0. 1 Quote Link to comment Share on other sites More sharing options...
MrTrust Posted June 14, 2021 Share Posted June 14, 2021 This is a little orthogonal to your question, but you could also do multicolored sprites with the standard kernel by drawing both players on top of one another. Takes twice the RAM for one sprite, and you'll need to resort to flicker if you want to reuse the players for anything else, but if, say, your game was mostly one sprite interacting with playfield graphics or something, it might be a handy solution. 2 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 15, 2021 Author Share Posted June 15, 2021 (edited) On 6/14/2021 at 5:36 PM, SpiceWare said: @Random Terrain's bB pages has a section on kernel_options and a Kernel Options Chart that should help. Cool...I think this is the route I'm going: set kernel_options player0colors pfcolors Just wondering if you don't set kernel options, what is the default - is there one? Edited July 1, 2021 by rsiddall Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 15, 2021 Author Share Posted June 15, 2021 14 hours ago, MrTrust said: This is a little orthogonal to your question, but you could also do multicolored sprites with the standard kernel by drawing both players on top of one another. Takes twice the RAM for one sprite, and you'll need to resort to flicker if you want to reuse the players for anything else, but if, say, your game was mostly one sprite interacting with playfield graphics or something, it might be a handy solution. That might be another option to consider. Right now I'm using 2 colors on the player0 sprite (hat/clothes and face/feet) but could add additional colors (like white, to fill in the eyes) if I'm understanding correctly. Quote Link to comment Share on other sites More sharing options...
+Karl G Posted June 15, 2021 Share Posted June 15, 2021 48 minutes ago, rsiddall said: Cool...I think this is the route I'm going: set kernel_options player1colors pfcolors Just wondering if you don't set kernel options, what is the default - is there one? By default you get a kernel that allows you to use both player objects with a single solid color, both missiles, the ball, and a 32x11 asymmetric playfield. The kernel options modify this default, e.g. having to give up one of the missile objects to use player1colors. 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 15, 2021 Author Share Posted June 15, 2021 1 hour ago, Karl G said: By default you get a kernel that allows you to use both player objects with a single solid color, both missiles, the ball, and a 32x11 asymmetric playfield. The kernel options modify this default, e.g. having to give up one of the missile objects to use player1colors. This sounds, unsurprisingly, like the early games Atari made. ? Quote Link to comment Share on other sites More sharing options...
+Gemintronic Posted June 16, 2021 Share Posted June 16, 2021 I've used RevEngs paddlemini mini kernel to add an "extra" multi-colored sprite below the playfield. It was really meant to make paddle controller based games easier. But, I just used it for the extra sprite. It's limited in that you can't move the extra sprite onto the playfield proper. It can only move horizontally just below the playfield. Also, you must edit the mini kernel directly to put in your custom sprite. 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 16, 2021 Author Share Posted June 16, 2021 3 hours ago, Gemintronic said: I've used RevEngs paddlemini mini kernel to add an "extra" multi-colored sprite below the playfield. It was really meant to make paddle controller based games easier. But, I just used it for the extra sprite. It's limited in that you can't move the extra sprite onto the playfield proper. It can only move horizontally just below the playfield. Also, you must edit the mini kernel directly to put in your custom sprite. Awesome game! 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 20, 2021 Author Share Posted June 20, 2021 (edited) Okay, small update to the game. Skeleton is now chasing the player from room to room and can be killed. AwakeningRev1.bin Edited June 20, 2021 by rsiddall Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 21, 2021 Author Share Posted June 21, 2021 Better ball detection/collision? Remade the skeleton. AwakeningRev2.bin Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 22, 2021 Author Share Posted June 22, 2021 Added some columns to various rooms, broken columns, and change the stone color. Turned the bullets into a sword. Elf now hold the sword to kill the skeleton. Reworked the elf to "hold" the sword. Working out a score bug that sometimes resets the game. AwakeningRev3.bin Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 23, 2021 Author Share Posted June 23, 2021 (edited) 15 hours ago, rsiddall said: Added some columns to various rooms, broken columns, and change the stone color. Turned the bullets into a sword. Elf now hold the sword to kill the skeleton. Reworked the elf to "hold" the sword. Working out a score bug that sometimes resets the game. AwakeningRev3.bin 8 kB · 4 downloads Small update. Disabled the score momentarily (will continue to countdown past 0). Changed the PF/BK colors. Switched score fonts to "handwritten". Doubled the skeleton (Player1 -NUSIZ) but doesn't really make a difference to number of hits. Have come to the conclusion this game looks like several others that have been done through the years. Not sure what the point of proceeding is. AwakeningRev3b.bin Edited June 23, 2021 by rsiddall Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 28, 2021 Author Share Posted June 28, 2021 Question about "kernel_options playercolors pfcolors" Why isn't "player1color = $0E" working? (see skeleton). Skeleton is black/blue not white. I also want to use "pfcolors" for different playfield colors (as seen in previous demos). I simplified the code just to replicate the problem I'm having: set kernel_options playercolors pfcolors player0x = 34 player0y = 74 player1x = 112 player1y = 32 Main_Loop COLUBK=$32 player0color: $FE $FE $C2 $C2 $C2 $C2 $FE $FE $FE $FE $FE $FE $FC $C2 $C4 $C6 end player0: %01110000 %00110111 %10110111 %10111111 %00011110 %10100111 %10011001 %00111100 %01100110 %11111111 %11011011 %10111101 %10000001 %01000010 %01111110 %00111100 end player1color = $0E player1: %00100000 %00100100 %00100100 %10011000 %10111100 %10011000 %01011010 %00111101 %00000001 %00101001 %00111100 %01111110 %01010110 %01111110 %01111110 %00111100 end drawscreen goto Main_Loop multicolor_pfcolor.bas Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted June 28, 2021 Share Posted June 28, 2021 If you click on what you want in the chart, it should work properly: https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#kernelopchart You can't use playercolors without player1colors. Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 28, 2021 Author Share Posted June 28, 2021 Okay, so if I change the kernel to set "kernel_options player1colors pfcolors" I can get around this? Basically want a multicolored sprite (player1), a mono sprite (player0) and the ability to color playfield and missile0. Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted June 28, 2021 Share Posted June 28, 2021 21 minutes ago, rsiddall said: Okay, so if I change the kernel to set "kernel_options player1colors pfcolors" I can get around this? Basically want a multicolored sprite (player1), a mono sprite (player0) and the ability to color playfield and missile0. Every valid combination is in the chart. You look down the chart, find what you want, click on it, then copy the code at the top of the chart and paste it into your program. If you only want one multicolored sprite and a multicolored playfield, you'd look at the chart to find player1colors and pfcolors, click on it, then copy what you see at the top: set kernel_options player1colors pfcolors rem * Cost: loss of missile1. To change the color of the plain mono sprite, look here: https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#colup0 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 28, 2021 Author Share Posted June 28, 2021 3 hours ago, Random Terrain said: Every valid combination is in the chart. You look down the chart, find what you want, click on it, then copy the code at the top of the chart and paste it into your program. If you only want one multicolored sprite and a multicolored playfield, you'd look at the chart to find player1colors and pfcolors, click on it, then copy what you see at the top: set kernel_options player1colors pfcolors rem * Cost: loss of missile1. To change the color of the plain mono sprite, look here: https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#colup0 Thank you for your help! I wanted to add a missile to my game but couldn't get it to show up using the "kernel_options playercolors pfcolors". Had to change everything around so that I now have "kernel_options player1colors pfcolors" and the ability to use a missile for the treasure. Since the sword is a ball graphic, I needed another option for the loot. I haven't implemented the collusion routine - just wanted to get the graphic on screen. Updated .bin attached. Thank you again for helping clarify my options. AwakeningRev4.bas.bin 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted June 30, 2021 Author Share Posted June 30, 2021 Fixed the score bug and added player lives. Lose a life when hit by skeleton (does not decrease score). Lose all 4 lives, game ends. I've got the treasure moving around randomly in current room (picking up adds 5+ points). Need to figure out how to make the loot randomly appear in a new room once picked up. AwakeningRev5.bin 1 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted July 1, 2021 Author Share Posted July 1, 2021 Created a custom font for the score. Used RevEng's batari Basic font pack as reference. Same applies to "Old English" - I'm placing in the public domain. Feel free to take and use as your own. Just unzip the pack to your project's directory, and rename the font you want to use to "score_graphics.asm". "Old English" looks good for dungeon crawlers, rogue-like, fantasy, etc. rsiddal_batari_Basic_oldnglish.zip 4 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted July 3, 2021 Author Share Posted July 3, 2021 (edited) Small update. Added startup, sword "swish" and treasure pick-up sounds. Added collision between sword and treasure to make it a little easier when loot reappears in hard to reach location. Included my custom font in this version, too. Is there an example of a timer that I could look at to see how to turn an object(ball or missile) on or off for a determined amount of time? AwakeningRev6.bin Edited July 3, 2021 by rsiddall Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted July 3, 2021 Share Posted July 3, 2021 18 minutes ago, rsiddall said: Is there an example of a timer that I could look at to see how to turn an object(ball or missile) on or off for a determined amount of time? If I remember correctly, you'd do something like this: _Main_Counter = _Main_Counter + 1 if _Main_Counter = 60 then _Main_Counter = 0 : _Missile_Counter = _Missile_Counter + 1 ... ... ... if _Missile_Counter = [whatever number you want] then _Missile_Counter = 0 : [DO SOMETHING] 1 Quote Link to comment Share on other sites More sharing options...
+Karl G Posted July 3, 2021 Share Posted July 3, 2021 What RT said. Basically just remember that one cycle of your main loop (a single frame) with a drawscreen is 1/60th of a second, so you can use a counter to count the number of frames to time it however you like. If you wanted a half second, you would count up to 30, etc. 2 Quote Link to comment Share on other sites More sharing options...
rsiddall Posted July 3, 2021 Author Share Posted July 3, 2021 You guys are awesome! I've got the code implemented and it's working great. Technically you could stay in the same room indefinitely and wait for the treasure to appear but if the average player is unaware, it gives the appearance of randomly spawning in different locations. ? Latest version attached! AwakeningRev7.bin 1 Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted July 7, 2021 Share Posted July 7, 2021 If you want a bunch of rooms, you might want to check out these example programs: https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#ex_8x8_world https://www.randomterrain.com/atari-2600-memories-batari-basic-commands.html#ex_16x16_world 2 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.