@inglorious/engine 24.2.2 → 24.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +9 -2
  2. package/package.json +3 -3
package/README.md CHANGED
@@ -16,6 +16,14 @@ pnpm create @inglorious/game
16
16
 
17
17
  This sets up a small playable game with a development server and tests, and can make it an installable PWA or an Android and iOS app with Capacitor.
18
18
 
19
+ To add the engine to an existing project, install the store with it:
20
+
21
+ ```bash
22
+ pnpm add @inglorious/engine @inglorious/store @inglorious/renderer-2d
23
+ ```
24
+
25
+ The engine creates the store for you, but the store is your game's: it is a peer dependency, so the engine and your code (`fsm`, `scenes`, `patch`) share one copy.
26
+
19
27
  ## Features
20
28
 
21
29
  - **Functional & Data-Oriented**: Uses a single, immutable state object as the source of truth, inspired by functional programming principles.
@@ -426,9 +434,8 @@ Because building things is fun! This project is as much an exploration of softwa
426
434
 
427
435
  The core engine relies on a few key, lightweight packages:
428
436
 
429
- - [mutative](https://www.npmjs.com/package/mutative): For enabling ergonomic immutable updates with structural sharing.
430
437
  - [@inglorious/utils](https://www.npmjs.com/package/@inglorious/utils): A collection of small, pure utility functions for things like vector math and data manipulation.
431
- - [@inglorious/store](https://www.npmjs.com/package/@inglorious/store): The environment-agnostic core state management library.
438
+ - [@inglorious/store](https://www.npmjs.com/package/@inglorious/store) (peer dependency, install it yourself): The environment-agnostic core state management library, which uses [mutative](https://www.npmjs.com/package/mutative) for ergonomic immutable updates with structural sharing.
432
439
 
433
440
  ## Quick Start Example
434
441
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inglorious/engine",
3
- "version": "24.2.2",
3
+ "version": "24.3.0",
4
4
  "description": "A JavaScript game engine written with global state, immutability, and pure functions in mind. Have fun(ctional programming) with it!",
5
5
  "author": "Matteo Antony Mistretta <antony.mistretta@gmail.com> (https://ingloriouscoderz.it)",
6
6
  "license": "MIT",
@@ -41,10 +41,10 @@
41
41
  },
42
42
  "sideEffects": false,
43
43
  "dependencies": {
44
- "@inglorious/store": "^12.9.4",
45
- "@inglorious/utils": "^5.4.4"
44
+ "@inglorious/utils": "^5.5.0"
46
45
  },
47
46
  "peerDependencies": {
47
+ "@inglorious/store": "^12.9.5",
48
48
  "vitest": "^5.1.1"
49
49
  },
50
50
  "devDependencies": {