summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPikalaxALT <pikalaxalt@gmail.com>2017-05-18 21:13:43 -0400
committerPikalaxALT <pikalaxalt@gmail.com>2017-05-18 21:13:43 -0400
commitf3e4f2f2104a86dc36415120b90c54793e324c39 (patch)
tree3ff5d07938a73d5aa2a77072fa501a91fc6df4c6
parentd4988da0cab8e88d390042d568641177ebb8ce41 (diff)
SetContestCategoryStringVarForInterview
-rw-r--r--asm/tv.s22
-rw-r--r--include/global.h9
-rw-r--r--src/tv.c9
3 files changed, 18 insertions, 22 deletions
diff --git a/asm/tv.s b/asm/tv.s
index 672f00003..cece28a79 100644
--- a/asm/tv.s
+++ b/asm/tv.s
@@ -2305,28 +2305,6 @@ _080BF058: .4byte gUnknown_083D1464
_080BF05C: .4byte gUnknown_083CE048
thumb_func_end CopyContestCategoryToStringVar
- thumb_func_start SetContestCategoryStringVarForInterview
-SetContestCategoryStringVarForInterview: @ 80BF060
- push {lr}
- ldr r0, _080BF080 @ =gSpecialVar_0x8004
- ldrh r1, [r0]
- lsls r0, r1, 3
- adds r0, r1
- lsls r0, 2
- ldr r1, _080BF084 @ =gSaveBlock1 + 0x2738
- adds r0, r1
- ldrb r1, [r0, 0x13]
- lsls r1, 29
- lsrs r1, 29
- movs r0, 0x1
- bl CopyContestCategoryToStringVar
- pop {r0}
- bx r0
- .align 2, 0
-_080BF080: .4byte gSpecialVar_0x8004
-_080BF084: .4byte gSaveBlock1 + 0x2738
- thumb_func_end SetContestCategoryStringVarForInterview
-
.section .text_80BF544
thumb_func_start sub_80BFF68
diff --git a/include/global.h b/include/global.h
index a6ab3eb63..086b858d0 100644
--- a/include/global.h
+++ b/include/global.h
@@ -298,6 +298,14 @@ struct TVShowSmartShopper {
u16 itemAmounts[3];
};
+struct TVShowContestWinner {
+ u8 var00;
+ u8 var01;
+ u8 pad02[17];
+ u8 contestCategory:3;
+ u8 var13_3:5;
+};
+
typedef union TVShow {
struct TVShowCommon common;
struct TVShowFanClubLetter fanclubLetter;
@@ -308,6 +316,7 @@ typedef union TVShow {
struct TVShowUnknownTVShowType unknownTvShowType;
struct TVShowUnknownTVShowType2 unknownTvShowType2;
struct TVShowSmartShopper smartshopperShow;
+ struct TVShowContestWinner contestShow;
} TVShow;
struct MailStruct
diff --git a/src/tv.c b/src/tv.c
index c66bafada..391429cf6 100644
--- a/src/tv.c
+++ b/src/tv.c
@@ -459,6 +459,15 @@ asm(".section .text_b");
void sub_80BF6D8(void);
void sub_80BF588(TVShow tvShows[]);
+void CopyContestCategoryToStringVar(u8 strvaridx, u8 category);
+
+void SetContestCategoryStringVarForInterview(void)
+{
+ TVShow *tvShow;
+ tvShow = &gSaveBlock1.tvShows.shows[gSpecialVar_0x8004];
+ CopyContestCategoryToStringVar(1, tvShow->contestShow.contestCategory);
+}
+
void sub_80BF088(u8 arg0, s32 price)
{
size_t log10val;