@combos-fun/plugin-renderer-3d-tiling-sprite 0.0.6 → 0.0.7

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.
package/README.md ADDED
@@ -0,0 +1,27 @@
1
+ # @combos-fun/plugin-renderer-3d-tiling-sprite
2
+
3
+ @combos-fun/plugin-renderer-3d-tiling-sprite — part of the Combos Fun engine monorepo.
4
+
5
+ Keywords: `3d`, `tiling`, `texture`, `floor`, `wall`, `repeat`.
6
+
7
+ ## Documentation
8
+
9
+ - Per-package agent / developer notes: [`agent-skill.md`](./agent-skill.md)
10
+ - Machine-readable manifest: [`combos-plugin.json`](./combos-plugin.json)
11
+ (validated against `schemas/combos-plugin.schema.json` in the repo
12
+ root)
13
+ - Entry skill (single source of truth for AI agents working with this
14
+ monorepo): `skills/combos-engine-development/SKILL.md`
15
+
16
+ When consumed from npm, the manifest and agent notes are exposed as
17
+ stable subpaths:
18
+
19
+ ```ts
20
+ import manifest from '@combos-fun/plugin-renderer-3d-tiling-sprite/plugin-manifest';
21
+ // or fetch the markdown directly:
22
+ // require.resolve('@combos-fun/plugin-renderer-3d-tiling-sprite/agent-skill')
23
+ ```
24
+
25
+ ## License
26
+
27
+ Internal workspace package, part of the Combos Fun engine monorepo.
package/agent-skill.md ADDED
@@ -0,0 +1,60 @@
1
+ # `@combos-fun/plugin-renderer-3d-tiling-sprite` — Agent notes
2
+
3
+ Repeating texture on a 3D plane (`PlaneGeometry` + `RepeatWrapping`
4
+ texture). Useful for ground tiles, walls, brick patterns.
5
+
6
+ ## When to read
7
+
8
+ Read for any tiled 3D surface: floors, walls, repeating patterns on a
9
+ plane.
10
+
11
+ ## Public API
12
+
13
+ ```ts
14
+ import { TilingSprite3D, TilingSprite3DSystem, type TilingSprite3DParams } from '@combos-fun/plugin-renderer-3d-tiling-sprite';
15
+ ```
16
+
17
+ `componentName = 'TilingSprite3D'`, `systemName = 'TilingSprite3DSystem'`.
18
+
19
+ ### `TilingSprite3DParams`
20
+
21
+ | Field | Type | Default |
22
+ |-------|------|---------|
23
+ | `resource` | `string` | `''` (texture URL — direct) |
24
+ | `repeatX` / `repeatY` | `number` | `1` |
25
+ | `width` / `height` | `number` | `10` |
26
+ | `positionX` / `Y` / `Z` | `number` | `0` |
27
+ | `rotationX` / `Y` / `Z` | `number` | `0` |
28
+ | `opacity` | `number` | `1` |
29
+
30
+ There are **no scale fields** — use `width` / `height` for size in world
31
+ units. Texture uses `THREE.RepeatWrapping`.
32
+
33
+ ## Required setup
34
+
35
+ `Renderer3DSystem` then `TilingSprite3DSystem`.
36
+
37
+ ## Common pitfalls
38
+
39
+ | Symptom | Fix |
40
+ |---------|-----|
41
+ | Texture stretched | Increase `repeatX` / `repeatY` to tile more |
42
+ | Visible seams | Use a power-of-two seamless texture |
43
+ | Plane invisible from below | Plane is single-sided — orient via `rotation*` so the camera sees the front |
44
+ | Need scale | Use `width` / `height`, not non-existent `scale*` |
45
+
46
+ ## Minimal example
47
+
48
+ ```ts
49
+ const floor = new GameObject('floor');
50
+ floor.addComponent(new TilingSprite3D({
51
+ resource: '/assets/floor.png',
52
+ repeatX: 4, repeatY: 4,
53
+ width: 10, height: 10,
54
+ rotationX: -Math.PI / 2, // lay flat
55
+ }));
56
+ ```
57
+
58
+ ## Verification
59
+
60
+ `pnpm --filter @combos-fun/plugin-renderer-3d-tiling-sprite run build`.
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "@combos-fun/plugin-renderer-3d-tiling-sprite",
3
+ "pluginId": "renderer-3d-tiling-sprite",
4
+ "category": "rendering",
5
+ "dimension": "3d",
6
+ "isCore": false,
7
+ "keywords": ["3d", "tiling", "texture", "floor", "wall", "repeat"],
8
+ "agentSkill": "./agent-skill.md",
9
+ "requires": ["@combos-fun/engine", "@combos-fun/plugin-renderer-3d"],
10
+ "exports": ["TilingSprite3D", "TilingSprite3DSystem"]
11
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@combos-fun/plugin-renderer-3d-tiling-sprite",
3
- "version": "0.0.6",
3
+ "version": "0.0.7",
4
4
  "description": "@combos-fun/plugin-renderer-3d-tiling-sprite",
5
5
  "main": "index.js",
6
6
  "module": "dist/plugin-renderer-3d-tiling-sprite.esm.js",
@@ -9,13 +9,27 @@
9
9
  "types": "dist/plugin-renderer-3d-tiling-sprite.d.ts",
10
10
  "files": [
11
11
  "index.js",
12
- "dist"
12
+ "dist",
13
+ "agent-skill.md",
14
+ "combos-plugin.json"
13
15
  ],
16
+ "exports": {
17
+ ".": {
18
+ "import": "./dist/plugin-renderer-3d-tiling-sprite.esm.js",
19
+ "require": "./index.js",
20
+ "types": "./dist/plugin-renderer-3d-tiling-sprite.d.ts"
21
+ },
22
+ "./plugin-manifest": "./combos-plugin.json",
23
+ "./agent-skill": "./agent-skill.md"
24
+ },
25
+ "combos": {
26
+ "pluginManifest": "./combos-plugin.json"
27
+ },
14
28
  "dependencies": {
15
29
  "three": "^0.172.0",
16
- "@combos-fun/plugin-renderer-3d": "0.0.6",
17
- "@combos-fun/inspector-decorator": "0.0.6",
18
- "@combos-fun/engine": "0.0.6"
30
+ "@combos-fun/engine": "0.0.7",
31
+ "@combos-fun/plugin-renderer-3d": "0.0.7",
32
+ "@combos-fun/inspector-decorator": "0.0.7"
19
33
  },
20
34
  "scripts": {
21
35
  "build": "node ../../scripts/build-package.mjs"