incanto 0.49.0 → 0.50.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 (30) hide show
  1. package/bin/incanto-play.mjs +42 -17
  2. package/dist/2d.js +2 -2
  3. package/dist/3d.js +4 -4
  4. package/dist/{create-game-BgV6UbVA.js → create-game-BLDjy_PW.js} +2 -2
  5. package/dist/{create-game-DFBjMetZ.js → create-game-DqqxEax1.js} +3 -3
  6. package/dist/{environment-presets-CZOH5TY5.js → environment-presets-XFuqu5jv.js} +1 -1
  7. package/dist/{gameplay-02Btmmjn.js → gameplay-DbaI313d.js} +16 -2
  8. package/dist/gameplay.js +1 -1
  9. package/dist/index.d.ts +1 -1
  10. package/dist/index.js +2 -2
  11. package/dist/{physics-2d-vyCBfACH.js → physics-2d-_9VBOHn6.js} +1 -1
  12. package/dist/{physics-3d-DpRqw8Mz.js → physics-3d-DrpF5hcG.js} +7 -7
  13. package/dist/react.js +1 -1
  14. package/dist/{replay-CAphXMyM.d.ts → replay-DYdy1wb0.d.ts} +5 -1
  15. package/dist/{replay-C0XJIsO7.js → replay-j-m6lJ4W.js} +22 -2
  16. package/dist/{src-DF4gCsqO.js → src-B3HrKuAi.js} +1 -1
  17. package/dist/{test-DRna_BQU.js → test-D16igj4C.js} +44 -17
  18. package/dist/test.d.ts +1 -1
  19. package/dist/test.js +2 -2
  20. package/dist/vite.js +2 -2
  21. package/editor/assets/{agent8-DCW4TgDt.js → agent8-t3kl5q9K.js} +1 -1
  22. package/editor/assets/{debug-RC6qts6S.js → debug-Bu3eeAlO.js} +1 -1
  23. package/editor/assets/{index-5dEIhvsf.js → index-Df5g8ofT.js} +51 -51
  24. package/editor/index.html +1 -1
  25. package/package.json +1 -1
  26. package/skills/incanto-gameplay-behaviors.md +11 -0
  27. package/skills/incanto-playtesting.md +13 -2
  28. package/templates-app/beacon-isle-3d/package.json +1 -1
  29. package/templates-app/tps-3d/package.json +1 -1
  30. package/templates-app/village-quest-3d/package.json +1 -1
package/editor/index.html CHANGED
@@ -5,7 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <title>Incanto Scene Editor</title>
7
7
  <link rel="icon" href="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'><rect width='16' height='16' rx='3' fill='%236ee7dc'/><text x='8' y='12' text-anchor='middle' font-size='11' font-family='monospace' fill='%230e1018'>i</text></svg>" />
8
- <script type="module" crossorigin src="./assets/index-5dEIhvsf.js"></script>
8
+ <script type="module" crossorigin src="./assets/index-Df5g8ofT.js"></script>
9
9
  <link rel="modulepreload" crossorigin href="./assets/GameServer-C56iOUgF.js">
10
10
  </head>
11
11
  <body>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "incanto",
3
- "version": "0.49.0",
3
+ "version": "0.50.0",
4
4
  "description": "Vibe-coding-first web game engine SDK — JSON-driven scenes on three.js",
5
5
  "keywords": [
6
6
  "game-engine",
@@ -356,6 +356,17 @@ whole entity toward the target. (Distance is measured from the moved parent.)
356
356
  "script": { "name": "Chase", "props": { "target": "/root/Player", "speed": 120, "stopRange": 20 } } }
357
357
  ```
358
358
 
359
+ **A character body chases through the level, not through walls.** When the node
360
+ being moved is a `CharacterBody2D`/`3D`, `Chase` (and `Patrol`) move it with
361
+ `moveAndSlide()`, so it collides and slides like any character. A plain
362
+ `Node2D`/`Node3D` — the example above — has no collider and keeps the direct
363
+ write, which is also what you want for a ghost or a flying marker.
364
+
365
+ This is straight-line homing, not pathfinding: a body can now be STOPPED by
366
+ geometry it used to walk through. When enemies must find their way around a
367
+ level, that is what `buildTerrainNav` + `findPath` + `PathFollow` are for (see
368
+ `incanto-building-3d-games.md`).
369
+
359
370
  ## Wander
360
371
 
361
372
  Seeded random roaming inside a circle around the spawn point — idle critters,
@@ -98,12 +98,23 @@ far more useful.
98
98
  ## Replays
99
99
 
100
100
  A run that did not win is written out. Because the engine is deterministic
101
- (seeded RNG, injected clock), a replay reproduces that run **bit-identically**:
101
+ (seeded RNG, injected clock), a replay reproduces that run **bit-identically** —
102
+ feed the file straight back in, with the seed the run used:
102
103
 
103
104
  ```bash
104
- bunx incanto-play src/game.scene.json --seed 7 # then replay the recording
105
+ bunx incanto-play src/game.scene.json --seed 1 --commands .incanto/playtest/fell-seed1.json
106
+ # {"ok":true,"cmd":"replay","frames":804,"events":963}
107
+ # … then the scene as it ended: /Game/Player position=[28.9, -49.46, …]
105
108
  ```
106
109
 
110
+ `--commands` takes either a text command script or a replay file and tells them
111
+ apart by content. The seed matters: the world's own randomness (spawners,
112
+ wandering AI) comes from it, and only the PLAYER's input is in the recording.
113
+
114
+ Then read where it ended. The player above left a walled 40×40 arena at
115
+ `x = 28.9` before falling — a thing you cannot learn from "fell in 1/4" and can
116
+ read straight off the replay.
117
+
107
118
  One file per *kind* of failure — twenty identical "stuck" replays teach nothing
108
119
  the first one does not.
109
120
 
@@ -14,7 +14,7 @@
14
14
  "@dimforge/rapier2d-compat": "0.19.3",
15
15
  "@dimforge/rapier3d-compat": "0.19.3",
16
16
  "@pixiv/three-vrm": "^3.5.3",
17
- "incanto": "^0.49.0",
17
+ "incanto": "^0.50.0",
18
18
  "three": "^0.184.0"
19
19
  },
20
20
  "devDependencies": {
@@ -13,7 +13,7 @@
13
13
  "@dimforge/rapier2d-compat": "0.19.3",
14
14
  "@dimforge/rapier3d-compat": "0.19.3",
15
15
  "@pixiv/three-vrm": "^3.5.3",
16
- "incanto": "^0.49.0",
16
+ "incanto": "^0.50.0",
17
17
  "three": "^0.184.0"
18
18
  },
19
19
  "devDependencies": {
@@ -13,7 +13,7 @@
13
13
  "@dimforge/rapier2d-compat": "0.19.3",
14
14
  "@dimforge/rapier3d-compat": "0.19.3",
15
15
  "@pixiv/three-vrm": "^3.5.3",
16
- "incanto": "^0.49.0",
16
+ "incanto": "^0.50.0",
17
17
  "three": "^0.184.0"
18
18
  },
19
19
  "devDependencies": {