-
-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regression: Sprite issue with vertical maps #255
Comments
Please see animated showing moving up and down. Only the middle goomba should be there, the others are ghosts. Attached is also code and sfc file. |
This behavior is normal on the Snes, take a look in the sprite viewer in Mesen when you moving vertically oambuffer[sprnum].oamx = (*goombaox) - x_pos; // that was easy for X
s16 posY = (*goombaoy) - y_pos; //define posY on top of your c file, not method local like here
if (posY > -16 && posY < 240) // play around with these values, in my case it works with a sprite size of 16
{
oambuffer[sprnum].oamy = posY; // if posY is in range it will draw
}
else
{
oambuffer[sprnum].oamy = 240; // otherwise draw the sprite it out of screen
}
oamDynamic16Draw(sprnum); |
Yes, but this was previously handled by the map engine. |
that's correct, it was handle previously but the code was not correct. Is it possible to have your source code to check how you add your objects in the map? |
This was fixed in earlier 4.x dev branch, but now with 4.1 it is broken again.
When on a vertical map, if you move up or down on the map, then any sprites that scroll off the map, suddenly appear on the opposite side. So, if you move up, any sprites that go off bottom of map, appear at top. If you move down, any sprites that go off top of map, appear at bottom.
Previously this was fixed with sprite refresh settings, but this fix no longer works.
The text was updated successfully, but these errors were encountered: