@thi.ng/boids 1.0.0 → 1.0.3
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/CHANGELOG.md +1 -1
- package/README.md +7 -3
- package/behaviors/update.d.ts +10 -0
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -7,9 +7,13 @@
|
|
|
7
7
|

|
|
8
8
|
[](https://mastodon.thi.ng/@toxi)
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
> [!NOTE]
|
|
11
|
+
> This is one of 189 standalone projects, maintained as part
|
|
12
|
+
> of the [@thi.ng/umbrella](https://github.com/thi-ng/umbrella/) monorepo
|
|
13
|
+
> and anti-framework.
|
|
14
|
+
>
|
|
15
|
+
> 🚀 Help me to work full-time on these projects by [sponsoring me on
|
|
16
|
+
> GitHub](https://github.com/sponsors/postspectacular). Thank you! ❤️
|
|
13
17
|
|
|
14
18
|
- [About](#about)
|
|
15
19
|
- [Available behaviors](#available-behaviors)
|
package/behaviors/update.d.ts
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
import type { Vec } from "@thi.ng/vectors";
|
|
2
2
|
import type { Boid } from "../boid.js";
|
|
3
|
+
/**
|
|
4
|
+
* Behavior update function (the default implementation fro
|
|
5
|
+
* {@link BoidOpts.update}). Takes a single {@link Boid} and evaluates all of
|
|
6
|
+
* its assigned behaviors (in the order given). If a behavior's weight evaluates
|
|
7
|
+
* to zero, the behavior will be skipped, otherwise the returned force vector
|
|
8
|
+
* will be added (multiplied with the behavior's current weight). Returns summed
|
|
9
|
+
* force vector of all behaviors.
|
|
10
|
+
*
|
|
11
|
+
* @param boid
|
|
12
|
+
*/
|
|
3
13
|
export declare const blendedBehaviorUpdate: (boid: Boid) => Vec;
|
|
4
14
|
//# sourceMappingURL=update.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/boids",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "n-dimensional boids simulation with modular behavior system",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -35,14 +35,14 @@
|
|
|
35
35
|
"test": "bun test"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@thi.ng/api": "^8.9.
|
|
39
|
-
"@thi.ng/checks": "^3.4.
|
|
40
|
-
"@thi.ng/distance": "^2.4.
|
|
41
|
-
"@thi.ng/geom-closest-point": "^2.1.
|
|
42
|
-
"@thi.ng/geom-resample": "^2.3.
|
|
43
|
-
"@thi.ng/math": "^5.
|
|
44
|
-
"@thi.ng/timestep": "^0.5.
|
|
45
|
-
"@thi.ng/vectors": "^7.
|
|
38
|
+
"@thi.ng/api": "^8.9.20",
|
|
39
|
+
"@thi.ng/checks": "^3.4.20",
|
|
40
|
+
"@thi.ng/distance": "^2.4.44",
|
|
41
|
+
"@thi.ng/geom-closest-point": "^2.1.98",
|
|
42
|
+
"@thi.ng/geom-resample": "^2.3.24",
|
|
43
|
+
"@thi.ng/math": "^5.8.2",
|
|
44
|
+
"@thi.ng/timestep": "^0.5.19",
|
|
45
|
+
"@thi.ng/vectors": "^7.10.2"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@microsoft/api-extractor": "^7.39.0",
|
|
@@ -143,5 +143,5 @@
|
|
|
143
143
|
"status": "alpha",
|
|
144
144
|
"year": 2023
|
|
145
145
|
},
|
|
146
|
-
"gitHead": "
|
|
146
|
+
"gitHead": "3fa30b2dc2de762f24fd64b881b68d4da33d4c38\n"
|
|
147
147
|
}
|