| |
Parody
Registered: Jul 2013 Posts: 7 |
Leftmost sprite position and opening borders
I just noticed that x=0 for a sprite doesn't cover the "start" of the left side border, Is there any way to achieve this? |
|
... 37 posts hidden. Click here to view all posts.... |
| |
Flavioweb
Registered: Nov 2011 Posts: 463 |
Ok, first of all... thanks for your replies, then i hope to be able to write some code regarding this...
Then... there is another "little strange thing" that goes around in my mind.
In the vic article, the "internal x coord register" was described as a 9 bits counter.
How can count more than 512 x positions with just 9 bits?
I'm thinking about also to sprite collision detection or lightpen matches in the "area" 513-520 "dots"...
How can vic know "where" is between this range? |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
I suspect it's 9 bits, but uses an extra flip-flop to alternate between resetting to $180 or not when reaching $188. Just shooting from the hips though :) |
| |
Flavioweb
Registered: Nov 2011 Posts: 463 |
This "flip-flop" seems to "freeze" the counter instead of resetting it... but looks like a strange and too complex solution to me... |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Which solution that is easier (and just needs a few gates) would you propose, then? And don't say anything about fractional counters :) |
| |
Flavioweb
Registered: Nov 2011 Posts: 463 |
I don't have a solution... more simple o more complex, but if xpos is the same for sprites and lightpen, and we have the same value of xpos for 1 cycle = 8 pixels, how can vic detect a sprite collision correctly in this range of dots? |
| |
tlr
Registered: Sep 2003 Posts: 1790 |
Collisions are not directly related to xpos. Collisions occur when data shifted out from the sprite shift registers fulfill a collision condition. Xpos is only used to trigger the sprite.
I don't believe the value of xpos stays the same. It seems like 0x180-0x187 repeats twice like I stated earlier. |
| |
Flavioweb
Registered: Nov 2011 Posts: 463 |
"Trigger" a sprite mean "set" where it appears?
If so, in NTSC, where would appear 2 sprites with coord $184 and $187?
{ Phi1(62), 0x184, None, SprDma1(1), BaSpr3(1, 2, 3), None },
{ Phi2(62), 0x184, None, SprDma2(1), BaSpr3(1, 2, 3), None },
{ Phi1(63), 0x184, None, SprPtr(2), BaSpr2(2, 3), None
...here we have 6 possible positions between 12 "dots"... |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
LOL at those fractions |
| |
tlr
Registered: Sep 2003 Posts: 1790 |
@flavioweb: it can be shown that a sprite can only trigger once per line so there will a gap instead of two triggers.
Perhaps if you are really sneaky you could change xpos on the fly so it gets set to $0180-$0187 exactly at the cycle where the repeat occurs? Then it should be triggered 8 pixels later which is way nerdy cool. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
i demand a test program :) |
Previous - 1 | 2 | 3 | 4 | 5 - Next |