mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 11:39:50 +02:00
feat: some implementation for client unmounted mode
This commit is contained in:
1 parent
980fd6e50e
commit
ba4e6dfd68
7 files changed
+29
-26
No files matched your search
@@ -0,0 +1,3 @@
|
||||
export const clientUnmountedResponse = new Response(null, { status: 503 });
|
||||
|
||||
export const notFoundResponse = new Response(null, { status: 404 });
|
||||
@@ -1,5 +1,13 @@
|
||||
import { GameInterface } from "@blitzkit/game";
|
||||
|
||||
export const game = new GameInterface(
|
||||
"C:/Program Files (x86)/Steam/steamapps/common/World of Tanks Blitz Playtest",
|
||||
);
|
||||
export const clientUnmounted = !("WOTB_CLIENT" in import.meta.env);
|
||||
|
||||
let _game: GameInterface | null = null;
|
||||
|
||||
if (!clientUnmounted) {
|
||||
_game = new GameInterface(import.meta.env.WOTB_CLIENT);
|
||||
} else {
|
||||
console.warn("Running in client denied mode...");
|
||||
}
|
||||
|
||||
export const game = _game;
|
||||
Reference in new issue
Block a user