parametric game fules. minor simulator refactoring
This commit is contained in:
+12
-1
@@ -2,10 +2,21 @@ import { makeGame, ResourceGenerator, ResourceSet } from "@idle-economy/engine";
|
||||
import { makeAutoObservable } from "mobx";
|
||||
import { Notation, Presets } from 'eternal_notations';
|
||||
import { now } from "../tools/time";
|
||||
import { defaultGameRulesOptions, type GameRulesOptions } from "@idle-economy/engine/src/rulesets/rules";
|
||||
|
||||
const gameRulesOptions: GameRulesOptions = defaultGameRulesOptions;
|
||||
|
||||
// const gameRulesOptions: GameRulesOptions = {
|
||||
// startingResources: 0,
|
||||
// generationBasePrice: 1,
|
||||
// generationPower: 1.2,
|
||||
// upgradeBasePrice: 2000,
|
||||
// upgradeFactor: 1.01,
|
||||
// }
|
||||
|
||||
export class Root {
|
||||
|
||||
private readonly game = makeGame();
|
||||
private readonly game = makeGame(gameRulesOptions);
|
||||
|
||||
public resources: ResourceSet = new ResourceSet();
|
||||
public generators: ResourceGenerator[] = [];
|
||||
|
||||
Reference in New Issue
Block a user