summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDizzyEggg <jajkodizzy@wp.pl>2017-08-27 14:01:30 +0200
committerDizzyEggg <jajkodizzy@wp.pl>2017-08-27 14:01:30 +0200
commit4a195f5009a16955e37d5898ab8d8a6b385cd5cc (patch)
tree80f61b597b86e4d9cf4b78c09a702266e48e6d1d /include
parentd4a7bcf4808f94e6d961d7788330ce8842d7cf97 (diff)
parent1a33ca381de71bb3b4b250a2f3b41b0c15ed5f21 (diff)
Merge branch 'master' into decompile_evolution_scene
Diffstat (limited to 'include')
-rw-r--r--include/money.h2
-rw-r--r--include/shop.h36
-rw-r--r--include/text.h58
3 files changed, 63 insertions, 33 deletions
diff --git a/include/money.h b/include/money.h
index 49015ee19..06ac00e92 100644
--- a/include/money.h
+++ b/include/money.h
@@ -7,7 +7,7 @@ void sub_80B79E0(u32 *, u32);
void sub_80B79F8(u8 *buffer, u32 arg1, u8 arg2);
void sub_80B7A94(u32 arg0, u8 arg1, u8 x, u8 y);
void sub_80B7AEC(u32, u8 left, u8 top);
-void sub_80B7B34(void);
+void sub_80B7B34(u8, u8, int);
void sub_80B7BEC(u32, u8, u8);
void sub_80B7C14(u32, u8, u8);
void RemoveMoneyLabelObject(u8, u8);
diff --git a/include/shop.h b/include/shop.h
index cca6091c9..b785ca764 100644
--- a/include/shop.h
+++ b/include/shop.h
@@ -1,6 +1,34 @@
#ifndef GUARD_SHOP_H
#define GUARD_SHOP_H
+enum
+{
+ MART_TYPE_0, // normal mart
+ MART_TYPE_1,
+ MART_TYPE_2,
+};
+
+// shop view window NPC info enum
+enum
+{
+ MAP_OBJ_ID,
+ X_COORD,
+ Y_COORD,
+ ANIM_NUM
+};
+
+struct MartInfo
+{
+ /* 0x0 */ void (* callback) (void);
+ /* 0x4 */ u16 *itemList;
+ /* 0x8 */ u8 itemCount; // how many unique items are there for sale?
+ /* 0x9 */ u8 cursor; // this shows the on-screen true index of the cursor and not the current item selected.
+ /* 0xA */ u8 numChoices; // how many options does the mart have? can be either 2 or 1 (BUY/SELL vs BUY)
+ /* 0xB */ u8 choicesAbove; // when your cursor is far down, there are choices that have scrolled up past the top. this is the count of that.
+ /* 0xC */ u8 martType; // 0-2. 0 is normal mart while 1-2 seem to be decor shops or non-stackable purchases in general.
+ /* 0xD */ u8 curItemCount; // if you are selling an item, this is the count of the current item stack you have.
+};
+
void sub_80B2E38(u8);
void HandleShopMenuQuit(u8);
void sub_80B2FA0(u8);
@@ -11,8 +39,10 @@ void BuyMenuDrawMapGraphics(void);
void sub_80B3764(int, int);
void sub_80B37EC(void);
void sub_80B40E8(u8);
-void CreatePokemartMenu(void *);
-void CreateDecorationShop1Menu(void *);
-void CreateDecorationShop2Menu(void *);
+void CreatePokemartMenu(u16 *);
+void CreateDecorationShop1Menu(u16 *);
+void CreateDecorationShop2Menu(u16 *);
+void sub_80B356C(void);
+void sub_80B368C(void);
#endif // GUARD_SHOP_H
diff --git a/include/text.h b/include/text.h
index 99987d2c3..9a70dec11 100644
--- a/include/text.h
+++ b/include/text.h
@@ -97,35 +97,35 @@ struct WindowConfig
struct Window
{
- u8 textMode;
- u8 fontNum;
- u8 language;
- u8 foregroundColor;
- u8 backgroundColor;
- u8 shadowColor;
- u8 paletteNum;
- u8 tilemapLeft;
- u8 tilemapTop;
- u8 width;
- u8 height;
- u8 win_field_B;
- u8 win_field_C;
- u8 delayCounter;
- u8 spacing;
- u8 win_field_F;
- u8 cursorX;
- u8 cursorY;
- u8 left;
- u16 top;
- u16 state;
- u16 downArrowCounter;
- u16 tileDataStartOffset;
- u16 tileDataOffset;
- u16 textIndex;
- const u8 *text;
- u8 *tileData;
- u16 *tilemap;
- struct WindowConfig *config;
+ /*0x00*/ u8 textMode;
+ /*0x01*/ u8 fontNum;
+ /*0x02*/ u8 language;
+ /*0x03*/ u8 foregroundColor;
+ /*0x04*/ u8 backgroundColor;
+ /*0x05*/ u8 shadowColor;
+ /*0x06*/ u8 paletteNum;
+ /*0x07*/ u8 tilemapLeft;
+ /*0x08*/ u8 tilemapTop;
+ /*0x09*/ u8 width;
+ /*0x0A*/ u8 height;
+ /*0x0B*/ u8 win_field_B;
+ /*0x0C*/ u8 win_field_C;
+ /*0x0D*/ u8 delayCounter;
+ /*0x0E*/ u8 spacing;
+ /*0x0F*/ u8 win_field_F;
+ /*0x10*/ u8 cursorX;
+ /*0x11*/ u8 cursorY;
+ /*0x12*/ u8 left;
+ /*0x14*/ u16 top; // padded to 0x14
+ /*0x16*/ u16 state;
+ /*0x18*/ u16 downArrowCounter;
+ /*0x1A*/ u16 tileDataStartOffset;
+ /*0x1C*/ u16 tileDataOffset;
+ /*0x1E*/ u16 textIndex;
+ /*0x20*/ const u8 *text;
+ /*0x24*/ u8 *tileData;
+ /*0x28*/ u16 *tilemap;
+ /*0x2C*/ struct WindowConfig *config;
};
extern vu16 *const gBGControlRegs[];