Made default layer option functions not anonymous

This commit is contained in:
thepaperpilot 2022-07-22 18:59:52 -05:00
parent fe865bff9d
commit c84bffae59
2 changed files with 4 additions and 4 deletions

View file

@ -10,13 +10,13 @@ import MainDisplay from "features/resources/MainDisplay.vue";
import { createResource } from "features/resources/resource";
import { addTooltip } from "features/tooltips/tooltip";
import { createResourceTooltip } from "features/trees/tree";
import { createLayer } from "game/layers";
import { BaseLayer, createLayer } from "game/layers";
import type { DecimalSource } from "util/bignum";
import { render } from "util/vue";
import { createLayerTreeNode, createResetButton } from "../common";
const id = "p";
const layer = createLayer(id, () => {
const layer = createLayer(id, function (this: BaseLayer) {
const name = "Prestige";
const color = "#4BDC13";
const points = createResource<DecimalSource>(0, "prestige points");

View file

@ -4,7 +4,7 @@ import { createResource, trackBest, trackOOMPS, trackTotal } from "features/reso
import type { GenericTree } from "features/trees/tree";
import { branchedResetPropagation, createTree } from "features/trees/tree";
import { globalBus } from "game/events";
import type { GenericLayer } from "game/layers";
import type { BaseLayer, GenericLayer } from "game/layers";
import { createLayer } from "game/layers";
import type { PlayerData } from "game/player";
import player from "game/player";
@ -17,7 +17,7 @@ import prestige from "./layers/prestige";
/**
* @hidden
*/
export const main = createLayer("main", () => {
export const main = createLayer("main", function (this: BaseLayer) {
const points = createResource<DecimalSource>(10);
const best = trackBest(points);
const total = trackTotal(points);