Jump to content
IGNORED

vertical sprite positioning issue at leftmost screen positions


Recommended Posts

Hello,

 

I'm desperate, I attached a stripped-down 2-scanline kernal, that shows a

phenomenon I don't understand.

 

Here is a little run-down, of what the kernal does:

 

- In the first scanline the playfield gets drawn as well as sprite GRP1 (only

to trigger GRP0, see below).

- In the second scanline the playfield gets disabled and Sprite GRP0 gets

drawn.

- In order to position Sprite GRP0 vertically accurate I use the VDELP0

register.

 

By and large this works fairly well, except for the leftmost side of the

screen. The attached kernal shows a sprite at a neuralgic position. The left

side of the sprite is messed up, whereas the right side gets drawn correctly.

 

Can anybody explain to me, why accurate vertical positioning at the leftmost

side of the screen does not work? Or am I doing something wrong?

 

kind regards, Jan

stripdown.asm.txt

post-26871-128035644738_thumb.gif

Link to comment
Share on other sites

Looks to me like you are taking too long to store into GRP0:

 

  sta   WSYNC          
  stx   PF2			;3
  lda   #0				;2
  cpy   heroY			;3
  bcs   .skipDrawHero		;2
  lda   (heroSpritePtr,x)	;6
  beq   .skipDrawHero		;2
  inc   heroSpritePtr		;5
.skipDrawHero		
  sta   GRP0			;3 - 26 total (should be less than 68/3)

 

Try moving a little work above the WSYNC.

  • Like 1
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...