mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-11-23 06:04:32 +01:00
texture discovery
This commit is contained in:
1 parent
62b629fe3a
commit
a348e005f7
6 files changed
+117
-9
No files matched your search
@@ -1,6 +1,8 @@
|
||||
import { assertSecret } from "@blitzkit/core";
|
||||
import type { GameInterface } from "@blitzkit/game";
|
||||
import { clientUnmounted } from "./unmounted";
|
||||
import { api } from "../api/dynamic";
|
||||
import { assertDiscoveryTag } from "./assertDiscoveryTag";
|
||||
|
||||
let _game: GameInterface | null = null;
|
||||
|
||||
@@ -12,6 +14,17 @@ if (!clientUnmounted && import.meta.env.SSR) {
|
||||
assertSecret(import.meta.env.WOTB_USMAP),
|
||||
"../../temp",
|
||||
);
|
||||
|
||||
const tankTags: string[] = [];
|
||||
|
||||
for (const item of api.metadata.group("TankEntity")) {
|
||||
const assetDiscovery = item.BlitzStaticAssetsDiscovery();
|
||||
const tag = assertDiscoveryTag(assetDiscovery);
|
||||
|
||||
tankTags.push(tag);
|
||||
}
|
||||
|
||||
_game.discoverTextures(tankTags);
|
||||
}
|
||||
|
||||
export const game = _game;
|
||||
Reference in new issue
Block a user