From 1d42d8ea5ff0536cbfd3de531d0d916dbed8fbf0 Mon Sep 17 00:00:00 2001 From: unsoftcapped3 <75136164+unsoftcapped3@users.noreply.github.com> Date: Fri, 23 Dec 2022 02:04:58 +0000 Subject: [PATCH] fix grid --- src/data/layers/factory.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/data/layers/factory.tsx b/src/data/layers/factory.tsx index 43513d0..d8cd41c 100644 --- a/src/data/layers/factory.tsx +++ b/src/data/layers/factory.tsx @@ -30,7 +30,7 @@ import { noPersist, Persistent, persistent, State } from "game/persistence"; import Decimal, { DecimalSource, format, formatWhole } from "util/bignum"; import { Direction } from "util/common"; import { ProcessedComputable } from "util/computed"; -import { render, renderGrid, renderRow } from "util/vue"; +import { render, renderGrid, renderRow, VueFeature } from "util/vue"; import { computed, ComputedRef, reactive, ref, unref, watchEffect } from "vue"; import _cloth from "../symbols/cloth.png"; import _dye from "../symbols/dyes.png"; @@ -1097,7 +1097,7 @@ const factory = createLayer(id, () => { ] // pixi - const upgradeAmount = computed(() => Object.values(upgrades).filter(u => u.bought.value).length) as ComputedRef + const upgradeAmount = computed(() => upgrades.flat().filter(u => u.bought.value).length) as ComputedRef // load every sprite here so pixi doesn't complain about loading multiple times const assetsLoading = Promise.all([ Assets.load(Object.values(FACTORY_COMPONENTS).map(x => x.imageSrc)), @@ -1856,7 +1856,7 @@ const factory = createLayer(id, () => { {renderRow(...Object.values(factoryBuyables))} - {renderGrid(upgrades as VueFeature[])} + {renderGrid(...upgrades as VueFeature[][])} )) })),