import{_ as a,c as r,a0 as t,o}from"./chunks/framework.P9qPzDnn.js";const h=JSON.parse('{"title":"Function: setupAutoPurchase()","description":"","frontmatter":{"editLink":false},"headers":[],"relativePath":"api/features/clickables/upgrade/functions/setupAutoPurchase.md","filePath":"api/features/clickables/upgrade/functions/setupAutoPurchase.md","lastUpdated":null}'),s={name:"api/features/clickables/upgrade/functions/setupAutoPurchase.md"};function u(c,e,i,d,n,p){return o(),r("div",null,e[0]||(e[0]=[t('

Profectus / features/clickables/upgrade / setupAutoPurchase

Function: setupAutoPurchase()

setupAutoPurchase(layer, autoActive, upgrades): void

Utility to auto purchase a list of upgrades whenever they're affordable.

Parameters

layer

Layer

The layer the upgrades are apart of

autoActive

MaybeRefOrGetter<boolean>

Whether or not the upgrades should currently be auto-purchasing

upgrades

Upgrade[] = []

The specific upgrades to upgrade. If unspecified, uses all upgrades on the layer.

Returns

void

Defined in

profectus/src/features/clickables/upgrade.tsx:160

',18)]))}const f=a(s,[["render",u]]);export{h as __pageData,f as default};