@korial29/tiny-fps 0.117.0 → 0.118.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.
|
@@ -17,6 +17,8 @@ interface Region {
|
|
|
17
17
|
/** Its bottom and top at each angle (degrees from the front, + outward), when not level: a leg's opening. */
|
|
18
18
|
low?: (a: number) => number;
|
|
19
19
|
high?: (a: number) => number;
|
|
20
|
+
/** Only on the woman's skin. */
|
|
21
|
+
fem?: boolean;
|
|
20
22
|
/** A round plate: its outline an ellipse in (angle, height), [half the angle, middle height, half height]. */
|
|
21
23
|
round?: [number, number, number];
|
|
22
24
|
}
|
|
@@ -26,6 +28,15 @@ interface Region {
|
|
|
26
28
|
* the pecs and fading to the collar, the plate flat below; `PEC` metres at most.
|
|
27
29
|
*/
|
|
28
30
|
export declare const PEC = 0.011;
|
|
31
|
+
/**
|
|
32
|
+
* The woman's chest plate (the user, 2026-11-11: a more feminine armour, with the chest; until then
|
|
33
|
+
* one moulded piece with the sternum filled): a cup each side over the bust skin.ts shapes, `CUP`
|
|
34
|
+
* metres out at most, fullest low with a firm line under it, the sternum left hollow between them.
|
|
35
|
+
*/
|
|
36
|
+
export declare const CUP = 0.014;
|
|
37
|
+
export declare const bust: (x: number, y: number) => number;
|
|
38
|
+
/** The woman's shoulder cap: a low dome, 5 mm more at the middle of the deltoid; its middle height and half height on the arm at rest. */
|
|
39
|
+
export declare const SHOULDER: number[];
|
|
29
40
|
/** The gap the user asked between the chest plate and the belly's plates, and between those. */
|
|
30
41
|
export declare const GAP = 0.02;
|
|
31
42
|
export declare const REGIONS: Region[];
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import type { Spot } from './helmet';
|
|
2
|
+
import type { Vec3 } from './mesh';
|
|
3
|
+
import type { Quat } from './rig';
|
|
4
|
+
/**
|
|
5
|
+
* The dome: its middle (the widest ring, level with the brow), its half width, height over the
|
|
6
|
+
* middle and depth, how square it is seen from above, how flat on top, and the height of its lip
|
|
7
|
+
* under the chin. It holds the head of the skin (1.555 to 1.803 m, the head joint at 1.62).
|
|
8
|
+
*/
|
|
9
|
+
export declare const DOME: {
|
|
10
|
+
c: Vec3;
|
|
11
|
+
r: Vec3;
|
|
12
|
+
e: [number, number];
|
|
13
|
+
rim: number;
|
|
14
|
+
/** The cheeks draw in by this share half way down, and the lip flares out by this one. */
|
|
15
|
+
waist: number;
|
|
16
|
+
flare: number;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* The T: the slit's middle height and half height at the nose and at its ends, how far round it
|
|
20
|
+
* goes (radians from the front), and the slot's half width (metres across the front).
|
|
21
|
+
*/
|
|
22
|
+
export declare const TEE: {
|
|
23
|
+
y: number;
|
|
24
|
+
h: [number, number];
|
|
25
|
+
round: number;
|
|
26
|
+
slot: number;
|
|
27
|
+
/** The frame round it, in the team's colour: how much wider than the glass, and how far each stands off the dome. */
|
|
28
|
+
frame: number;
|
|
29
|
+
off: [number, number];
|
|
30
|
+
};
|
|
31
|
+
/** The ear caps: their height on the dome, radius and thickness; the stalk's height over the cap and half width. */
|
|
32
|
+
export declare const EAR: {
|
|
33
|
+
y: number;
|
|
34
|
+
r: number;
|
|
35
|
+
t: number;
|
|
36
|
+
stalk: number;
|
|
37
|
+
w: number;
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* The cheek plates, grey, each side of the slot under the slit: how far round they go (radians),
|
|
41
|
+
* the gap to the T's frame, how much their top edge falls to the back, and how far they stand off.
|
|
42
|
+
*/
|
|
43
|
+
export declare const CHEEK: {
|
|
44
|
+
round: number;
|
|
45
|
+
gap: number;
|
|
46
|
+
fall: number;
|
|
47
|
+
off: number;
|
|
48
|
+
};
|
|
49
|
+
/** The crest, in the team's colour: a stripe from the brow over the top to the back of the dome, its half width and how far it stands off. */
|
|
50
|
+
export declare const CREST: {
|
|
51
|
+
w: number;
|
|
52
|
+
off: number;
|
|
53
|
+
from: number;
|
|
54
|
+
};
|
|
55
|
+
/** The dome's surface at the turn `a` (radians from the front, + to the right) and height y. */
|
|
56
|
+
export declare const dome: (a: number, y: number) => Vec3;
|
|
57
|
+
/** The point of the dome at (a, y) set `off` metres out along its normal, with that normal. */
|
|
58
|
+
export declare const onDome: (a: number, y: number, off?: number) => Spot;
|
|
59
|
+
/** The slit's half height at the turn `a`: tall at the nose, thin at its ends. */
|
|
60
|
+
export declare const slit: (a: number) => number;
|
|
61
|
+
/** Whether the dome's point at (a, y) is under the T's glass grown by `grow` metres. */
|
|
62
|
+
export declare const glazed: (a: number, y: number, grow?: number) => boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Appends her helmet at level of detail `lod` (0 far, 1 near, 2 and up close) on the head joint at
|
|
65
|
+
* `at` turned by `q`, the frame of its T in `rgb`, the team's colour (0 to 1). The far one has no
|
|
66
|
+
* ear caps and no cheek plates.
|
|
67
|
+
*/
|
|
68
|
+
export declare const helm: (out: number[], at: Vec3, q: Quat, rgb: number[], lod: number) => void;
|
|
@@ -46,6 +46,8 @@ export declare const cross: (a: Vec3, b: Vec3) => Vec3;
|
|
|
46
46
|
export declare const unit: (v: Vec3) => Vec3;
|
|
47
47
|
/** A signed power: the superellipse's |t|^p keeping t's sign. */
|
|
48
48
|
export declare const pow: (t: number, p: number) => number;
|
|
49
|
+
/** A triangle over `p`, wound as its first normal faces, in `col` on `layer`; none if it has no area. */
|
|
50
|
+
export declare const face: (out: number[], col: number[], layer: number, p: Spot[]) => void;
|
|
49
51
|
/**
|
|
50
52
|
* Triangles between the rows of points `rows`, each a closed ring of n (the first and the last may
|
|
51
53
|
* be one point), in `col` on `layer`; wound as the normals face. Triangles of no area are left out.
|
|
@@ -43,8 +43,8 @@ export declare const PAD: {
|
|
|
43
43
|
h: number;
|
|
44
44
|
cut: number;
|
|
45
45
|
};
|
|
46
|
-
/** The woman's
|
|
47
|
-
export declare const
|
|
46
|
+
/** The woman's cup, scaled about its joint: flatter. Her shoulders have caps of the armour (armor.ts), no pads. */
|
|
47
|
+
export declare const CUP_F: Vec3;
|
|
48
48
|
/** Appends both shoulder pads at level of detail `lod` on the arm joints (`arms`: the left's and the right's place and turn), in `plate` (white when absent), `scale`d about the joints. */
|
|
49
49
|
export declare const shoulders: (out: number[], arms: [Vec3, Quat][], lod: number, plate?: number[], scale?: number) => void;
|
|
50
50
|
/** Appends the crotch cup at level of detail `lod` on the pelvis joint at `at` turned by `q`, in `plate` (white when absent). */
|
|
@@ -72,7 +72,7 @@ export interface Skin {
|
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
74
|
/** How far out the woman's bust stands at its fullest, on the man's rest mesh, metres. */
|
|
75
|
-
export declare const BUST = 0.
|
|
75
|
+
export declare const BUST = 0.028;
|
|
76
76
|
/**
|
|
77
77
|
* The skin at a level of detail: 0 far, 1 near (see DETAIL in mesh.ts), 2 near, headless and
|
|
78
78
|
* handless, for the eye, 3 close (CLOSE in render.ts), twice the rings and half more sides, the
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@korial29/tiny-fps",
|
|
3
3
|
"description": "Tiny multiplayer first-person rooftop game for the browser: raw WebGL, zero runtime dependencies, WebSocket or same-browser multi-tab play.",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.118.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"files": [
|
|
8
8
|
"dist"
|