mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-13 13:04:03 +00:00
initial test
This commit is contained in:
parent
05418c2163
commit
b23ef37992
@ -28,6 +28,7 @@ import { createLogger } from "../../core/logging";
|
|||||||
import { HUDPuzzleCompleteNotification } from "../hud/parts/puzzle_complete_notification";
|
import { HUDPuzzleCompleteNotification } from "../hud/parts/puzzle_complete_notification";
|
||||||
import { HUDPuzzlePlaySettings } from "../hud/parts/puzzle_play_settings";
|
import { HUDPuzzlePlaySettings } from "../hud/parts/puzzle_play_settings";
|
||||||
import { MetaBlockBuilding } from "../buildings/block";
|
import { MetaBlockBuilding } from "../buildings/block";
|
||||||
|
import { MetaBuilding } from "../meta_building";
|
||||||
|
|
||||||
const logger = createLogger("puzzle-play");
|
const logger = createLogger("puzzle-play");
|
||||||
const copy = require("clipboard-copy");
|
const copy = require("clipboard-copy");
|
||||||
@ -45,6 +46,7 @@ export class PuzzlePlayGameMode extends PuzzleGameMode {
|
|||||||
constructor(root, { puzzle }) {
|
constructor(root, { puzzle }) {
|
||||||
super(root);
|
super(root);
|
||||||
|
|
||||||
|
/** @type {(typeof MetaBuilding)[]} */
|
||||||
this.hiddenBuildings = [
|
this.hiddenBuildings = [
|
||||||
MetaConstantProducerBuilding,
|
MetaConstantProducerBuilding,
|
||||||
MetaGoalAcceptorBuilding,
|
MetaGoalAcceptorBuilding,
|
||||||
@ -67,6 +69,7 @@ export class PuzzlePlayGameMode extends PuzzleGameMode {
|
|||||||
MetaComparatorBuilding,
|
MetaComparatorBuilding,
|
||||||
MetaTransistorBuilding,
|
MetaTransistorBuilding,
|
||||||
];
|
];
|
||||||
|
this.hiddenBuildings.push(puzzle.game.excludedBuildings);
|
||||||
|
|
||||||
this.additionalHudParts.puzzlePlayMetadata = HUDPuzzlePlayMetadata;
|
this.additionalHudParts.puzzlePlayMetadata = HUDPuzzlePlayMetadata;
|
||||||
this.additionalHudParts.puzzlePlaySettings = HUDPuzzlePlaySettings;
|
this.additionalHudParts.puzzlePlaySettings = HUDPuzzlePlaySettings;
|
||||||
|
@ -90,6 +90,7 @@ export class PuzzleSerializer {
|
|||||||
w: mode.zoneWidth,
|
w: mode.zoneWidth,
|
||||||
h: mode.zoneHeight,
|
h: mode.zoneHeight,
|
||||||
},
|
},
|
||||||
|
excludedBuildings: [],
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,6 +41,8 @@
|
|||||||
* }} SavegamesData
|
* }} SavegamesData
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
import { MetaBuilding } from "../game/meta_building";
|
||||||
|
|
||||||
// Notice: Update backend too
|
// Notice: Update backend too
|
||||||
/**
|
/**
|
||||||
* @typedef {{
|
* @typedef {{
|
||||||
@ -84,7 +86,8 @@
|
|||||||
* @typedef {{
|
* @typedef {{
|
||||||
* version: number;
|
* version: number;
|
||||||
* bounds: { w: number; h: number; },
|
* bounds: { w: number; h: number; },
|
||||||
* buildings: (PuzzleGameBuildingGoal | PuzzleGameBuildingConstantProducer | PuzzleGameBuildingBlock)[]
|
* buildings: (PuzzleGameBuildingGoal | PuzzleGameBuildingConstantProducer | PuzzleGameBuildingBlock)[],
|
||||||
|
* excludedBuildings: (typeof MetaBuilding)[],
|
||||||
* }} PuzzleGameData
|
* }} PuzzleGameData
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user