exelotl / natu

Toolkit for writing Game Boy Advance games in Nim
https://natu.exelo.tl
Other
224 stars 6 forks source link

Move Sprite Demo not working #6

Closed Runkunkun closed 2 years ago

Runkunkun commented 2 years ago

Hello I did set up everything according to the description on my Mac. When i build in the move sprite folder and load the rom afterwards with mGBA the spaceships shows up on screen but it doesnt move. Other roms work just fine.

exelotl commented 2 years ago

Hi! When abouts did you install Natu? There was an issue last week where all the examples would hang on VBlankIntrWait() because I forgot to initialise the global interrupt handler, but this was fixed in commit https://github.com/exelotl/natu/commit/149bf84c59b15d3592a49771dae9e53f96a38b49.

I just tried the move_sprite example on my machine (Manjaro Linux) and it seems to work fine, I can move the ship with the d-pad / arrow keys.

exelotl commented 2 years ago

@Runkunkun If you're on the latest commit of Natu and it's still giving you trouble, please zip up the whole move_sprite directory (including the generated nimcache folder) and upload it here, that should give me enough info to see what's going wrong.

Runkunkun commented 2 years ago

move_sprite.zip

@exelotl thanks for the help. I am on the newest commit on the devel branch now.

exelotl commented 2 years ago

Hmm, it seems that irq.init() is indeed not being called. Try reinstalling and doing a clean build?

cd path/to/natu
nimble install
cd examples/move_sprite
nim clean
nim build
Runkunkun commented 2 years ago

Reinstalling and doing a clean build was the secret sauce. Thanks a lot for the help, I am still new to nim.

exelotl commented 2 years ago

Sweet! Glad it was something simple at least ^^

If you're looking for a bigger example that makes use of the asset system (rather than using preconverted asm files for graphics), you might want to take a look at xniq

Apologies for the lack of docs, I'm slowly working on it but it'll take a bit longer :sweat_smile:

Runkunkun commented 2 years ago

I will have a look. Undoubtly cool project you are putting here together and very welcoming aswell 🦕