A huge upgrade to the battle engine in HeartGold
This repository and its assets are a community endeavor. By its nature, using it and subsequently profiting off of it is profiting on the backs of all of our work, all of which is intended to be used to further hobbies and for everyone to have fun. You have my blessing to use code and assets from this repository as you please as long as there is no money involved, including optional donations through whichever platform to play your hack. The creations that stem from this repository must be freely accessible and not hidden at all behind any paywall, including those that prompt the player to pay optionally (Ko-Fi's style comes to mind here). The Credits should also be replicated in your hack's repository and/or the post to your hack--we all sit on the shoulders of giants here.
A more comprehensive list of features + a roadmap can be found by visiting the hg-engine wiki. Please read this README and the Wiki thoroughly before asking questions.
sudo apt-get install libpng-dev build-essential cmake python3-pip git automake autoconf gcc-arm-none-eabi
pip3 install ndspy
mono
is not preinstalled (Ubuntu-based ones come to mind), install it with sudo apt-get install mono-devel
brew
by running the following in Terminal: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
xcode-select --install
brew install python3 libpng automake autoconf cmake zlib pkg-config
brew install --cask gcc-arm-embedded
python3 -m pip install ndspy
export PKG_CONFIG_PATH=$(brew --prefix zlib)/lib/pkgconfig
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all
Windows key
and R
at the same time, then type in wsl
and press Enter. This is how you should open WSL from now on.
wsl
to open WSL at the file explorer.sudo apt update
, and after it finishes processing, type in sudo apt upgrade
. This will take quite a while, so find something else to do in the meantime. These two commands together will update all of the packages that came pre-installed with Ubuntu.
sudo apt-get install build-essential git libpng-dev gdebi-core python3 python3-pip cmake automake autoconf mono-devel gcc-arm-none-eabi
pip3 install ndspy
pacman -Syu
pacman -S gcc base-devel cmake python git automake autoconf mingw-w64-x86_64-mono mingw-w64-x86_64-arm-none-eabi-gcc p7zip zlib-devel
export PATH=$PATH:/mingw64/bin
echo export PATH='$'PATH:/mingw64/bin >> ~/.bashrc
python3 -m ensurepip --upgrade
python3 -m pip install ndspy
./configure --prefix=/usr
make check
make install
mkdir -p ~/git && cd ~/git
git clone --recursive https://github.com/BluRosie/hg-engine.git
If you are using Docker, there is no need for complicated setup or anything. You just have to clone the git repository:
mkdir -p ~/git && cd ~/git
git clone --recursive https://github.com/BluRosie/hg-engine.git
cd hg-engine
Docker handles all of the setup for you with relative replicability across platforms. This abstracts a bit of it away from the user and is slightly slower, but such is the price of simplicity.
To set up for the first time, all that needs to be run is:
docker build . -t hg-engine
To build, you can then run a simple shell script to build the test.nds
:
./docker-makerom.cmd
This script is written in such a way that it works on every platform (including from cmd
on Windows).
There is no need to continue to Build Instructions for anything. Docker handles it all for you.
You will still have to make clean
and make clean_code
manually when changing code or other things that won't build for some reason. But this makes setup really convenient.
~/git/hg-engine
.
explorer.exe .
from the WSL terminal. This will open the File Explorer to the folder where hg-engine is located.
Linux\Ubuntu\home\[USERNAME]\git\hg-engine
.C:\msys64\home\[USERNAME]\git\hg-engine
directory.make
. It will start with building all the tools necessary, then move to the code, then the rest of the files in the folders.
make
is initially very slow. It can be sped up by specifying a certain amount of threads through the -j#
flag, where # is a number. The ideal amount of threads is typically the number that is given from nproc
--so my make
command, with nproc
giving me 8
, is typically make -j8
.libpng
linker issues caused by an expected architecture mismatch. You can get around this issue by going to Applications/Utilities/
, right clicking on Terminal, Clicking "Get Info", and clicking the "Open using Rosetta" checkbox so it becomes blue. Close Terminal if you had it open, then open it again and run the following:
cd ~/git/hg-engine
make tools/nitrogfx
make tools/ENCODE_IMG
hg-engine
folder named test.nds.
armips/data
.