LoginLogin
Nintendo shutting down 3DS + Wii U online services, see our post

How do you flip sprites?

Root / Programming Questions / [.]

GuzzlerCreated:
I only even need to flip them horizontally for now.

Apologies, but I have no experience with sprites.

:(

I'm making a racing game.

That would be cool. Maybe look at others code as examples?

What code? I mean, where do I even start to see where other people have flipped sprites?

Ummm I dunno. I have a poor solution though... maybe just make another sprite thats the original one just flipped, and when you need to flip it then just switch sprites... maybe

I guess... Though I don't want to have an entire file in my final download just for sprites.

I guess... well I'm stumped. Hopefully someone else will come across this forum and provide some help.

You could use SPDEF definition_number, U, V, Sprite_With, Sprite_Height, #SPREVH if you want the reversed the image used by the sprite and SPDEF definition_number, U, V, Sprite_With, Sprite_Height, 0 to define the image without horizontal reverse. However, you need to do this each time you flip your sprite for each image used by it. The other way is to define the normal and the flipped image on different definition number. Edit: U,V are the coordinates (X,Y) where the sprite begin in GPR4:

Sweet. Thanks.

Wait, what do you mean "U" and "V"?

Also, I'm trying to display two of these sprites.

K thanks.

*Sigh* Look at the complete description of SPCHR, your answer is in the value that goes at the end.

*Sigh* Look at the complete description of SPCHR, your answer is in the value that goes at the end.
I didn't get to see your comment yesterday because I was in bed. Though, I'm not actually constantly flipping the sprites or anything. I just used it to make a title screen graphic. Thank you for your help though.