@hadoku/game-server 0.1.27 → 0.1.29
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/room/room-list.d.ts
CHANGED
|
@@ -44,7 +44,7 @@ export interface RoomBusyHook<R> {
|
|
|
44
44
|
}
|
|
45
45
|
/** The plain rule: no live match it can see, no extra reason to stay offered, an 8-hour idle window, never spared. What a room wires if its game has nothing extra to say. */
|
|
46
46
|
export declare const NO_BUSY_HOOK: RoomBusyHook<unknown>;
|
|
47
|
-
/**
|
|
47
|
+
/** Newest room first, with the (random) room id as a tie-break for two rooms made in the same millisecond — `list()`'s and `offered()`'s shared sort. */
|
|
48
48
|
export declare function sortRoomsByCreation<R extends {
|
|
49
49
|
id: string;
|
|
50
50
|
createdAt: number;
|
package/dist/room/room-list.js
CHANGED
|
@@ -22,9 +22,9 @@ export const NO_BUSY_HOOK = {
|
|
|
22
22
|
defaultIdleMs: () => 8 * 60 * 60_000,
|
|
23
23
|
sparedFromSweep: () => false,
|
|
24
24
|
};
|
|
25
|
-
/**
|
|
25
|
+
/** Newest room first, with the (random) room id as a tie-break for two rooms made in the same millisecond — `list()`'s and `offered()`'s shared sort. */
|
|
26
26
|
export function sortRoomsByCreation(rooms) {
|
|
27
|
-
return [...rooms].sort((a, b) =>
|
|
27
|
+
return [...rooms].sort((a, b) => b.createdAt - a.createdAt || (a.id < b.id ? -1 : 1));
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
30
|
* Whether `room` belongs on the front page right now: a seeded testing room
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hadoku/game-server",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"gitHead": "
|
|
3
|
+
"version": "0.1.29",
|
|
4
|
+
"gitHead": "ea618fa2509658efa7050ea64ceb8b9b4cbbb7e7",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"description": "The server parts any hosted game shares, above the kernel: the app config and edge auth, the room core (identity, seats, sessions, membership, the room list, the generic room routes), match hosting (the host contract, local and remote JVMs, placement, the start queue, recordings, the in-process and relay runtimes), streams, erase, telemetry and usage. Knows no game; Magic plugs in from apps/server. MIT; imports only node built-ins, express, socket.io, @wolffm/* and the platform packages.",
|
|
@@ -16,12 +16,12 @@
|
|
|
16
16
|
"play/remote/"
|
|
17
17
|
],
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@wolffm/host-wire": "npm:@hadoku/host-wire@0.1.
|
|
20
|
-
"@wolffm/platform-wire": "npm:@hadoku/platform-wire@0.1.
|
|
21
|
-
"@wolffm/service-kernel": "npm:@hadoku/service-kernel@0.1.
|
|
19
|
+
"@wolffm/host-wire": "npm:@hadoku/host-wire@0.1.29",
|
|
20
|
+
"@wolffm/platform-wire": "npm:@hadoku/platform-wire@0.1.29",
|
|
21
|
+
"@wolffm/service-kernel": "npm:@hadoku/service-kernel@0.1.62",
|
|
22
22
|
"@wolffm/prefs-client": "npm:@hadoku/prefs-client@^1.1.27",
|
|
23
|
-
"@wolffm/rooms-protocol": "npm:@hadoku/rooms-protocol@^0.45.
|
|
24
|
-
"@wolffm/rooms-server": "npm:@hadoku/rooms-server@^0.45.
|
|
23
|
+
"@wolffm/rooms-protocol": "npm:@hadoku/rooms-protocol@^0.45.103",
|
|
24
|
+
"@wolffm/rooms-server": "npm:@hadoku/rooms-server@^0.45.103",
|
|
25
25
|
"express": "^5.1.0",
|
|
26
26
|
"socket.io": "^4.8.3",
|
|
27
27
|
"zod": "4.5.4"
|