Jump to content

Photo

falling sky


8 replies to this topic

#1 bogax OFFLINE  

bogax

    Dragonstomper

  • 776 posts

Posted Mon Mar 5, 2018 8:40 PM

I don't think I'd call this a work in progress, more like exploring some ideas

 

The code is buggy there aren't many comments and it's full of kruft

 

the stuff in the bottom left corner is the upper byte of a 9 bit counter which

is supposed to be keeping track of the number of playfield blocks but it doesn't quite

 

edit: forgot to mention I had to adjust some stuff in the 2600basic.h file

        but I don't know how it comports with RevEng's latest and greatest

        I moved playfieldpos = $F0 and commented out the calculations

        for playfield from pfres

Attached Files


Edited by bogax, Mon Mar 5, 2018 8:50 PM.


#2 Mountain King OFFLINE  

Mountain King

    Dragonstomper

  • 684 posts
  • Location:Philadelphia, PA

Posted Mon Mar 5, 2018 9:39 PM

Cool concept. I like the rapid fire.



#3 TrekMD ONLINE  

TrekMD

    River Patroller

  • 3,677 posts
  • Location:Coral Gables, FL

Posted Mon Mar 5, 2018 10:30 PM

Pretty cool.  That rapid fire works like a charm!



#4 Lillapojkenpćön OFFLINE  

Lillapojkenpćön

    Star Raider

  • 93 posts

Posted Fri Mar 9, 2018 6:08 AM

Can you explain how this works?

 

   dim     p0x = player0x.y
   dim     p0y = player0y.y
   dim    p0lo = y
   dim     m0x = missile0x.x
   dim     m0y = missile0y.x
   dim    m0lo = x
   dim     p1x = player1x.w
   dim     p1y = player1y.w
   dim    p1lo = w
   dim     m1x = missile1x.v
   dim     m1y = missile1y.v
   dim    m1lo = v
   dim     blx = ballx.u
   dim     bly = bally.u
   dim    bllo = u
 
I've tried using the same variable for both x & y like you do with U V W X & Y but it allways results in jerky motion, don't think I understand how it works exactly?
Can I do that? I am doing this now..
 
   dim _P1_L_R = player1x.v
   dim _P1_U_D = player1y.w
 
   dim _robotspeed = l.var0
 
--------------------
 
 if player1x < temp6 then _P1_L_R=_P1_L_R+ _robotspeed 
 if player1x > temp6 then _P1_L_R=_P1_L_R-  _robotspeed 
 if player1y - l > 93 then _P1_U_D=_P1_U_D- _robotspeed  else player1y = 93 ; makes the player stop at y-pos 93 no mather what speed it has


#5 bogax OFFLINE  

bogax

    Dragonstomper

  • Topic Starter
  • 776 posts

Posted Fri Mar 9, 2018 11:04 AM

what kernel?

what are you trying to do?

 

if your speed was, say, l = 5 

then player1y would have to be >= 99 for player1y to not be set to 93 and then player1y would be >=94 



#6 Lillapojkenpćön OFFLINE  

Lillapojkenpćön

    Star Raider

  • 93 posts

Posted Sat Mar 10, 2018 2:56 AM

DPC+

I'm trying to get the players to chase the ball object that you controll left and right ( temp6= _BALL_L_R -4 )

Or I'm doing that allready but I'm trying to save variables if I can?

 

Yup, that's exactly what it's for, but player1-4 only moves upwards and player5-8 only moves down..

 

 if player5x < temp6  then _P5_L_R = _P5_L_R + _robotspeed  
 if player5x > temp6  then _P5_L_R = _P5_L_R - _robotspeed  
 if player5y + l < 66 then _P5_U_D = _P5_U_D + _robotspeed else player5y = 66 
 
So if player1y=94 and l=5, then the next time it will "snap" to 93 instead of move to 89 like this would
 
 if player1y > 93 then _P1_U_D=_P1_U_D - _robotspeed

Edited by Lillapojkenpćön, Sat Mar 10, 2018 9:16 AM.


#7 bogax OFFLINE  

bogax

    Dragonstomper

  • Topic Starter
  • 776 posts

Posted Sat Mar 10, 2018 11:29 AM

I'm still not clear on what your trying to do that it's not doing
 
if you're trying to get it to wrap around from 0 to 93 then maybe something like this
 
   _P1_U_D = _P1_U_D - _robotspeed
   if player1y > 93 then player1y = player1y + 93

Edited by bogax, Sat Mar 10, 2018 11:35 AM.


#8 Lillapojkenpćön OFFLINE  

Lillapojkenpćön

    Star Raider

  • 93 posts

Posted Sat Mar 10, 2018 12:23 PM

It's doing what it should do  :) I was just wondering how you're using the same variable in your 8.8 type x & y variables

 

   dim     p1x = player1x.w
   dim     p1y = player1y.w
 
Just w while I have to use both v & w
 
   dim _P1_L_R = player1x.v
   dim _P1_U_D = player1y.w 
 
So I'm wondering if I could also use just one variable in some way? Just making shure I'm not currently wasting nine variables if I don't have to?


#9 bogax OFFLINE  

bogax

    Dragonstomper

  • Topic Starter
  • 776 posts

Posted Sat Mar 10, 2018 4:33 PM

 

It's doing what it should do  :) I was just wondering how you're using the same variable in your 8.8 type x & y variables

 

   dim     p1x = player1x.w
   dim     p1y = player1y.w
 
Just w while I have to use both v & w
 
   dim _P1_L_R = player1x.v
   dim _P1_U_D = player1y.w 
 
So I'm wondering if I could also use just one variable in some way? Just making shure I'm not currently wasting nine variables if I don't have to?

 

 

it only uses the fractional part in one direction at a time

 

if the angle is less than 45 or greater than 135  the x direction is whole integer and the y is fractional

other wise y is integers and x is fractional


Edited by bogax, Sat Mar 10, 2018 8:42 PM.





0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users