-
Notifications
You must be signed in to change notification settings - Fork 9
Building From Source
-
A development environment that supports .NET 8.
- On Windows, Visual Studio Community is recommended. Choose C# and .NET development during installation.
- On Linux and macOS, install the .NET SDK (see instructions below).
-
(Optional, Windows only) The Visual Studio Installer Projects Extension if you want to build the installer. If you don't download it you might get some warnings about the setup project, but it is not necessary to just run the randomizer.
-
(Optional) A Git client. Recommended for easier updating, but you can also download a
.zipfrom GitHub.
You can either:
-
Click the green Code button on GitHub → Download ZIP, or
-
Clone via Git:
git clone --recursive https://github.com/Ellendar/Z2Randomizer.git cd Z2Randomizer git checkout 4.4 # switch to the tag/branch you want to build
- Open the solution:
Z2Randomizer.sln - From the dropdown near the green play button, select the project you want to build:
-
CrossPlatformUI.Desktop(for the Desktop GUI).
-
- (Optional) From the dropdown that says Debug, switch to Release for a more optimized build.
- Press the green play button to build and run.
-
Ubuntu/Debian
sudo apt-get install dotnet-sdk-8.0
-
Gentoo (as root)
emerge --ask =dev-dotnet/dotnet-sdk-bin-8.0.108
-
Fedora
sudo dnf install dotnet-sdk-8.0
-
Mac: Download .NET 8.0 macOS x64 Installer or .NET 8.0 macOS ARM Installer.
From inside the Z2Randomizer folder:
dotnet workload restore
dotnet restoreNote: It’s expected that the
Setup1project may fail. This does not affect building or running the randomizer.
dotnet build CrossPlatformUI.Desktop --configuration ReleaseThe executable Z2Randomizer will be created in CrossPlatformUI.Desktop/bin/Release/net8.0.
Run with:
./CrossPlatformUI.Desktop/bin/Release/net8.0/Z2Randomizer &dotnet build CommandLine --configuration ReleaseThe executable Z2R will be created in CommandLine/bin/Release/net8.0.
Example usage:
cd CommandLine/bin/Release/net8.0
./Z2R -r /path/to/Zelda2.nes \
-f RAAA2dJALw3MXoaJCKTLPeo++OwsL63s1ADhAAsBAA \
-s 12345678The randomized ROM will be created in the same folder as the input ROM. The filename will be shown when the generation has finished.
You can also use JSON config files to determine randomizer settings.
Copy the sample config:
cp ../../../Sample.json ./Sample.json(You may move this config file anywhere convenient.)
Run the randomizer with a config:
./Z2R -r /path/to/Zelda2.nes \
-c ./Sample.json \
-s 12345678