feat: More bonus (exponential) and method to list icons needed
This commit is contained in:
@@ -29,6 +29,7 @@ export function buildContext({
|
||||
achievements,
|
||||
investments,
|
||||
tabs,
|
||||
endless,
|
||||
}) {
|
||||
const generatorsById = byId(generators, 'generator');
|
||||
const upgradesById = byId(upgrades, 'upgrade');
|
||||
@@ -36,6 +37,7 @@ export function buildContext({
|
||||
const perksById = byId(legacy, 'legacy perk');
|
||||
const achievementsById = byId(achievements, 'achievement');
|
||||
const societiesById = byId(investments.societies, 'society');
|
||||
const endlessById = byId(endless, 'endless line');
|
||||
byId(tabs, 'tab');
|
||||
|
||||
for (const u of upgrades) {
|
||||
@@ -50,6 +52,12 @@ export function buildContext({
|
||||
if (!researchById.has(req)) throw new Error(`Research "${node.id}": unknown requirement "${req}"`);
|
||||
}
|
||||
}
|
||||
for (const line of endless) {
|
||||
checkEffect(`Endless "${line.id}"`, line.effect, generatorsById);
|
||||
if (line.requires && !upgradesById.has(line.requires)) {
|
||||
throw new Error(`Endless "${line.id}": unknown requirement "${line.requires}"`);
|
||||
}
|
||||
}
|
||||
for (const perk of legacy) checkEffect(`Perk "${perk.id}"`, perk.effect, generatorsById);
|
||||
for (const a of achievements) checkEffect(`Achievement "${a.id}"`, a.effect, generatorsById);
|
||||
for (const s of investments.societies) {
|
||||
@@ -65,11 +73,13 @@ export function buildContext({
|
||||
achievements,
|
||||
investments,
|
||||
tabs,
|
||||
endless,
|
||||
generatorsById,
|
||||
upgradesById,
|
||||
researchById,
|
||||
perksById,
|
||||
achievementsById,
|
||||
societiesById,
|
||||
endlessById,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user