This is a monorepo. For a specific project setup/config, check those project subfolders (for example, the server
needs a .env
setup before it will run.).
You can either use Docker, or you can use your own installed Node / Mongo / Redis (or, of course, a hosted Mongo / Redis). If you're installing Node, it should be at least version 14.
- Assets - home of bgm, macicons, sfx, and spritesheets (frontend content)
- Content - home of droptables, items, maps, npc stats, npc scripts, quests, recipes, and spawners (backend content)
Just run docker-compose up
and it will build, run, and start the client and server (as well as Mongo and Redis).
You will want to be using Node 16.12 (at least) to run this project.
npm install
- set up the monoreponpm run setup:full
- setup both the client and server for development (See "Developing Content" for some advice on running the same instance of the Content folder for client and server).
Check this wiki page.
One option you have to run Land of the Rair and actively work on the content, is to clone the Content repo right alongside Land of the Rair (meaning you'll have folder/LandOfTheRair
and folder/Content
). If you have the Content repo available and run npm run setup
, it will symlink the Content repo so you can develop it concurrently without having to commit, push, pull, and update. Or copying, or whatever.
The content will need to be rebuilt when it changes. You can either run npm run content:build
to do it when needed, or npm run content:watch
to watch for changes.
To commit content, you'll still need to go to that folder manually and commit, since it is a separate repository. The helpers above are added for convenience.
Running this sets up the environment entirely, with a symlinked content directory for editing / committing.
git clone https://github.com/LandOfTheRair/LandOfTheRair.git
git clone https://github.com/LandOfTheRair/Content.git
touch LandOfTheRair/.env
cd LandOfTheRair
npm install
npm run setup:full
You'll still need to edit your .env
, and do other project-specific setup - see here for server setup. The client should work after running the above.
Run npm start
and the client and server will both start up.
You can also do npm run start:server
and npm run start:client
to start the two separately.