1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2025-06-13 13:04:03 +00:00

Added better support for hud parts

This commit is contained in:
DJ1TJOO 2021-02-28 20:39:51 +01:00
parent bd39112f10
commit ca5218561f
2 changed files with 6 additions and 0 deletions

View File

@ -112,6 +112,11 @@ export class GameHUD {
/* typehints:end */
};
for (const partKey in shapezAPI.ingame.hudParts) {
if (!shapezAPI.ingame.hudParts.hasOwnProperty(partKey)) continue;
this.parts[partKey] = shapezAPI.ingame.hudParts[partKey];
}
for (let i = 0; i < shapezAPI.ingame.layers.length; i++) {
const layer = shapezAPI.ingame.layers[i];
if (shapezAPI.toolbars[layer])

View File

@ -869,6 +869,7 @@ export class ShapezAPI {
this.ingame = {
buildings: {},
components: {},
hudParts: {},
//Must be array because of update order
systems: [],
items: {},