Posted: Tue Dec 20, 2011 7:41 am
Could you help with the paddlewidth
you mentioned?
(and paddleheight and left and right)
Lets take 1 step back first.
I made 2 moving balls what did i use for that..
-variables : ballx and bally
-initial ball stats : lda #$30 sta ballx and lda #$40 sta bally
-update sprites :lda sta the Y,sprite,attribute,X
-update ball sprite: for the controls
So i thought ..
how do i get paddlewidth to start with the checks you mentioned.
so i looked here on the forum and google and i saw most people use these variables.
-top
-down
-left
-right
So i thought where are the x and y ? seems that
left=x and y = top
right = x + width
down = y + height
MY QUESTION :
1. How do i get the the width and the height?
and
2. how do i put it in my code?
My incomplete awnser and guesing..
1.width is x +other tiles / height is y+ other tiles,for exsample a pong paddle of 4 tiles is the y +the other 3.
2. how to put in code
variables = well.. left right top bottum .rs 1
initial ball stats= uhm.. left is x and top is y,but what about the right side of the ball and the bottum? Can this be the same also #$30 and 40 like my exsample? and if ther more pixels the would be a multiple lda #$ followed by sta ballright?
update sprites= well this gets confusing i gues multiple loadoing lda?
(and paddleheight and left and right)
Lets take 1 step back first.
I made 2 moving balls what did i use for that..
-variables : ballx and bally
-initial ball stats : lda #$30 sta ballx and lda #$40 sta bally
-update sprites :lda sta the Y,sprite,attribute,X
-update ball sprite: for the controls
So i thought ..
so i looked here on the forum and google and i saw most people use these variables.
-top
-down
-left
-right
So i thought where are the x and y ? seems that
left=x and y = top
right = x + width
down = y + height
MY QUESTION :
1. How do i get the the width and the height?
and
2. how do i put it in my code?
My incomplete awnser and guesing..
1.width is x +other tiles / height is y+ other tiles,for exsample a pong paddle of 4 tiles is the y +the other 3.
2. how to put in code
variables = well.. left right top bottum .rs 1
initial ball stats= uhm.. left is x and top is y,but what about the right side of the ball and the bottum? Can this be the same also #$30 and 40 like my exsample? and if ther more pixels the would be a multiple lda #$ followed by sta ballright?
update sprites= well this gets confusing i gues multiple loadoing lda?
