@kuncat/avoidant 0.2.2 → 0.2.4
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/components/AvoidantGame.svelte +1 -2
- package/dist/components/MapControls.svelte +1 -1
- package/dist/components/board.svelte +38 -23
- package/dist/components/label-connectors.d.ts +6 -0
- package/dist/components/label-connectors.js +73 -0
- package/dist/components/map-camera.js +1 -1
- package/dist/paraglide/messages/_index.d.ts +8 -8
- package/dist/paraglide/messages/_index.js +9 -9
- package/dist/paraglide/messages/action_back.js +2 -2
- package/dist/paraglide/messages/action_copy.js +2 -2
- package/dist/paraglide/messages/action_exit.js +2 -2
- package/dist/paraglide/messages/action_invite.js +2 -2
- package/dist/paraglide/messages/action_join.js +2 -2
- package/dist/paraglide/messages/action_join_game.js +2 -2
- package/dist/paraglide/messages/action_new_game.js +2 -2
- package/dist/paraglide/messages/action_random.js +2 -2
- package/dist/paraglide/messages/action_start.js +2 -2
- package/dist/paraglide/messages/aria_close_invitation.js +2 -2
- package/dist/paraglide/messages/aria_score_summary.js +2 -2
- package/dist/paraglide/messages/cells_count.js +2 -2
- package/dist/paraglide/messages/cells_per_face.js +2 -2
- package/dist/paraglide/messages/default_player_name.js +2 -2
- package/dist/paraglide/messages/error_join_connect_failed.js +2 -2
- package/dist/paraglide/messages/error_join_failed.js +2 -2
- package/dist/paraglide/messages/error_join_ticket_invalid.js +2 -2
- package/dist/paraglide/messages/error_join_ticket_required.js +2 -2
- package/dist/paraglide/messages/faces_count.js +2 -2
- package/dist/paraglide/messages/field_cell_density.js +2 -2
- package/dist/paraglide/messages/field_invitation_url.js +2 -2
- package/dist/paraglide/messages/field_map_shape.js +2 -2
- package/dist/paraglide/messages/field_map_size.js +2 -2
- package/dist/paraglide/messages/field_player_name.js +2 -2
- package/dist/paraglide/messages/field_radius.js +2 -2
- package/dist/paraglide/messages/field_radius_x.js +2 -2
- package/dist/paraglide/messages/field_radius_y.js +2 -2
- package/dist/paraglide/messages/field_radius_z.js +2 -2
- package/dist/paraglide/messages/field_relay_servers.js +2 -2
- package/dist/paraglide/messages/field_seed.js +2 -2
- package/dist/paraglide/messages/field_size.js +2 -2
- package/dist/paraglide/messages/field_spikiness.js +2 -2
- package/dist/paraglide/messages/field_subdivisions.js +2 -2
- package/dist/paraglide/messages/field_surface_detail.js +2 -2
- package/dist/paraglide/messages/field_ticket_or_invitation_url.js +2 -2
- package/dist/paraglide/messages/field_tutorial_mode.js +2 -2
- package/dist/paraglide/messages/field_void_fraction.js +2 -2
- package/dist/paraglide/messages/label_advanced_settings.js +2 -2
- package/dist/paraglide/messages/label_players.js +2 -2
- package/dist/paraglide/messages/label_safe_cells_explored.js +2 -2
- package/dist/paraglide/messages/label_safe_cells_remaining.js +2 -2
- package/dist/paraglide/messages/label_score.js +2 -2
- package/dist/paraglide/messages/label_streak.js +2 -2
- package/dist/paraglide/messages/label_voids_discovered.js +2 -2
- package/dist/paraglide/messages/package.json +4 -0
- package/dist/paraglide/messages/preset_custom.js +2 -2
- package/dist/paraglide/messages/preset_large.js +2 -2
- package/dist/paraglide/messages/preset_medium.js +2 -2
- package/dist/paraglide/messages/preset_small.js +2 -2
- package/dist/paraglide/messages/shape_label.js +2 -2
- package/dist/paraglide/messages/status_generating_map.js +2 -2
- package/dist/paraglide/messages/status_initialization_failed.js +2 -2
- package/dist/paraglide/messages/status_joining_game.js +2 -2
- package/dist/paraglide/messages/status_loading.js +2 -2
- package/dist/paraglide/messages/status_preparing.js +2 -2
- package/dist/paraglide/messages/text_avoided.js +2 -2
- package/dist/paraglide/messages/text_density_summary.js +2 -2
- package/dist/paraglide/messages/text_invite_after_opening.js +2 -2
- package/dist/paraglide/messages/text_relay_servers_hint.js +2 -2
- package/dist/paraglide/messages/tutorial_action_dismiss.js +2 -2
- package/dist/paraglide/messages/tutorial_action_next.js +2 -2
- package/dist/paraglide/messages/tutorial_after_safe_deducible.js +2 -2
- package/dist/paraglide/messages/tutorial_after_safe_guess.js +2 -2
- package/dist/paraglide/messages/tutorial_after_void.js +2 -2
- package/dist/paraglide/messages/tutorial_awaiting_first_click.js +2 -2
- package/dist/paraglide/messages/tutorial_intro.d.ts +1 -1
- package/dist/paraglide/messages/tutorial_intro.js +5 -5
- package/dist/paraglide/messages/tutorial_won.js +2 -2
- package/dist/paraglide/registry.d.ts +13 -0
- package/dist/paraglide/registry.js +15 -0
- package/dist/paraglide/runtime.d.ts +90 -26
- package/dist/paraglide/runtime.js +597 -109
- package/dist/paraglide/server.d.ts +1 -1
- package/dist/paraglide/server.js +27 -10
- package/dist/wasm/avoidant_wasm.d.ts +56 -11
- package/dist/wasm/avoidant_wasm.js +325 -189
- package/dist/wasm/avoidant_wasm_bg.wasm +0 -0
- package/dist/wasm/avoidant_wasm_bg.wasm.d.ts +25 -11
- package/package.json +29 -29
|
@@ -848,8 +848,7 @@
|
|
|
848
848
|
id="relay-servers"
|
|
849
849
|
bind:value={relayServersInput}
|
|
850
850
|
rows="4"
|
|
851
|
-
spellcheck="false"
|
|
852
|
-
></textarea>
|
|
851
|
+
spellcheck="false"></textarea>
|
|
853
852
|
<p class="field-help">{m.text_relay_servers_hint()}</p>
|
|
854
853
|
<div class="mt-6 w-full">
|
|
855
854
|
<label class="field-label" for="rng-seed-input">{m.field_seed()}</label>
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
const dx = event.clientX - previous.x;
|
|
108
108
|
const dy = event.clientY - previous.y;
|
|
109
109
|
if (previous.button === 1) zoom(event.clientX, event.clientY, dy * 0.01);
|
|
110
|
-
else if (event.shiftKey) rotate(dx, dy);
|
|
110
|
+
else if (previous.button === 2 || event.shiftKey) rotate(dx, dy);
|
|
111
111
|
else pan(previous.x, previous.y, event.clientX, event.clientY);
|
|
112
112
|
}
|
|
113
113
|
}
|
|
@@ -49,6 +49,7 @@
|
|
|
49
49
|
</script>
|
|
50
50
|
|
|
51
51
|
<script lang="ts">
|
|
52
|
+
import { cellLabelPlacements } from "./label-connectors";
|
|
52
53
|
import IdleBillboard from "./IdleBillboard.svelte";
|
|
53
54
|
import { TerrainDepthSort } from "./terrain-depth-sort";
|
|
54
55
|
import { SvelteMap, SvelteSet } from "svelte/reactivity";
|
|
@@ -59,6 +60,7 @@
|
|
|
59
60
|
import {
|
|
60
61
|
BufferAttribute,
|
|
61
62
|
BufferGeometry,
|
|
63
|
+
Color,
|
|
62
64
|
DataTexture,
|
|
63
65
|
DoubleSide,
|
|
64
66
|
Mesh,
|
|
@@ -460,31 +462,41 @@
|
|
|
460
462
|
});
|
|
461
463
|
|
|
462
464
|
const LABEL_LIFT_FACTOR = 0.4;
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
465
|
+
const labelPlacements = $derived(
|
|
466
|
+
cellLabelPlacements(
|
|
467
|
+
terrainGeometry,
|
|
468
|
+
$cells.map((cell) => new Vector3(...cell.normal)),
|
|
469
|
+
cellRadius * LABEL_LIFT_FACTOR,
|
|
470
|
+
),
|
|
471
|
+
);
|
|
472
|
+
const cellLabelAnchors = $derived(labelPlacements.map((placement) => placement?.anchor));
|
|
473
|
+
|
|
474
|
+
// Keep connectors in world space: only the text should turn to face the camera.
|
|
475
|
+
// Batch all visible labels into one draw call, with depth testing so lines on
|
|
476
|
+
// the far side of the map remain hidden behind the terrain.
|
|
477
|
+
const labelConnectorGeometry = $derived.by(() => {
|
|
478
|
+
const points: Vector3[] = [];
|
|
479
|
+
const colors: number[] = [];
|
|
480
|
+
for (let i = 0; i < $cellMetadata.length; i++) {
|
|
481
|
+
const entry = $cellMetadata[i];
|
|
482
|
+
const anchor = cellLabelAnchors[i];
|
|
483
|
+
const surface = labelPlacements[i]?.surface;
|
|
484
|
+
if (!entry.isExplored || entry.isVoid || entry.voidNeighborCount <= 0 || !anchor || !surface)
|
|
485
|
+
continue;
|
|
486
|
+
points.push(surface, new Vector3(anchor.x, anchor.y, anchor.z));
|
|
487
|
+
const color = new Color(
|
|
488
|
+
LABEL_COLORS[Math.min(entry.voidNeighborCount, LABEL_COLORS.length - 1)],
|
|
489
|
+
);
|
|
490
|
+
colors.push(color.r, color.g, color.b, color.r, color.g, color.b);
|
|
473
491
|
}
|
|
474
|
-
|
|
492
|
+
const geometry = new BufferGeometry().setFromPoints(points);
|
|
493
|
+
geometry.setAttribute("color", new BufferAttribute(new Float32Array(colors), 3));
|
|
494
|
+
return geometry;
|
|
495
|
+
});
|
|
496
|
+
$effect(() => {
|
|
497
|
+
const geometry = labelConnectorGeometry;
|
|
498
|
+
return () => geometry.dispose();
|
|
475
499
|
});
|
|
476
|
-
const cellLabelAnchors = $derived(
|
|
477
|
-
$cells.map((cell, idx) => {
|
|
478
|
-
const [cxv, cyv, czv] = cell.centroid;
|
|
479
|
-
const [nx, ny, nz] = cell.normal;
|
|
480
|
-
const lift = (terrainCellMaxHeights[idx] ?? 0) + cellRadius * LABEL_LIFT_FACTOR;
|
|
481
|
-
return {
|
|
482
|
-
x: cxv + nx * lift,
|
|
483
|
-
y: cyv + ny * lift,
|
|
484
|
-
z: czv + nz * lift,
|
|
485
|
-
};
|
|
486
|
-
}),
|
|
487
|
-
);
|
|
488
500
|
|
|
489
501
|
const LABEL_COLORS = [
|
|
490
502
|
undefined,
|
|
@@ -589,6 +601,9 @@
|
|
|
589
601
|
|
|
590
602
|
<T is={opaqueMesh} />
|
|
591
603
|
<T is={terrainMesh} name="terrain" onclick={handleTerrainClick} />
|
|
604
|
+
<T.LineSegments geometry={labelConnectorGeometry}>
|
|
605
|
+
<T.LineBasicMaterial vertexColors depthWrite={false} />
|
|
606
|
+
</T.LineSegments>
|
|
592
607
|
|
|
593
608
|
{#each $cellMetadata as entry, i (i)}
|
|
594
609
|
{#if entry.isExplored && !entry.isVoid && entry.voidNeighborCount > 0}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { BufferGeometry, Vector3 } from "three";
|
|
2
|
+
/** Center each label on its cell's exposed mesh, aligned with the base face normal. */
|
|
3
|
+
export declare function cellLabelPlacements(geometry: BufferGeometry, normals: Vector3[], clearance: number): ({
|
|
4
|
+
surface: Vector3;
|
|
5
|
+
anchor: Vector3;
|
|
6
|
+
} | undefined)[];
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { BufferGeometry, Ray, Triangle, Vector3 } from "three";
|
|
2
|
+
/** Center each label on its cell's exposed mesh, aligned with the base face normal. */
|
|
3
|
+
export function cellLabelPlacements(geometry, normals, clearance) {
|
|
4
|
+
const positions = geometry.getAttribute("position");
|
|
5
|
+
const cellIndices = geometry.getAttribute("aCellIndex");
|
|
6
|
+
const triangles = new Map();
|
|
7
|
+
const index = geometry.index;
|
|
8
|
+
for (let offset = 0; offset < (index?.count ?? positions.count); offset += 3) {
|
|
9
|
+
const a = index ? index.getX(offset) : offset;
|
|
10
|
+
const b = index ? index.getX(offset + 1) : offset + 1;
|
|
11
|
+
const c = index ? index.getX(offset + 2) : offset + 2;
|
|
12
|
+
const cell = cellIndices.getX(a);
|
|
13
|
+
const triangle = new Triangle(new Vector3().fromBufferAttribute(positions, a), new Vector3().fromBufferAttribute(positions, b), new Vector3().fromBufferAttribute(positions, c));
|
|
14
|
+
const group = triangles.get(cell);
|
|
15
|
+
if (group)
|
|
16
|
+
group.push(triangle);
|
|
17
|
+
else
|
|
18
|
+
triangles.set(cell, [triangle]);
|
|
19
|
+
}
|
|
20
|
+
return normals.map((faceNormal, cell) => {
|
|
21
|
+
const mesh = triangles.get(cell);
|
|
22
|
+
if (!mesh || !faceNormal.lengthSq())
|
|
23
|
+
return undefined;
|
|
24
|
+
const normal = faceNormal.clone().normalize();
|
|
25
|
+
const centroid = new Vector3();
|
|
26
|
+
const midpoint = new Vector3();
|
|
27
|
+
let area = 0;
|
|
28
|
+
let top = -Infinity;
|
|
29
|
+
for (const triangle of mesh) {
|
|
30
|
+
const weight = triangle.getArea();
|
|
31
|
+
centroid.addScaledVector(triangle.getMidpoint(midpoint), weight);
|
|
32
|
+
area += weight;
|
|
33
|
+
top = Math.max(top, triangle.a.dot(normal), triangle.b.dot(normal), triangle.c.dot(normal));
|
|
34
|
+
}
|
|
35
|
+
if (!area)
|
|
36
|
+
return undefined;
|
|
37
|
+
centroid.divideScalar(area);
|
|
38
|
+
// A curved mesh's area centroid may lie inside the terrain. Project outward
|
|
39
|
+
// along the face normal, then intersect back onto the exposed surface.
|
|
40
|
+
const gap = Math.max(clearance, 1e-6);
|
|
41
|
+
const anchor = centroid.clone().addScaledVector(normal, top + gap - centroid.dot(normal));
|
|
42
|
+
const ray = new Ray(anchor, normal.clone().negate());
|
|
43
|
+
const hit = new Vector3();
|
|
44
|
+
let surface;
|
|
45
|
+
let nearest = Infinity;
|
|
46
|
+
for (const triangle of mesh) {
|
|
47
|
+
if (!ray.intersectTriangle(triangle.a, triangle.b, triangle.c, false, hit))
|
|
48
|
+
continue;
|
|
49
|
+
const distance = anchor.distanceToSquared(hit);
|
|
50
|
+
if (distance < nearest) {
|
|
51
|
+
nearest = distance;
|
|
52
|
+
surface = hit.clone();
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
if (!surface) {
|
|
56
|
+
// For a non-convex cell or inset gap, use its nearest surface point and
|
|
57
|
+
// move the label with it so the connector never tilts away from the normal.
|
|
58
|
+
nearest = Infinity;
|
|
59
|
+
for (const triangle of mesh) {
|
|
60
|
+
triangle.closestPointToPoint(centroid, hit);
|
|
61
|
+
const distance = centroid.distanceToSquared(hit);
|
|
62
|
+
if (distance < nearest) {
|
|
63
|
+
nearest = distance;
|
|
64
|
+
surface = hit.clone();
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
if (!surface)
|
|
69
|
+
return undefined;
|
|
70
|
+
anchor.copy(surface).addScaledVector(normal, top + gap - surface.dot(normal));
|
|
71
|
+
return { surface, anchor };
|
|
72
|
+
});
|
|
73
|
+
}
|
|
@@ -55,7 +55,7 @@ export function orbitRadiansPerPixel(camera, radius, viewportHeight, flat = fals
|
|
|
55
55
|
const surfaceDistance = Math.max(mapRadius * 0.01, camera.position.length() - (flat ? 0 : mapRadius));
|
|
56
56
|
const visibleHeight = 2 * Math.tan((camera.getEffectiveFOV() * Math.PI) / 360) * surfaceDistance;
|
|
57
57
|
// The vertical FOV includes the aspect-ratio adjustment on narrow screens.
|
|
58
|
-
return 2 * Math.min(Math.PI * 2, visibleHeight / mapRadius) / Math.max(1, viewportHeight);
|
|
58
|
+
return (2 * Math.min(Math.PI * 2, visibleHeight / mapRadius)) / Math.max(1, viewportHeight);
|
|
59
59
|
}
|
|
60
60
|
/** Move the grabbed surface point with the pointer without changing the orbit center. */
|
|
61
61
|
export function panMap(camera, from, to, anchor) {
|
|
@@ -5,15 +5,19 @@ export * from "./action_invite.js";
|
|
|
5
5
|
export * from "./action_join.js";
|
|
6
6
|
export * from "./action_join_game.js";
|
|
7
7
|
export * from "./action_new_game.js";
|
|
8
|
+
export * from "./action_random.js";
|
|
8
9
|
export * from "./action_start.js";
|
|
9
10
|
export * from "./aria_close_invitation.js";
|
|
10
11
|
export * from "./aria_score_summary.js";
|
|
11
12
|
export * from "./cells_count.js";
|
|
13
|
+
export * from "./cells_per_face.js";
|
|
12
14
|
export * from "./default_player_name.js";
|
|
13
15
|
export * from "./error_join_connect_failed.js";
|
|
14
16
|
export * from "./error_join_failed.js";
|
|
15
17
|
export * from "./error_join_ticket_invalid.js";
|
|
16
18
|
export * from "./error_join_ticket_required.js";
|
|
19
|
+
export * from "./faces_count.js";
|
|
20
|
+
export * from "./field_cell_density.js";
|
|
17
21
|
export * from "./field_invitation_url.js";
|
|
18
22
|
export * from "./field_map_shape.js";
|
|
19
23
|
export * from "./field_map_size.js";
|
|
@@ -23,15 +27,14 @@ export * from "./field_radius_x.js";
|
|
|
23
27
|
export * from "./field_radius_y.js";
|
|
24
28
|
export * from "./field_radius_z.js";
|
|
25
29
|
export * from "./field_relay_servers.js";
|
|
26
|
-
export * from "./action_random.js";
|
|
27
30
|
export * from "./field_seed.js";
|
|
28
31
|
export * from "./field_size.js";
|
|
29
32
|
export * from "./field_spikiness.js";
|
|
30
33
|
export * from "./field_subdivisions.js";
|
|
34
|
+
export * from "./field_surface_detail.js";
|
|
31
35
|
export * from "./field_ticket_or_invitation_url.js";
|
|
32
36
|
export * from "./field_tutorial_mode.js";
|
|
33
37
|
export * from "./field_void_fraction.js";
|
|
34
|
-
export * from "./shape_label.js";
|
|
35
38
|
export * from "./label_advanced_settings.js";
|
|
36
39
|
export * from "./label_players.js";
|
|
37
40
|
export * from "./label_safe_cells_explored.js";
|
|
@@ -43,12 +46,15 @@ export * from "./preset_custom.js";
|
|
|
43
46
|
export * from "./preset_large.js";
|
|
44
47
|
export * from "./preset_medium.js";
|
|
45
48
|
export * from "./preset_small.js";
|
|
49
|
+
export * from "./shape_label.js";
|
|
46
50
|
export * from "./status_generating_map.js";
|
|
47
51
|
export * from "./status_initialization_failed.js";
|
|
48
52
|
export * from "./status_joining_game.js";
|
|
49
53
|
export * from "./status_loading.js";
|
|
50
54
|
export * from "./status_preparing.js";
|
|
51
55
|
export * from "./text_avoided.js";
|
|
56
|
+
export * from "./text_density_summary.js";
|
|
57
|
+
export * from "./text_invite_after_opening.js";
|
|
52
58
|
export * from "./text_relay_servers_hint.js";
|
|
53
59
|
export * from "./tutorial_action_dismiss.js";
|
|
54
60
|
export * from "./tutorial_action_next.js";
|
|
@@ -58,10 +64,4 @@ export * from "./tutorial_after_void.js";
|
|
|
58
64
|
export * from "./tutorial_awaiting_first_click.js";
|
|
59
65
|
export * from "./tutorial_intro.js";
|
|
60
66
|
export * from "./tutorial_won.js";
|
|
61
|
-
export * from "./field_cell_density.js";
|
|
62
|
-
export * from "./cells_per_face.js";
|
|
63
|
-
export * from "./faces_count.js";
|
|
64
|
-
export * from "./field_surface_detail.js";
|
|
65
|
-
export * from "./text_density_summary.js";
|
|
66
|
-
export * from "./text_invite_after_opening.js";
|
|
67
67
|
export type LocalizedString = import("../runtime.js").LocalizedString;
|
|
@@ -7,15 +7,19 @@ export * from './action_invite.js'
|
|
|
7
7
|
export * from './action_join.js'
|
|
8
8
|
export * from './action_join_game.js'
|
|
9
9
|
export * from './action_new_game.js'
|
|
10
|
+
export * from './action_random.js'
|
|
10
11
|
export * from './action_start.js'
|
|
11
12
|
export * from './aria_close_invitation.js'
|
|
12
13
|
export * from './aria_score_summary.js'
|
|
13
14
|
export * from './cells_count.js'
|
|
15
|
+
export * from './cells_per_face.js'
|
|
14
16
|
export * from './default_player_name.js'
|
|
15
17
|
export * from './error_join_connect_failed.js'
|
|
16
18
|
export * from './error_join_failed.js'
|
|
17
19
|
export * from './error_join_ticket_invalid.js'
|
|
18
20
|
export * from './error_join_ticket_required.js'
|
|
21
|
+
export * from './faces_count.js'
|
|
22
|
+
export * from './field_cell_density.js'
|
|
19
23
|
export * from './field_invitation_url.js'
|
|
20
24
|
export * from './field_map_shape.js'
|
|
21
25
|
export * from './field_map_size.js'
|
|
@@ -25,15 +29,14 @@ export * from './field_radius_x.js'
|
|
|
25
29
|
export * from './field_radius_y.js'
|
|
26
30
|
export * from './field_radius_z.js'
|
|
27
31
|
export * from './field_relay_servers.js'
|
|
28
|
-
export * from './action_random.js'
|
|
29
32
|
export * from './field_seed.js'
|
|
30
33
|
export * from './field_size.js'
|
|
31
34
|
export * from './field_spikiness.js'
|
|
32
35
|
export * from './field_subdivisions.js'
|
|
36
|
+
export * from './field_surface_detail.js'
|
|
33
37
|
export * from './field_ticket_or_invitation_url.js'
|
|
34
38
|
export * from './field_tutorial_mode.js'
|
|
35
39
|
export * from './field_void_fraction.js'
|
|
36
|
-
export * from './shape_label.js'
|
|
37
40
|
export * from './label_advanced_settings.js'
|
|
38
41
|
export * from './label_players.js'
|
|
39
42
|
export * from './label_safe_cells_explored.js'
|
|
@@ -45,12 +48,15 @@ export * from './preset_custom.js'
|
|
|
45
48
|
export * from './preset_large.js'
|
|
46
49
|
export * from './preset_medium.js'
|
|
47
50
|
export * from './preset_small.js'
|
|
51
|
+
export * from './shape_label.js'
|
|
48
52
|
export * from './status_generating_map.js'
|
|
49
53
|
export * from './status_initialization_failed.js'
|
|
50
54
|
export * from './status_joining_game.js'
|
|
51
55
|
export * from './status_loading.js'
|
|
52
56
|
export * from './status_preparing.js'
|
|
53
57
|
export * from './text_avoided.js'
|
|
58
|
+
export * from './text_density_summary.js'
|
|
59
|
+
export * from './text_invite_after_opening.js'
|
|
54
60
|
export * from './text_relay_servers_hint.js'
|
|
55
61
|
export * from './tutorial_action_dismiss.js'
|
|
56
62
|
export * from './tutorial_action_next.js'
|
|
@@ -59,10 +65,4 @@ export * from './tutorial_after_safe_guess.js'
|
|
|
59
65
|
export * from './tutorial_after_void.js'
|
|
60
66
|
export * from './tutorial_awaiting_first_click.js'
|
|
61
67
|
export * from './tutorial_intro.js'
|
|
62
|
-
export * from './tutorial_won.js'
|
|
63
|
-
export * from './field_cell_density.js'
|
|
64
|
-
export * from './cells_per_face.js'
|
|
65
|
-
export * from './faces_count.js'
|
|
66
|
-
export * from './field_surface_detail.js'
|
|
67
|
-
export * from './text_density_summary.js'
|
|
68
|
-
export * from './text_invite_after_opening.js'
|
|
68
|
+
export * from './tutorial_won.js'
|
|
@@ -24,6 +24,6 @@ const bn_action_back = /** @type {(inputs: Action_BackInputs) => LocalizedString
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_back = /** @type {((inputs?: Action_BackInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_BackInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_back(inputs)
|
|
28
|
+
return en_action_back(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_copy = /** @type {(inputs: Action_CopyInputs) => LocalizedString
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_copy = /** @type {((inputs?: Action_CopyInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_CopyInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_copy(inputs)
|
|
28
|
+
return en_action_copy(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_exit = /** @type {(inputs: Action_ExitInputs) => LocalizedString
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_exit = /** @type {((inputs?: Action_ExitInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_ExitInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_exit(inputs)
|
|
28
|
+
return en_action_exit(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_invite = /** @type {(inputs: Action_InviteInputs) => LocalizedSt
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_invite = /** @type {((inputs?: Action_InviteInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_InviteInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_invite(inputs)
|
|
28
|
+
return en_action_invite(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_join = /** @type {(inputs: Action_JoinInputs) => LocalizedString
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_join = /** @type {((inputs?: Action_JoinInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_JoinInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_join(inputs)
|
|
28
|
+
return en_action_join(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_join_game = /** @type {(inputs: Action_Join_GameInputs) => Local
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_join_game = /** @type {((inputs?: Action_Join_GameInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_Join_GameInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_join_game(inputs)
|
|
28
|
+
return en_action_join_game(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_new_game = /** @type {(inputs: Action_New_GameInputs) => Localiz
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_new_game = /** @type {((inputs?: Action_New_GameInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_New_GameInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_new_game(inputs)
|
|
28
|
+
return en_action_new_game(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_random = /** @type {(inputs: Action_RandomInputs) => LocalizedSt
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_random = /** @type {((inputs?: Action_RandomInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_RandomInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_random(inputs)
|
|
28
|
+
return en_action_random(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_action_start = /** @type {(inputs: Action_StartInputs) => LocalizedStri
|
|
|
24
24
|
*/
|
|
25
25
|
export const action_start = /** @type {((inputs?: Action_StartInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Action_StartInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_action_start(inputs)
|
|
28
|
+
return en_action_start(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_aria_close_invitation = /** @type {(inputs: Aria_Close_InvitationInputs
|
|
|
24
24
|
*/
|
|
25
25
|
export const aria_close_invitation = /** @type {((inputs?: Aria_Close_InvitationInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Aria_Close_InvitationInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_aria_close_invitation(inputs)
|
|
28
|
+
return en_aria_close_invitation(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_aria_score_summary = /** @type {(inputs: Aria_Score_SummaryInputs) => L
|
|
|
24
24
|
*/
|
|
25
25
|
export const aria_score_summary = /** @type {((inputs?: Aria_Score_SummaryInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Aria_Score_SummaryInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_aria_score_summary(inputs)
|
|
28
|
+
return en_aria_score_summary(inputs)
|
|
29
29
|
});
|
|
@@ -28,6 +28,6 @@ const bn_cells_count = /** @type {(inputs: Cells_CountInputs) => LocalizedString
|
|
|
28
28
|
*/
|
|
29
29
|
export const cells_count = /** @type {((inputs: Cells_CountInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Cells_CountInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
|
|
30
30
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
31
|
-
if (locale === "
|
|
32
|
-
return
|
|
31
|
+
if (locale === "bn") return bn_cells_count(inputs)
|
|
32
|
+
return en_cells_count(inputs)
|
|
33
33
|
});
|
|
@@ -24,6 +24,6 @@ const bn_cells_per_face = /** @type {(inputs: Cells_Per_FaceInputs) => Localized
|
|
|
24
24
|
*/
|
|
25
25
|
export const cells_per_face = /** @type {((inputs: Cells_Per_FaceInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Cells_Per_FaceInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_cells_per_face(inputs)
|
|
28
|
+
return en_cells_per_face(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_default_player_name = /** @type {(inputs: Default_Player_NameInputs) =>
|
|
|
24
24
|
*/
|
|
25
25
|
export const default_player_name = /** @type {((inputs?: Default_Player_NameInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Default_Player_NameInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_default_player_name(inputs)
|
|
28
|
+
return en_default_player_name(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_error_join_connect_failed = /** @type {(inputs: Error_Join_Connect_Fail
|
|
|
24
24
|
*/
|
|
25
25
|
export const error_join_connect_failed = /** @type {((inputs?: Error_Join_Connect_FailedInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Error_Join_Connect_FailedInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_error_join_connect_failed(inputs)
|
|
28
|
+
return en_error_join_connect_failed(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_error_join_failed = /** @type {(inputs: Error_Join_FailedInputs) => Loc
|
|
|
24
24
|
*/
|
|
25
25
|
export const error_join_failed = /** @type {((inputs?: Error_Join_FailedInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Error_Join_FailedInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_error_join_failed(inputs)
|
|
28
|
+
return en_error_join_failed(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_error_join_ticket_invalid = /** @type {(inputs: Error_Join_Ticket_Inval
|
|
|
24
24
|
*/
|
|
25
25
|
export const error_join_ticket_invalid = /** @type {((inputs?: Error_Join_Ticket_InvalidInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Error_Join_Ticket_InvalidInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_error_join_ticket_invalid(inputs)
|
|
28
|
+
return en_error_join_ticket_invalid(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_error_join_ticket_required = /** @type {(inputs: Error_Join_Ticket_Requ
|
|
|
24
24
|
*/
|
|
25
25
|
export const error_join_ticket_required = /** @type {((inputs?: Error_Join_Ticket_RequiredInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Error_Join_Ticket_RequiredInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_error_join_ticket_required(inputs)
|
|
28
|
+
return en_error_join_ticket_required(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_faces_count = /** @type {(inputs: Faces_CountInputs) => LocalizedString
|
|
|
24
24
|
*/
|
|
25
25
|
export const faces_count = /** @type {((inputs: Faces_CountInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Faces_CountInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_faces_count(inputs)
|
|
28
|
+
return en_faces_count(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_cell_density = /** @type {(inputs: Field_Cell_DensityInputs) => L
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_cell_density = /** @type {((inputs?: Field_Cell_DensityInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Cell_DensityInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_cell_density(inputs)
|
|
28
|
+
return en_field_cell_density(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_invitation_url = /** @type {(inputs: Field_Invitation_UrlInputs)
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_invitation_url = /** @type {((inputs?: Field_Invitation_UrlInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Invitation_UrlInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_invitation_url(inputs)
|
|
28
|
+
return en_field_invitation_url(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_map_shape = /** @type {(inputs: Field_Map_ShapeInputs) => Localiz
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_map_shape = /** @type {((inputs?: Field_Map_ShapeInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Map_ShapeInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_map_shape(inputs)
|
|
28
|
+
return en_field_map_shape(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_map_size = /** @type {(inputs: Field_Map_SizeInputs) => Localized
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_map_size = /** @type {((inputs?: Field_Map_SizeInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Map_SizeInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_map_size(inputs)
|
|
28
|
+
return en_field_map_size(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_player_name = /** @type {(inputs: Field_Player_NameInputs) => Loc
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_player_name = /** @type {((inputs?: Field_Player_NameInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Player_NameInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_player_name(inputs)
|
|
28
|
+
return en_field_player_name(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_radius = /** @type {(inputs: Field_RadiusInputs) => LocalizedStri
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_radius = /** @type {((inputs?: Field_RadiusInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_RadiusInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_radius(inputs)
|
|
28
|
+
return en_field_radius(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_radius_x = /** @type {(inputs: Field_Radius_XInputs) => Localized
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_radius_x = /** @type {((inputs?: Field_Radius_XInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Radius_XInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_radius_x(inputs)
|
|
28
|
+
return en_field_radius_x(inputs)
|
|
29
29
|
});
|
|
@@ -24,6 +24,6 @@ const bn_field_radius_y = /** @type {(inputs: Field_Radius_YInputs) => Localized
|
|
|
24
24
|
*/
|
|
25
25
|
export const field_radius_y = /** @type {((inputs?: Field_Radius_YInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Radius_YInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
26
|
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
-
if (locale === "
|
|
28
|
-
return
|
|
27
|
+
if (locale === "bn") return bn_field_radius_y(inputs)
|
|
28
|
+
return en_field_radius_y(inputs)
|
|
29
29
|
});
|