Jump to content
IGNORED

Road Rage 2050


arcade_lights

Recommended Posts

Hey guys. I understand there were issues with my previous topic. I apologize for that. I know I'm new here, but I should have gotten familiar with forum rules more thoroughly. It won't happen again.

 

So I changed the title and excluded everything even remotely political from the game. Just plain old post apocalyptic racing-shooting game now.

 

Unlike my previous game, which sucks, I must say that for my 2nd game, I'm really satisfied with this. I studied batari basic more thoroughly this time and I managed to do several difficulty levels. First the enemies attack alone. Than they come in groups of 2, than 3. All 3 of them die at the same time if you hit one, which sucks, but it makes gameplay harder, so it counts. I still don't know how to work with multisprite kernel so I used NUSIZ1 to create an illusion of multiple enemies and also different colors. Later on speed of the game goes up, and player0 gets a powerup in the form of another car and bigger missile. The background also changes colors during waves which looks very "atarish". I also did the "eye hurting" game over screen in the vain of Missile command with my own sound composition.

 

So that's it for now. I don't have any more ideas for this. Any suggestions are more than welcome.

road rage 2050.bas

  • Like 1
Link to comment
Share on other sites

You can still give the illusion of multiple enemies using NUSIZx. I do so with Space Game. It's a big pain in the rear, but it can be done. For example, if you have three close spacing, and the right one is shot, you can change it to two close spacing, and subtract 16 from the variable you use to keep track of the width of the enemies. If it was the left one, you would do the same, but also add 16 to player0x or player1x. If the middle one was hit, you would just change three close spacing to two medium spacing. You can detect which is hit by comparing the missile x position to the enemy sprite's x position when a collision occurs.

 

Mind you, if you are satisfied with having all 3 get hit, then there's nothing wrong with that, either - whatever feels best for your game. :-)

Link to comment
Share on other sites

You can still give the illusion of multiple enemies using NUSIZx. I do so with Space Game. It's a big pain in the rear, but it can be done. For example, if you have three close spacing, and the right one is shot, you can change it to two close spacing, and subtract 16 from the variable you use to keep track of the width of the enemies. If it was the left one, you would do the same, but also add 16 to player0x or player1x. If the middle one was hit, you would just change three close spacing to two medium spacing. You can detect which is hit by comparing the missile x position to the enemy sprite's x position when a collision occurs.

 

Mind you, if you are satisfied with having all 3 get hit, then there's nothing wrong with that, either - whatever feels best for your game. :-)

This was added to the bB page recently:

 

randomterrain.com/atari-2600-memories-batari-basic-commands.html#ex_dpc_shooting_nusiz

Link to comment
Share on other sites

  • 1 month later...

As far as I understand NUSIZx only works within DPC+ kernel and I haven't gotten familiar with it yet. Is there any way to make these cars disappear one at a time within this 4kb rom and a regular kernel, without bankswitching? I would also like to add a power up pixel which makes player0 invincible for a short period of time. Also, could you give me some examples of equations for a specified movement of cars, because in my game they only randomly charge at you. I would like to make them move, after some time in the game, in a specified manner, like for example those tires in Megamania and also shoot missiles at player0. Just a few examples to spare me from endless searching. Thanx in advance guys.

Link to comment
Share on other sites

I have another question concerning lives. I added a power up in the form of missile1 which is supposed to add an extra life. I wrote the equation outside the main loop to avoid instant game over. However, when player0 and missile1 collide, it adds the full life bar instead of just 1 life. I don't understand what I'm doing wrong here. Here's the equation: Can you help me with this?

 

 missile1height = 2
  missile1y = missile1y + 1
  if missile1y > 200 then missile1y = 200: missile1x =200 
  if collision(player0,missile1) then sounda = 1: lives = lives + 32 
  if lives > 223 then lives = 223 
  
  


   ;***************************************************************
   ;
   ;  Displays the screen.
   ;
   drawscreen
Edited by arcade_lights
Link to comment
Share on other sites

Kdgarris, thanx a lot for all the info man, really appreciate it, but honestly, I still don't know how to apply NUSIZx for this purpose and the link you shared, doesn't mean a lot to me. I don't want to sound boring, but if you could put it in a more simple words I'd be really grateful. I'm sure your explanation above is good and precise but I'm still a noob after all. I don't wanna sound pretentious, but I think this game has potential. It's fast and chaotic, it's challenging and not so easy to play. If I managed to make enemies die one at a time it would be practically finished. Also, I tried to put in an extra life sound in the game but I got an error. If you guys could give me more info about music and sound editor that would be great. I managed to put in my own composition of sound in the game over screen last time, you can see it in the bas file above, but now I don't know how to do it in game for an extra life. I'll attach the music below. I tried to create another setup for this but got an error every time.

 

I don't know what else could I put in this game to make it more challenging. Maybe additional pfpixels like holes in the road? Any ideas are welcome.

 

Here's the music I intended for an extra life:

musiclive.bas

Link to comment
Share on other sites

Okay, let's suppose that your enemy sprite is 8 pixels wide, and you have them tripled with close spacing, and 1 pixel wide missiles. Looking at the chart I linked to, that would be NUSIZ1=$03.

 

For your code, if you need to keep track of the width of the group so they don't go off the screen, then you might set a variable to hold the current enemy width. In this example, the effective width would be 40 pixels (3 8-width sprites plus 8 pixels between them).

 

Now, suppose the player's missile hit that group of 3. The first thing you would need to do is figure out which copy got hit. You would do this by comparing the x position of the player's missile (missile0x) to the x position of the enemy (player1x). The player1x variable is the starting position of the leftmost copy. The second copy starts 16 pixels later, and the third 32 pixels later.

 

What you do next depends on which copy was hit:

 

If the leftmost copy was hit, then change NUSIZ1 to $01 (two close-spaced copies), add 16 to player1x (so that it stays in the same position with the previous leftmost copy missing), and change the width of the group to 24.

 

If the middle copy was hit, change NUSIZ1 to $02 (two medium-spaced copies) and don't change player1x or the width variable.

 

If the rightmost copy was hit, change NUSIZ1 to $01 (two close-spaced copies), and change the group width to 24, but don't change the value of player1x.

 

Note that the NUSIZ0 and NUSIZ1 registers are write-only, so you can't check their value, and they are wiped out with every drawscreen, so you may wish to use a variable to hold this value so that you can check it and change it, and then set NUSIZ1 to the value of that variable right before your drawscreen.

 

I hope this helps!

  • Like 1
Link to comment
Share on other sites

Thank you very much. Now I understand how it works. I'll give it a try tomorrow. Today I added extra lives in the form of a ball and I also added homing missiles1 which makes gameplay much more interesting and challenging. I also had an idea to do a separate screen for player0,player1 collision (crash) and also player0,missile1 collision, (missile hit) which I did, and it looked good, but for some reason it started to interfere with player1 x and y and also with my game over screen background color. Sometimes the color would be how it's supposed to, sometimes it would just go black. I have no idea why this is happening. They are supposed to be separated. Anyway, I'll leave that for later and now try to do this thing you just explained.

Link to comment
Share on other sites

  • 2 weeks later...

I've been trying the whole week with no success. I know what I have to do but it still doesn't do the trick. It does something, making cars tremble and flicker at some points, but not destroying one by one, they still die at the same time. Here are the equations I tried:

 

For example, If there are 3 cars coming:

if missile0x = player1x then player1x = player1x+16: NUSIZ1 = 01
if missile0x = player1x + 16 then NUSIZ1 = 02
if missile0x = player1x + 32 then NUSIZ1 = 01

Even if I succeeded there would still be one problem. My car shoots from all sides and enemies attack from all sides. So if an enemy car is below me and I shoot above this would still cause an effect.

 

Also, this whole dim and variables thing is still very confusing to me, I really need to take more time to study this.

Link to comment
Share on other sites

The first thing I see wrong is that there needs to be a $ in front of the NUSIZ value (so NUSIZ1 = $01, etc.)

 

Another thing to keep in mind is that the individual enemy cars are 8 pixels wide, not 1, so there's a range of possible missile0x positions that would result in a hit. The code would look something like this:

 

if collision(missile0,player1) then goto __enemy_shot

...

...

...

__enemy_shot

if missile0x < player1x + 8 then whatever happens when the left car is hit

if missile0x > player1x + 16 && missile0x < player1x + 24 then whatever happens when the middle car is hit

if missile0x > player1x + 32 then whatever happens when the right car is hit

 

The numbers are probably off, but that's the general idea. Using collision detection instead of just the player1x value also eliminates the problem of false hits when enemies are below you and you shoot up.

 

You also need to account for what the NUSIZ value is when the enemy is hit. For example if it's $04 (2 copies with a wide space in between after the middle enemy from a group of 3 is shot) and the enemy on the left is shot, you not only have to change the NUSIZ value to $00 to leave only one copy, you have to shift the player1x value to the right the appropriate amount. Otherwise it will look like the player shot the car on the left but destroyed the one on the right. What the NUSIZ1 value is determines both what it needs to be changed to and how much if any the player1x value needs to be changed.

Edited by KaeruYojimbo
Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...