Skip to content
Toolkit for writing Game Boy Advance games in Nim
Nim
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples
natu Custom `=` operators so ObjAttr and ObjAffine don't clobber each other. Feb 13, 2020
.gitignore
LICENSE
natu.nim
natu.nimble
readme.md

readme.md

Natu GBA Logo

Natu is a package for making Game Boy Advance games in Nim.

Primarily a wrapper for libtonc, we are now growing in our own direction: ditching some old conventions to be more Nim-friendly, and adding more libraries.

Features

  • Full GBA memory map + flag definitions
  • BIOS routines
  • Interrupt manager
  • A powerful text system (TTE)
  • Surfaces (draw to tiles like a canvas)
  • Efficient copy routines
  • Sin/Cos/Div LUTs + other math functions
  • Fixed-point numbers, 2D vector types
  • Random number generator
  • Hardware sprites, affine matrix helpers
  • Color/palette utilities
  • Button states (hit, down, released)
  • mGBA logging functions
  • Maxmod bindings for music/sfx

Usage

You will need devkitARM with GBA tools and libraries. If you are using the graphical installer, simply check "tools for GBA development" during setup. Otherwise be sure to install the gba-dev group of packages. Either way, the libtonc package is included so you should be good to go!

Before diving into Nim, try building some of the Tonc 'advanced' demos to make sure your environment is good.

The examples in this repo each use a nimscript configuration which should make a good starting point for any project. From within an example you can run nim build in the terminal to produce a GBA rom.

Happy coding! And if you need any help you can reach me (@exelotl) on the gbdev discord.

Thanks

tonc + libtonc by cearn
devkitARM toolchain maintained by wintermute
maxmod sound system by mukunda johnson
mGBA by endrift
gba logo by iamrifki
font: gelatin mono by loren schmidt

Natu

You can’t perform that action at this time.