A web application to help you find and create custom creatures and NPCs for the 5th edition of the world's greatest role playing game.
The best way to bring an issue to light is by submitting an issue right here on Github. If you wish to, however, you can also contact me directly at haswellrd@gmail.com.
Any help on the project is much appreciated. The goal is for CritterDB to be reliable, easy to use, and feature-rich, and that will be best achieved with the help of all the strong developers in the role playing community.
If do you want to help out with CritterDB, getting started is easy. The site runs on NodeJS with Angular 1 on the front end and a Mongo database. Angular Material is used as a UI framework for the front end. CritterDB uses npm to manage back-end packages, and grunt to handle pre-deployment tasks such as code minification and compilation. Use the following instructions to set up a local development environment for CritterDB:
Clone the code from Github.
CritterDB uses npm to manage its back-end dependencies. Navigate to the CritterDB/server/ folder on the command line, then execute the following command:
Settings and configuration for npm can be found in 'package.json'.
CritterDB has a config file which manages several values that must be set before you can run CritterDB. This file is not stored in git as it varies based on dev or deployment environment. Navigate to the 'server' folder within the CritterDB project. Copy 'sampleconfig.js' and name the new file 'config.js'.
Now, open config.js and edit the fields to something that is appropriate for your development environment.
And that's it! The most important thing is making sure that the databaseUrl points to your database. Sample image shown below:
CritterDB uses Grunt to perform code minification, obfuscation, and any other tasks that must be performed for the code to be ready for production. Grunt should also be used when developing code to simulate the production environment as closely as possible. Grunt scripts are stored in 'gruntfile.js'.
When first setting up the CritterDB code, you should run Grunt once. Navigate to the 'server' folder on the command line and run the following command to use Grunt to compile the code:
Grunt needs to be run every time the code changes. When you are developing the server you should run 'grunt watch' from the 'server' folder in a command line. This will constantly watch the directory for changes and recompile as needed so that you don't have to re-run grunt every time you want to test anything.
Now you're ready to run the server! Navigate to the 'server' folder on the command line and run the following command:
The server should start up and tell you it's running on port 3000. Now you can navigate to 'localhost:3000' in your browser and you should see CritterDB. You will need to restart the server anytime you change back-end code by stopping and re-running 'node server.js'.
CritterDB also has a simple health monitor server which periodically pings the CritterDB server and will set off alarms if the production server is unhealthy for several health checks in a row. It can be configured to take automated corrective action (such as trying to restart the CritterDB server repeatedly for a certain number of attempts), and can also send out alerts that the server is down.
This project is contained in the healthMonitorServer folder. To run it you will need to create a 'config.js' file by copying the 'sampleconfig.js' file and editing the values as needed. The program itself is small and should be pretty self explanatory.
You can get in touch with me at haswellrd@gmail.com.