Jump to content
IGNORED

Two-line kernel and sprite motion weirdness


Luigi301

Recommended Posts

I'm trying to convert my program's one-line kernel into a two-line kernel. It works perfectly with the one-line kernel, but I can't get it to work with a two-line kernel. The problem is, something's broken somewhere and I can't figure out what.

 

In theory, each time a sprite is drawn on the line, its position (SpriteYPosition) is shifted down one line so it can be drawn on the next line. At the beginning of the next frame, it's shifted back up the number of scanlines it was shifted down.

 

In this converted kernel, it goes up with no joystick movement no matter what I set the sprite's height to in the repositioning code. Worse, no matter if I press up or down, it speeds up going up. This is probably related to my hacky collision detection code.

 

Can someone help me get my sprites to stop moving on their own?

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