@adatechnology/game-vfx-three 0.1.2 → 0.2.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.
package/README.md CHANGED
@@ -10,8 +10,9 @@ The three.js renderer of [`@adatechnology/game-vfx`](../game-vfx). It draws a `V
10
10
  and marks agree. `createGroundPatch(THREE, { field })` is the Lab's 60 m patch as a mesh that follows a `GroundField`.
11
11
  - **Screen**: `overlay` puts the Lab's white flash (`mix-blend-mode: screen`) and the Workshop's white, red edge, sides and gas tint inside your container.
12
12
  `applyCamera()` shakes the camera for the render that follows and answers the function that puts it back.
13
+ - **Solid particles**: the Workshop's `MeshPool` (cones, spheres, icosahedra: the first-person muzzle flash and smoke) is drawn as one three.js mesh each (`workshop-meshes`), with the geometry, flat or lit material, blending, turn and scale the particle says; the geometry and the material go with the mesh.
13
14
  - **Workshop layers**: what `world.play` fills is drawn too, made when the first recipe plays: the two sprite systems with the page's soft-point shader, streaks,
14
- 500 instanced debris boxes, the decals (wet and dry), the expanding rings and the flash and fire lights. The Workshop's screen state joins the overlay (the
15
+ 500 instanced debris boxes, the decals (wet and dry), the expanding rings and the flash and fire lights. The Workshop's rain (`engine.rain`, up to 4 000 streaks, `workshop-rain` line segments) is drawn too; `game-weather-three` drives it. The Workshop's screen state joins the overlay (the
15
16
  stronger value of each field). The lens blobs and the post-processing the page paints on a 2D canvas are not drawn yet.
16
17
  - **Bench module**: `createVfxTestModule({ locale })` (id `vfx`, group `effects`) for `game-test-room`: pick an explosion or a recipe (listed by team), its variant,
17
18
  replay or auto replay, distance, LOD band, quality and six layers (`show_puffs`, `show_sparks`, `show_glows`, `show_debris`, `show_shock`, `show_sprites`),
package/dist/index.d.ts CHANGED
@@ -3,7 +3,7 @@ import { EffectSink, TestableModule } from '@adatechnology/game-contracts';
3
3
  import { VfxWorld, ScreenState, VfxOptions, VfxProfileName, EffectDef, ExplosionDef, GroundField, SpriteKindSystem, MarkEvent } from '@adatechnology/game-vfx';
4
4
 
5
5
  /** The only three.js members the renderer needs at runtime. Pass your own `THREE` instance (the whole namespace works). */
6
- type ThreeLib = Pick<typeof THREE_NS, 'AdditiveBlending' | 'BufferAttribute' | 'BufferGeometry' | 'BoxGeometry' | 'CanvasTexture' | 'CircleGeometry' | 'Color' | 'DodecahedronGeometry' | 'DynamicDrawUsage' | 'Euler' | 'Float32BufferAttribute' | 'Group' | 'IcosahedronGeometry' | 'InstancedBufferAttribute' | 'InstancedBufferGeometry' | 'InstancedMesh' | 'LineBasicMaterial' | 'LineSegments' | 'LinearSRGBColorSpace' | 'Matrix4' | 'Mesh' | 'MeshBasicMaterial' | 'MeshStandardMaterial' | 'NormalBlending' | 'PlaneGeometry' | 'Points' | 'PointLight' | 'Quaternion' | 'RepeatWrapping' | 'RingGeometry' | 'SRGBColorSpace' | 'DoubleSide' | 'ShaderMaterial' | 'SphereGeometry' | 'Vector3'>;
6
+ type ThreeLib = Pick<typeof THREE_NS, 'AdditiveBlending' | 'BufferAttribute' | 'BufferGeometry' | 'BoxGeometry' | 'CanvasTexture' | 'CircleGeometry' | 'Color' | 'ConeGeometry' | 'DodecahedronGeometry' | 'DynamicDrawUsage' | 'Euler' | 'Float32BufferAttribute' | 'Group' | 'IcosahedronGeometry' | 'InstancedBufferAttribute' | 'InstancedBufferGeometry' | 'InstancedMesh' | 'LineBasicMaterial' | 'LineSegments' | 'LinearSRGBColorSpace' | 'Matrix4' | 'Mesh' | 'MeshBasicMaterial' | 'MeshStandardMaterial' | 'NormalBlending' | 'PlaneGeometry' | 'Points' | 'PointLight' | 'Quaternion' | 'RepeatWrapping' | 'RingGeometry' | 'SRGBColorSpace' | 'DoubleSide' | 'ShaderMaterial' | 'SphereGeometry' | 'Vector3'>;
7
7
  /** A canvas the marks draw their textures on. A browser has one; a test supplies a fake. */
8
8
  interface CanvasLike {
9
9
  width: number;