mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-04-25 22:46:15 -04:00
wip
This commit is contained in:
parent
9624c5b351
commit
e78021ff83
24 changed files with 840 additions and 437 deletions
|
@ -14,7 +14,7 @@ export function startingPerkMenuButton() {
|
|||
},
|
||||
};
|
||||
}
|
||||
function isChecked(u: Upgrade): boolean {
|
||||
export function isStartingPerk(u: Upgrade): boolean {
|
||||
return getSettingValue("start_with_" + u.id, u.giftable);
|
||||
}
|
||||
|
||||
|
@ -24,9 +24,9 @@ export async function openStartingPerksEditor() {
|
|||
(u) =>
|
||||
!u.requires && !["instant_upgrade"].includes(u.id) && u.threshold <= ts,
|
||||
);
|
||||
const starting = avaliable.filter((u) => isChecked(u));
|
||||
const starting = avaliable.filter((u) => isStartingPerk(u));
|
||||
const buttons = avaliable.map((u) => {
|
||||
const checked = isChecked(u);
|
||||
const checked = isStartingPerk(u);
|
||||
return {
|
||||
icon: u.icon,
|
||||
text: u.name,
|
||||
|
@ -48,7 +48,7 @@ export async function openStartingPerksEditor() {
|
|||
],
|
||||
});
|
||||
if (perk) {
|
||||
setSettingValue("start_with_" + perk.id, !isChecked(perk));
|
||||
setSettingValue("start_with_" + perk.id, !isStartingPerk(perk));
|
||||
openStartingPerksEditor();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue