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

[SB4] GRP and SPSET issues.

Root / Programming Questions / [.]

CharredCheeseCreated:
Hello everyone. I am trying to use a custom sprite that I made (saved as "GRP:SPRITE". I would like to use the image that I made as a sprite in my game. My code is attached.

Here is what the end result looks like. Just to clarify, I would like the strawberry to instead be the smiley face that I drew in my graphics page.

Looks like I'm stupid because I forgot to add the images. Sorry for the post spam, mods.

This looks like SB3 on a 3DS emulator, not SB4. Anyway, you have to load the sprite file.
LOAD "GRP4:SPRITE",#FALSE
GRP4: is the graphic page the sprite sheet is normally on. Make sure you're saving and loading from the right one!

Yeah, just for future reference, SB4 is the Switch version of SmileBASIC, which has only been released in Japan so far.

Oh yeah, I somehow mistook an image from a tutorial I was watching with this. Here's the actual image; I honestly have no idea why I thought that was the correct image. My apologies for the confusion. Also yeah I used a Japanese NS account to get SB4, not the 3DS one. If it would help, I can transcribe the code to text on this site.

LOADG "GRP:SPRITE",0
This loads your SPRITE file into graphics page 0, but by default sprites use graphics page 4. In other words, you should change the 0 to a 4.

Ah, gotcha. Thanks a ton! Works like a charm!