@adatechnology/game-animals-three 0.2.0 → 0.2.1

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.
@@ -289,6 +289,24 @@ uniform mat4 uNodes[${nodes.length}]; attribute float aNodeIndex; attribute vec3
289
289
  }
290
290
  };
291
291
  };
292
+ var LEAF = (() => {
293
+ const f = [0, 0, 0, -0.5, 0.4, 0, 0.5, 0.4, 0, 0, 1, 0];
294
+ const positions = [];
295
+ const normals = [];
296
+ const uvs = [];
297
+ const indices = [];
298
+ for (const side of [1, -1]) {
299
+ const base = positions.length / 3;
300
+ for (let i = 0; i < 4; i++) {
301
+ positions.push(f[i * 3], f[i * 3 + 1], f[i * 3 + 2]);
302
+ normals.push(0, 0, side);
303
+ uvs.push(f[i * 3] + 0.5, f[i * 3 + 1]);
304
+ }
305
+ if (side === 1) indices.push(base, base + 2, base + 1, base + 1, base + 2, base + 3);
306
+ else indices.push(base, base + 1, base + 2, base + 1, base + 3, base + 2);
307
+ }
308
+ return { positions, normals, uvs, indices };
309
+ })();
292
310
 
293
311
  // src/animate-bird.ts
294
312
  var { PI } = Math;