Jump to content
IGNORED

falling sky


bogax

Recommended Posts

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

falling_sky_03_5_1.bas

falling_sky_03_5_1.bas.bin

Edited by bogax
  • Like 4
Link to comment
Share on other sites

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
Link to comment
Share on other sites

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
Link to comment
Share on other sites

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
Link to comment
Share on other sites

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?
Link to comment
Share on other sites

 

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
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...