A simple Sonolus custom server to demonstrate usage of sonolus-express.
This custom server contains features:
- A fully functional Sonolus custom server that Sonolus app can connect to and play.
- Contains sonolus-bandori-engine and other items.
- Allows users to upload levels (by opening server link in browser) and play them.
This custom server demonstrates the following concepts that are commonly used in making Sonolus custom servers:
- Setting up sonolus-express to handler Sonolus custom server routes.
- Loading static items packed by sonolus-pack.
- Dynamically adding new items (third party package and user uploads).
Additional notes:
- This custom server is NOT production ready, it is meant as a demo.
- All repository resources are not kept in memory.
- All item info are kept in memory (
sonolus.db
), which allows sonolus-express default handlers to do their jobs automatically. - Keeping all item info in memory has non-negligible memory usage cost, and is meant for small to medium scale servers. For large scale servers that requires indefinite scaling, see sonolus-express-demo-dynamic.
npm run build
After building, navigate to dist
and:
node index.js