
-----------------------------------
Reality Check
Thu Mar 16, 2006 12:06 pm

Where to begin my game?
-----------------------------------
I posted here a while back about an asteroids game I wanted to make.  It will be my first game.  I read arrays and all the stuff that was suggested to me and I think I've got it down.  I am ready to start coding.  I wanted to start simply with the ship and getting it to spin and fire the misiles.  I will have the ship stay in the middle and not be able to move as it gets much too complicated that way.  I'll work on getting the asteroids to come later on and my ship in the beginning would probably be a crappy triangle or something until I get the movement down.  After that I'll make it look better.  My question is...would that be a good place to start?  Or should I start with the asteroids first?

-----------------------------------
Imm0rtal
Thu Mar 16, 2006 12:47 pm


-----------------------------------
The laser should be interesting.. You need to get the coordinates your ship is facing and then use simple math to determind all the coordinates infront of the ship at that moment and have a loop of the laser firing.. Or at least thats what I would do..

Sounds interesting.. I prefer RPG's myself. :o

-----------------------------------
Reality Check
Thu Mar 16, 2006 1:17 pm


-----------------------------------
I have the code in my head.  I think I know pretty much how I am going to do it.  This is my first game and if I have troubles I'll just ask for help.  I'm just asking if thats a good place to start?  I'm going to submit the ship when I am done but remember, my ship will be a crappy triangle, no sounds added, no background, just the misile firing (upon spacebar being pressed) and the ship spinning on spot.  My misile in the beginning will probably be a dot or a small line, I'll make it look nice once I got the code down.

-----------------------------------
Tony
Thu Mar 16, 2006 1:44 pm


-----------------------------------
Don't worry about graphics, start with most basic shapes - triangle for spaceship, line for missile, circle for asteroid. Once you know all the important points, you can slap images on top later.

have a loop of the laser firing.. Or at least thats what I would do..
Don't do that, else you'll be stuck in a situation where nothing but a single missile moves on the screen.

Have a single "game loop" where you move everything a single step at a time. So you want to have something like

loop
   move_ship
   for i:0..num_missiles
      move_missile(i)
   end for
   for i:0..num_asteroids
      move_asteroid(i)
   end for
   check_for_collision
end loop

never

loop
   move_missile
   exit when collision
end loop

