diff options
author | PikalaxALT <pikalaxalt@gmail.com> | 2017-05-20 11:19:34 -0400 |
---|---|---|
committer | PikalaxALT <pikalaxalt@gmail.com> | 2017-05-20 11:19:34 -0400 |
commit | 39b15cb589dde612854ba1e0ea1365daccbfc7a2 (patch) | |
tree | b5e93819395304d6be41371807670e3af193a1b1 /src | |
parent | df3197f80818e7953c0572c6f23b2dd1ba7baf6b (diff) |
sub_80C004C
Diffstat (limited to 'src')
-rw-r--r-- | src/tv.c | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -1613,6 +1613,20 @@ _080C0048: .4byte gUnknown_03000722\n\ } #endif +u8 sub_80C004C(TVShow *tv1, TVShow *tv2, u8 idx) { + u32 linkTrainerId = GetLinkPlayerTrainerId(idx); + if ((linkTrainerId & 0xFF) == tv2->common.trainerIdLo && ((linkTrainerId >> 8) & 0xFF) == tv2->common.trainerIdHi) { + return FALSE; + } + tv2->common.trainerIdLo = tv2->common.srcTrainerIdLo; + tv2->common.trainerIdHi = tv2->common.srcTrainerIdHi; + tv2->common.srcTrainerIdLo = linkTrainerId & 0xFF; + tv2->common.srcTrainerIdHi = linkTrainerId >> 8; + *tv1 = *tv2; + tv1->common.var01 = 1; + return TRUE; +} + asm(".section .dotvshow\n"); void DoTVShowPokemonFanClubLetter(void); |