@korial29/tiny-fps 0.128.0 → 0.128.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.
- package/dist/index.js +13 -13
- package/dist/types/client/hud.d.ts +1 -0
- package/dist/types/client/soldier.d.ts +16 -0
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Result } from '../shared/protocol';
|
|
2
2
|
import type { PlayerState, Rover, Snapshot } from '../shared/types';
|
|
3
3
|
import type { Mark } from './marks';
|
|
4
|
+
export declare const rim: () => [number, number][];
|
|
4
5
|
export declare const HUD_CSS: string;
|
|
5
6
|
/** The tabs of the title screen's menu, the first one shown first. */
|
|
6
7
|
export declare const TABS: string[];
|
|
@@ -35,6 +35,9 @@ export interface Runner {
|
|
|
35
35
|
dt: number;
|
|
36
36
|
/** The seat he rides in, when he does and his rover is known. */
|
|
37
37
|
seat?: Seat;
|
|
38
|
+
/** The head of the runner he looks at (watched()), and how far his own is turned to it, eased: to his right and up, radians. */
|
|
39
|
+
watch?: Vec3;
|
|
40
|
+
gaze?: number[];
|
|
38
41
|
/** The muzzle of the long gun in his hands as last drawn, from his feet: where its shots are seen to leave (combat.ts). */
|
|
39
42
|
tip?: Vec3;
|
|
40
43
|
/** The BUILD of the body (rig.ts, PlayerInfo.body): the man's when absent. */
|
|
@@ -59,6 +62,19 @@ export declare const createRunner: (p: PlayerState, seat?: Seat, build?: number)
|
|
|
59
62
|
* runner already in pose, one that left loses it. With a `world` the feet stand on the brushes
|
|
60
63
|
* under them. The `tracer` gets the sparks of a limb cut off.
|
|
61
64
|
*/
|
|
65
|
+
/**
|
|
66
|
+
* The head turns to the runner one looks at (the user, 2026-11-12): the nearest within `far`
|
|
67
|
+
* metres and `cone` radians of his aim. It turns no further than `turn` (to a side, up or down)
|
|
68
|
+
* from where it points, the eyes going the rest of their travel; `rate` is how fast, per second.
|
|
69
|
+
*/
|
|
70
|
+
export declare const WATCH: {
|
|
71
|
+
far: number;
|
|
72
|
+
cone: number;
|
|
73
|
+
turn: number[];
|
|
74
|
+
rate: number;
|
|
75
|
+
};
|
|
76
|
+
/** Where the head of the runner `p` looks at is, among `crowd`: nothing when he looks at no one, or is down. */
|
|
77
|
+
export declare const watched: (p: PlayerState, crowd: PlayerState[]) => Vec3 | undefined;
|
|
62
78
|
export declare const animate: (book: Map<number, Runner>, others: PlayerState[], dt: number, world?: World, tracer?: Pick<Tracer, "shock" | "spit">, rovers?: Rover[], builds?: ReadonlyMap<number, number>) => void;
|
|
63
79
|
/**
|
|
64
80
|
* A long gun's butt plate in the hollow of the right shoulder: from the shoulder joint, in 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.128.
|
|
5
|
+
"version": "0.128.1",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"files": [
|
|
8
8
|
"dist"
|