Skip to content

Commit 0b69d27

Browse files
committed
Update Utility
1 parent 0e269a2 commit 0b69d27

File tree

12 files changed

+2507
-573
lines changed

12 files changed

+2507
-573
lines changed

GSC/Utility/lethalbeats/DynamicMenus/dynamic_shop.gsc

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
#define TABLE "mp/dynamic_shop.csv"
22

3-
#define PAGE_NULL -1
4-
53
#define OPTION_BUY -5
64
#define OPTION_DISABLE -4
75
#define OPTION_OWNED -3
86
#define OPTION_UPGRADE -2
97
#define OPTION_SCRIPTRESPONSE -1
8+
// OPTION >= 0 -> item_price
109

1110
init()
1211
{
@@ -32,6 +31,14 @@ onMenuResponse()
3231
for (;;)
3332
{
3433
self waittill("menuresponse", menu, response);
34+
35+
if (menu == "class" && response == "back")
36+
{
37+
self closepopupMenu();
38+
self closeInGameMenu();
39+
continue;
40+
}
41+
3542
if (menu != "dynamic_shop") continue;
3643

3744
if (response == "close_self")
@@ -141,7 +148,7 @@ getIndex(page, item)
141148

142149
buyItem(price)
143150
{
144-
self lethalbeats\survival\_utility::setScore(self.score - int(price));
151+
if (isDefined(level.setMoney)) [[level.setMoney]](self.score - int(price));
145152
self playLocalSound("arcademode_checkpoint");
146153
self updateLabels();
147154
}
@@ -150,6 +157,6 @@ shopInit(menu)
150157
{
151158
self.shop = spawnstruct();
152159
self.shop.menu = menu;
153-
self.shop.page = PAGE_NULL;
160+
self.shop.page = -1;
154161
self.shop.owner = self;
155162
}

0 commit comments

Comments
 (0)