
-----------------------------------
jamonathin
Thu May 26, 2005 9:35 am

Intellivision Games on Turing? - Astrosmash!
-----------------------------------
I was bored one day and was playing my "Intellivision Lives!" game for PS2, and I got addicted to Astrosmash!.   I tried recreating it using only turing, no imported images, and it's fairly well done, not exact like the original, but pretty close.

Here it is:

Left / Right  - Arrow Keys to Move
Up Arrow Key to Teleport
Down Arrow Key for Auto-Shoot

-----------------------------------
zomg
Thu May 26, 2005 11:00 am


-----------------------------------
its fun :) nice job with being able to shoot and move at the same time

-----------------------------------
Flikerator
Thu May 26, 2005 12:59 pm


-----------------------------------
To shoot and move at the same time all you need to do is use Input.KeyDown instead of Getch :p

Very well done game, especially for no imported images :P

-----------------------------------
jamonathin
Thu May 26, 2005 1:25 pm


-----------------------------------
I think he ment delay's with the shooting :think:.

-----------------------------------
Token
Thu May 26, 2005 1:58 pm


-----------------------------------
nice game, but its spelt peak not peek.

-----------------------------------
jamonathin
Fri May 27, 2005 7:58 am


-----------------------------------
Meh, most compsci students suck at english anyways  :P

-----------------------------------
RaPsCaLLioN
Fri May 27, 2005 10:19 am


-----------------------------------
I've never played Intellivision games before and am not familiar with Astromash.   But I've noticed a couple things;

-I'll die for no reason.

-And my score goes down for no reason.

Why does this happen?

-----------------------------------
Carino
Fri May 27, 2005 10:35 am


-----------------------------------
I've never played Intellivision games before and am not familiar with Astromash.   But I've noticed a couple things;

-I'll die for no reason.

-And my score goes down for no reason.

Why does this happen?

You can't let any of the satellites hit the ground or you die right away. So thats why you are probably dying for no reason. And everytime an asteriod hits the ground you lose points.I have this game on my cell  :P

-----------------------------------
Cervantes
Fri May 27, 2005 5:06 pm


-----------------------------------
Um.. I think you need to work on your collision detection a bit.  It seems somewhat off at times.  Also, the shooting is messed up.  I press the space bar, but only some of the time the shot actually occurs. Is this some sort of reloading feature?  :lol:  
In any case, some explanation would be good.

-----------------------------------
Token
Fri May 27, 2005 5:17 pm


-----------------------------------
Meh, most compsci students suck at english anyways  :P

yah really, i'm actually quite a horrible speller myself  :lol:, it just stood out to me.

-----------------------------------
Naveg
Fri May 27, 2005 11:38 pm


-----------------------------------
Meh, most compsci students suck at english anyways  :P

nah...i wouldnt say that

-----------------------------------
MysticVegeta
Sun May 29, 2005 12:28 am


-----------------------------------
Cool game except sometimes when i hit the "asteroids" or "boxes", i die. lol. I dont know how that happens  :roll:

-----------------------------------
jamonathin
Sun May 29, 2005 7:56 pm


-----------------------------------
Um.. I think you need to work on your collision detection a bit.  It seems somewhat off at times.  Also, the shooting is messed up.  I press the space bar, but only some of the time the shot actually occurs. Is this some sort of reloading feature?  :lol:  
In any case, some explanation would be good.

For my collision, I was trying something new (or at elast something that I thought would work)

this is what I have for collision detection

for i : 1 .. upper (laserx)
        if laserg (i) = 1 then
            lasery (i) += 9
            Draw.ThickLine (laserx (i), lasery (i), laserx (i), lasery (i) + 20, 5, white)
            for w : 1 .. upper (a)
                if a (w).alive > 0 then
                    for q : 0 .. 20
                        if lasery (i) + q >= a (w).y1 and lasery (i) + q = a (w).x1 and laserx (i) = a (w).y1 and lasery (i) + q = a (w).x1 and laserx (i) = bombx (b) and laserx (i) = bomby (b) and lasery (i) + t = hx - 2 and laserx (i) = hy - 2 and lasery (i) + h  maxy then
                laserg (i) := 0
            end if
        end if
    end for
Basically what I have going on is the laser moves up by 9 pixels, because the size of the small asteroid is 10, and anything larger would skip right by the asteroid.  What the for q: 0 .. 20 is for is it checks every vertical pixel on the laser to see if it hits anywhere on the asteroid.  Now that I think of it, the problem probabily is, the laser is 5 pixels wide, and I never check the width of the laser, I'm always checking the center.  That's probabily what's going wrong,  :P 

For the space bar thing.  I probabily should have tested that lol.  I always just figured it worked right, and so whenever I tested everything else, I just used the autoshoot.  So i've never run into this problem, but here's all i have for that section, I have no idea whats wrong.
if key (' ') and laserc = 0 or autoshoot and laserc = 0 then %If spacebar is pressed or auto shoot is on
        for i : 1 .. upper (laserx) %checking all lasers
            if laserg (i) = 0 and laserc = 0 then
                laserg (i) := 1 %Tells program this laser is in use
                laserx (i) := x + 10
                lasery (i) := 50 + Pic.Height (man)
                %sound(300,1)
                laserc := 1
                exit %exit for loop
            end if
        end for
    end if
    refresh %Drawing Everything/lasers
    if laserc >= 0 then %Just a delay between lasers
        laserc += 1
        if laserc >= 15 then %Which is a delay of (15 * delay(10)) = delay(150)
            laserc := 0
        end if
    end if 
I cant really figure it out, it anyone does, thats cool, let me know, but if not, thats ok, I'm pretty much done with this game.

Cool game except sometimes when i hit the "asteroids" or "boxes", i die. lol. I dont know how that happens 
I've never run into that problem.  By any chance did you hit a box when one of those white things hit the ground?
