@zakkster/lite-tools 2.0.3 → 2.0.5
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/LiteEngine.d.ts +3 -3
- package/LiteEngine.js +6 -6
- package/README.md +2 -2
- package/package.json +1 -1
package/LiteEngine.d.ts
CHANGED
|
@@ -103,9 +103,9 @@ export { seedNoise, simplex2, simplex3, fbm2, fbm3, curl2 } from '@zakkster/lite
|
|
|
103
103
|
export { Timeline } from '@zakkster/lite-timeline';
|
|
104
104
|
|
|
105
105
|
// Interaction + utility
|
|
106
|
-
export {
|
|
106
|
+
export { GestureTracker } from '@zakkster/lite-gesture';
|
|
107
107
|
export { confetti, createConfetti } from '@zakkster/lite-confetti';
|
|
108
|
-
export {
|
|
108
|
+
export { liteId } from '@zakkster/lite-id';
|
|
109
109
|
export { Vec2 } from '@zakkster/lite-vec';
|
|
110
110
|
export { Seek, Flee, Wander, Arrive, Pursuit, Evade, PathFollow, Separation, Alignment, Cohesion, Flock } from '@zakkster/lite-steer';
|
|
111
111
|
|
|
@@ -154,7 +154,7 @@ import type {RainEngine} from '@zakkster/lite-rain';
|
|
|
154
154
|
import type {SnowEngine} from '@zakkster/lite-snow';
|
|
155
155
|
import type {SparkEngine} from '@zakkster/lite-sparks';
|
|
156
156
|
import type {FireworksEngine} from '@zakkster/lite-fireworks';
|
|
157
|
-
import type {
|
|
157
|
+
import type {GestureTracker} from '@zakkster/lite-gesture';
|
|
158
158
|
import type {Timeline} from '@zakkster/lite-timeline';
|
|
159
159
|
|
|
160
160
|
/** All recipes return at least a destroy() method. */
|
package/LiteEngine.js
CHANGED
|
@@ -102,9 +102,9 @@ export {seedNoise, simplex2, simplex3, fbm2, fbm3, curl2} from '@zakkster/lite-n
|
|
|
102
102
|
export {Timeline} from '@zakkster/lite-timeline';
|
|
103
103
|
|
|
104
104
|
// Interaction + utility
|
|
105
|
-
export {
|
|
105
|
+
export {GestureTracker} from '@zakkster/lite-gesture';
|
|
106
106
|
export {confetti, createConfetti} from '@zakkster/lite-confetti';
|
|
107
|
-
export {
|
|
107
|
+
export {liteId} from '@zakkster/lite-id';
|
|
108
108
|
export {Vec2} from '@zakkster/lite-vec';
|
|
109
109
|
export {
|
|
110
110
|
Seek, Flee, Wander, Arrive, Pursuit, Evade, PathFollow, Separation, Alignment, Cohesion, Flock
|
|
@@ -165,9 +165,9 @@ import {SpringPool} from '@zakkster/lite-spring';
|
|
|
165
165
|
import {Gradient} from '@zakkster/lite-gradient';
|
|
166
166
|
import {seedNoise, fbm2} from '@zakkster/lite-noise';
|
|
167
167
|
import {Timeline} from '@zakkster/lite-timeline';
|
|
168
|
-
import {
|
|
168
|
+
import {GestureTracker} from '@zakkster/lite-gesture';
|
|
169
169
|
import {confetti as confettiFn} from '@zakkster/lite-confetti';
|
|
170
|
-
import {
|
|
170
|
+
import {liteId} from '@zakkster/lite-id';
|
|
171
171
|
import {Vec2} from '@zakkster/lite-vec';
|
|
172
172
|
import {Flock, Wander, Separation, Alignment, Cohesion} from '@zakkster/lite-steer';
|
|
173
173
|
import {BmFont} from '@zakkster/lite-bmfont';
|
|
@@ -973,7 +973,7 @@ export const Recipes = {
|
|
|
973
973
|
|
|
974
974
|
function addDamage(x, y, value) {
|
|
975
975
|
numbers.push({
|
|
976
|
-
id:
|
|
976
|
+
id: liteId(), x, y, value: String(value),
|
|
977
977
|
startY: y, t: 0, life: 1.2, alpha: 1,
|
|
978
978
|
});
|
|
979
979
|
score += value;
|
|
@@ -1284,7 +1284,7 @@ export const Recipes = {
|
|
|
1284
1284
|
}, destroy() {
|
|
1285
1285
|
}
|
|
1286
1286
|
};
|
|
1287
|
-
const gesture = new
|
|
1287
|
+
const gesture = new GestureTracker(el);
|
|
1288
1288
|
let currentIndex = 0, offsetX = 0;
|
|
1289
1289
|
const slideWidth = el.clientWidth || 300;
|
|
1290
1290
|
|
package/README.md
CHANGED
|
@@ -418,7 +418,7 @@ hud.update(dt);
|
|
|
418
418
|
console.log(hud.getScore()); // cumulative
|
|
419
419
|
```
|
|
420
420
|
|
|
421
|
-
**Composes:** `BmFont` + `easeOutCubic` + `easeInOutCubic` + `
|
|
421
|
+
**Composes:** `BmFont` + `easeOutCubic` + `easeInOutCubic` + `liteId()` + `Random`
|
|
422
422
|
|
|
423
423
|
</details>
|
|
424
424
|
|
|
@@ -558,7 +558,7 @@ carousel.goTo(2);
|
|
|
558
558
|
console.log(carousel.getCurrentIndex()); // 2
|
|
559
559
|
```
|
|
560
560
|
|
|
561
|
-
**Composes:** `
|
|
561
|
+
**Composes:** `GestureTracker` (pan + panEnd with velocity) + `Timeline` + `easeOutCubic`
|
|
562
562
|
|
|
563
563
|
</details>
|
|
564
564
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zakkster/lite-tools",
|
|
3
3
|
"author": "Zahary Shinikchiev <shinikchiev@yahoo.com>",
|
|
4
|
-
"version": "2.0.
|
|
4
|
+
"version": "2.0.5",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"description": "The standard library for high-performance web presentation — 45+ micro-libraries, 24 recipes, zero-GC, deterministic, tree-shakeable.",
|
|
7
7
|
"type": "module",
|