1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2025-12-16 11:41:50 +00:00

Get shape-percentage and use it in root.map

Signed-off-by: Daan Breur <git@daanbreur.systems>
This commit is contained in:
Daan Breur 2021-11-27 15:32:48 +01:00
parent ca12bcaaa3
commit ceb54c69b6
No known key found for this signature in database
GPG Key ID: FAD44580052ECA57

View File

@ -170,12 +170,16 @@ export class GameCore {
* @param {object} param1 * @param {object} param1
* @param {number} param1.seed * @param {number} param1.seed
* @param {boolean} param1.allowNonPrimaryColors * @param {boolean} param1.allowNonPrimaryColors
* @param {number} param1.fullShapePercentage
* @param {number} param1.wierdShapePercentage
* */ * */
initNewGame({ seed, allowNonPrimaryColors }) { initNewGame({ seed, allowNonPrimaryColors, fullShapePercentage, wierdShapePercentage }) {
logger.log("Initializing new game"); logger.log("Initializing new game");
this.root.gameIsFresh = true; this.root.gameIsFresh = true;
this.root.map.seed = seed; this.root.map.seed = seed;
this.root.map.allowNonPrimaryColors = allowNonPrimaryColors; this.root.map.allowNonPrimaryColors = allowNonPrimaryColors;
this.root.map.fullShapePercentage = fullShapePercentage;
this.root.map.wierdShapePercentage = wierdShapePercentage;
logger.log("Initializing newGame with seed: ", this.root.map.seed); logger.log("Initializing newGame with seed: ", this.root.map.seed);