From c56dfd20c4e2cf3929c9265a02bfd0fb1c2dba46 Mon Sep 17 00:00:00 2001 From: Brady Mauermann-Peterson Date: Thu, 15 Feb 2024 09:52:19 -0800 Subject: [PATCH] Update README.md --- README.md | 89 +++++++++++-------------------------------------------- 1 file changed, 18 insertions(+), 71 deletions(-) diff --git a/README.md b/README.md index 4c3a76d..3ab5d15 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,6 @@ -# rot.js TypeScript basics +# Sim World -A basic roguelike example built with rot.js and TypeScript. Playable at [https://mizar999.github.io/rotjs-typescript-basics/](https://mizar999.github.io/rotjs-typescript-basics/) - -## Resources - -- [rot.js - Roguelike Toolkit](https://github.com/ondras/rot.js) -- [RogueBasin - rot.js Tutorial](http://www.roguebasin.roguelikedevelopment.org/index.php?title=Rot.js_tutorial) -- [Frostlike - 7 Day Roguelike Challenge 2017 entry](https://github.com/maqqr/7drl2017) +A prototype of a colony management game, in which the environment (plants, climate, weather) is deeply simulated. The entities living in this world will be powered by the latest LLM AI, and will populate, build, and maintain the environment over many generations. ## How to run @@ -15,15 +9,26 @@ After cloning the repository: - Install necessary packages ```powershell - npm install + npm ci + ``` + +- To build the assets, run: + ```powershell + npm run build:assets ``` -- To build the application run: +- To build the application, run: ```powershell npm run build ``` + - To run the application using the dev server, run: + + ```powershell + npm run dev + ``` + - To run multiple npm scripts cross platform in parallel run the following command: ```powershell @@ -34,66 +39,6 @@ After cloning the repository: npx concurrently npm:watch npm:serve ``` -## Initial Project setup - -If you're interested here is my initial project setup: - -- Init npm and install necessary packages - - ```powershell - npm init -y - npm install --save-dev typescript@4.6.4 ts-loader@9.3.0 rot-js@2.0.3 webpack@5.72.1 webpack-cli@4.9.2 http-server@14.1.0 concurrently@7.2.1 - ``` - -- Create **Webpack** configuration `webpack.config.js`: - - ```javascript - const path = require("path"); - - module.exports = { - entry: "./src/app.ts", - module: { - rules: [ - { - test: /\.tsx?$/, - use: "ts-loader", - exclude: /node_modules/, - }, - ], - }, - resolve: { - extensions: [".ts", ".tsx", ".js"], - }, - output: { - filename: "app.js", - path: path.resolve(__dirname, "dist"), - }, - mode: "development", - }; - ``` - -- Webpack will get the sources from `src/app.ts` and collect everything in `dist/app.js` file -- Create **TypeScript** configuration `tsconfig.json`: - - ```json - { - "compilerOptions": { - "target": "es5" - }, - "include": ["src/*"] - } - ``` - -- Update the **scripts**-section of the `package.json` file: - - ```json - "scripts": { - "build": "webpack", - "watch": "webpack --watch", - "serve": "http-server --port=8085 -c-1" - } - ``` - ## Development Guide This project uses rot.js as the game framework, and pixijs for rendering and handling sprites. @@ -105,4 +50,6 @@ This project uses rot.js as the game framework, and pixijs for rendering and han npm run build:assets ``` -Find the rebuilt sprite sheets in public/assets +Find the rebuilt sprite sheets in public/sprites. + +