-
Notifications
You must be signed in to change notification settings - Fork 40
Getting Started
This document guides you through building and running the Nine Chronicles launcher (a.k.a. 9c-launcher) with the game on your own computer from scratch. Following this guide, you can play NineChronicles with a launcher connected to the mainnet that works like the released launcher. We hope you can easily start participating and/or contributing to Nine Chronicles from here.
- Windows 10 or 11 is recommended.
- Linux/macOS also works, but the compatibility is not guaranteed.
Due to the usage of symbolic links and submodules, you need to use some flags when cloning. In case if you forgot to do so, follow the guides in the Troubleshooting section.
git clone https://github.com/planetarium/9c-launcher
cd 9c-launcher
git switch main # In case you're contributing, skip this
git pull
yarn
yarn lefthook install # installs git hook for contributing, feel free to skip
yarn
yarn codegen # This generates GraphQL API codes for Apollo and etc.
yarn release
The launcher needs a configuration to tell the headless to which chain to use and how to set up and communicate with the desired chain. You can easily do this when if you're connecting to the mainnet.
yarn download-config
or
curl https://release.nine-chronicles.com/9c-launcher-config.json -o dist/config.json
yarn codegen
yarn dev
# Press `Ctrl + C` on terminal to shut down the launcher
# This is IMPORTANT, causing launcher restart from UI while on yarn dev
# would cause orphaned electron process without main process, which
# you need to find and kill process specifically otherwise next yarn dev will not work.
-
yarn download-config
- Downloads the latest configuration of the mainnet, which allows you to use it just like a released launcher.
-
yarn codegen
- Generates graphQL code from defined schema.
That's it! Enjoy the game with your own launcher! 🎮
Note In case you're using your customized source code or running under unsupported platform, this may not work but you can run the launcher itself.
If you close the launcher on your taskbar, not terminal, this could happen when you run yarn dev
again.
- Open the Task Manager. - You can open it by pressing Ctrl + Shift + Esc.
- See details in
Process
tab, you can find the livingElectron
app. - If you see an instance of 'Nine Chronicles' they need to be terminated as well. - Manually kill those living processes.
- The
yarn dev
should work now. - To prevent this, we recommend terminating the launcher with Ctrl + C.