mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-27 04:04:17 +01:00
52db3ad5aa
* ClearTVShowData * special_0x44 * DoTVShow (nonmatching because align) * DoTVShowBravoTrainerPokemonProfile * Update field names * DoTVShowBravoTrainerBattleTower * Renaming of struct fields * sub_80EBFF4 and UpdateTVScreensOnMap * SetTVMetatilesOnMap * Power buttons for the TV screens on the map * special_0x45 * sub_80EC18C * special_0x4a * ResetGabbyAndTy * GabbyAndTyBeforeInterview * GabbyAndTyAfterInterview * Through IsTVShowInSearchOfTrainersAiring * GabbyAndTyGetLastQuote * GabbyAndTyGetLastBattleTrivia * GabbyAndTySetScriptVarsToFieldObjectLocalIds * InterviewAfter; use TVShow as a precursor for making the individual show structs anonymous * Make TV structs anonymous within the union * Move the TV union to its own subheader * Move TV show enums to the global.tv.h subheader * Funcion renaming * Apply static attributes where able * PutPokemonTodayCaughtOnAir * sub_80EC8A4 * PutPokemonTodayFailedOnTheAir * sub_80EC9E8, sub_80ECA10 * sub_80ECA38 * sub_80ECB00 * Put3CheersForPokeblocksOnTheAir * PutFanClubSpecialOnTheAir * ContestLiveUpdates_BeforeInterview * Other before-interview Contest Live Updates functions * ContestLiveUpdates_BeforeInterview_5 * InterviewAfter_BravoTrainerPokemonProfile * BravoTrainerPokemonProfile_BeforeInterview1 * BravoTrainerPokemonProfile_BeforeInterview2 * Disassemble TV data * Decompile TV data * InterviewAfter_BravoTrainerBattleTowerProfile * SaveRecordedItemPurchasesForTVShow * PutNameRaterShowOnTheAir * StartMassOutbreak * PutLilycoveContestLadyShowOnTheAir * InterviewAfter_FanClubLetter * Rip TV strings * InterviewAfter_RecentHappenings * InterviewAfter_PkmnFanClubOpinions * sub_80ED718 * EndMassOutbreak * sub_80ED888 * sub_80ED8B4 * UpdateMassOutbreakTimeLeft * sub_80ED950 * PutFishingAdviceShowOnTheAir * through sub_80EDA80 * ewram and common syms are now fetched from the object files * BSS symbols are taken from the tv.o file * through sub_80EDC60 * sub_80EDCE8 * sub_80EDD78 * through sub_80EDE84 * nomatching sub_80EDE98 * sub_80EDFB4 * sub_80EE104 * sub_80EE104 * sub_80EE184 * sub_80EE2CC * sub_80EE35C * sub_80EE44C * sub_80EE4DC * sub_80EE5A4 * sub_80EE69C * sub_80EE72C * sub_80EE7C0 * sub_80EE818 * sub_80EE8C8 * sub_80EEA70 * sub_80EEB98 * sub_80EEBF4 * through sub_80EED60 * Functions relating to Pokemon News * sub_80EEF6C * GetPriceReduction * IsPriceDiscounted * sub_80EF120 * through sub_80EF370 * sub_80EF40C * HasMixableShowAlreadyBeenSpawnedWithPlayerID * TV_SortPurchasesByQuantity * FindActiveBroadcastByShowType_SetScriptResult * InterviewBefore * through sub_80EF88C * through sub_80EF93C * through sub_80EFA24 * through TV_BernoulliTrial * sub_80EFB58 * sub_80EFBA4 * sub_80EFBDC * through sub_80EFD98 * ChangePokemonNickname * ChangeBoxPokemonNickname * sub_80EFF9C * through player_id_to_dword * CheckForBigMovieOrEmergencyNewsOnTV * GetMomOrDadStringForTVMessage * sub_80F01E8 * sub_80F0358 * sub_80F049C * TV record mixing functions * sub_80F06D0 * sub_80F0708 nonmatching * through sub_80F0B24 * sub_80F0B64 * through sub_80F0C04 * sub_80F0C7C * sub_80F0D60 * sub_80F0E58 * sub_80F0E84 * through sub_80F0F24 * sub_80F0F64 * sub_80F1208 * sub_80F1254 * sub_80F1290 * sub_80F12A4 * sub_80F14F8 * DoTVShowTodaysSmartShopper * DoTVShowTheNameRaterShow * DoTVShowPokemonTodaySuccessfulCapture * DoTVShowPokemonTodayFailedCapture * DoTVShowPokemonFanClubLetter * DoTVShowRecentHappenings * DoTVShowPokemonFanClubOpinions * DoTVShowPokemonNewsMassOutbreak * DoTVShowPokemonContestLiveUpdates * DoTVShowPokemonBattleUpdate * DoTVShow3CheersForPokeblocks * DoTVShowInSearchOfTrainers * Label GabbyAndTyData fields; remove ddump comments from data/text/tv.inc * DoTVShowPokemonAngler * DoTVShowTheWorldOfMasters; update RAM symbols and field names * Decorate static functions * DoTVShowTodaysRivalTrainer; region map enums * TVDewfordTrendWatcherNetworkTextGroup * DoTVShowHoennTreasureInvestigators * DoTVShowFindThatGamer * DoTVShowBreakingNewsTV * DoTVShowSecretBaseVisit * DoTVShowPokemonLotterWinnerFlashReport * DoTVShowThePokemonBattleSeminar * DoTVShowTrainerFanClubSpecial, DoTVShowTrainerFanClub * DoTVShowSpotTheCuties * DoTVShowPokemonNewsBattleFrontier * DoTVShowWhatsNo1InHoennToday * Helpers for DoTVShowSecretBaseSecrets * DoTVShowSecretBaseSecrets * DoTVShowSafariFanClub * Finish decompilation of tv.s * Some renaming * Rename text group pointers * revoke statis; pokenews enums * Labels are number one * Label all TV struct fields * Make data/text/tv.inc more readable * Split data/text/tv.inc * Rename pokenews text pointers * Frontier Symbol constants; indicate static rodata objects with 's' prefix * Fix leading spaces/tabs F*** CLion sometimes * Fix inconsequential warning
338 lines
5.4 KiB
ArmAsm
338 lines
5.4 KiB
ArmAsm
.include "asm/macros.inc"
|
|
.include "constants/constants.inc"
|
|
|
|
.syntax unified
|
|
|
|
.text
|
|
|
|
thumb_func_start sub_8098128
|
|
sub_8098128: @ 8098128
|
|
ldr r1, =gUnknown_020375BC
|
|
movs r0, 0
|
|
strb r0, [r1]
|
|
ldr r2, =gTextFlags
|
|
ldrb r1, [r2]
|
|
movs r0, 0x2
|
|
negs r0, r0
|
|
ands r0, r1
|
|
movs r1, 0x3
|
|
negs r1, r1
|
|
ands r0, r1
|
|
subs r1, 0x2
|
|
ands r0, r1
|
|
subs r1, 0x4
|
|
ands r0, r1
|
|
strb r0, [r2]
|
|
bx lr
|
|
.pool
|
|
thumb_func_end sub_8098128
|
|
|
|
thumb_func_start sub_8098154
|
|
sub_8098154: @ 8098154
|
|
push {r4,r5,lr}
|
|
lsls r0, 24
|
|
lsrs r5, r0, 24
|
|
lsls r0, r5, 2
|
|
adds r0, r5
|
|
lsls r0, 3
|
|
ldr r1, =gTasks
|
|
adds r4, r0, r1
|
|
movs r1, 0x8
|
|
ldrsh r0, [r4, r1]
|
|
cmp r0, 0x1
|
|
beq _08098188
|
|
cmp r0, 0x1
|
|
bgt _0809817C
|
|
cmp r0, 0
|
|
beq _08098182
|
|
b _080981B0
|
|
.pool
|
|
_0809817C:
|
|
cmp r0, 0x2
|
|
beq _08098198
|
|
b _080981B0
|
|
_08098182:
|
|
bl sub_81973A4
|
|
b _08098190
|
|
_08098188:
|
|
movs r0, 0
|
|
movs r1, 0x1
|
|
bl sub_81973C4
|
|
_08098190:
|
|
ldrh r0, [r4, 0x8]
|
|
adds r0, 0x1
|
|
strh r0, [r4, 0x8]
|
|
b _080981B0
|
|
_08098198:
|
|
bl sub_8197224
|
|
lsls r0, 16
|
|
lsrs r0, 16
|
|
cmp r0, 0x1
|
|
beq _080981B0
|
|
ldr r1, =gUnknown_020375BC
|
|
movs r0, 0
|
|
strb r0, [r1]
|
|
adds r0, r5, 0
|
|
bl DestroyTask
|
|
_080981B0:
|
|
pop {r4,r5}
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end sub_8098154
|
|
|
|
thumb_func_start task_add_textbox
|
|
task_add_textbox: @ 80981BC
|
|
push {lr}
|
|
ldr r0, =sub_8098154
|
|
movs r1, 0x50
|
|
bl CreateTask
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end task_add_textbox
|
|
|
|
thumb_func_start task_del_textbox
|
|
task_del_textbox: @ 80981D0
|
|
push {lr}
|
|
ldr r0, =sub_8098154
|
|
bl FindTaskIdByFunc
|
|
lsls r0, 24
|
|
lsrs r0, 24
|
|
cmp r0, 0xFF
|
|
beq _080981E4
|
|
bl DestroyTask
|
|
_080981E4:
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end task_del_textbox
|
|
|
|
thumb_func_start ShowFieldMessage
|
|
ShowFieldMessage: @ 80981EC
|
|
push {r4,lr}
|
|
adds r1, r0, 0
|
|
ldr r4, =gUnknown_020375BC
|
|
ldrb r0, [r4]
|
|
cmp r0, 0
|
|
bne _0809820C
|
|
adds r0, r1, 0
|
|
movs r1, 0x1
|
|
bl textbox_fdecode_auto_and_task_add
|
|
movs r0, 0x2
|
|
strb r0, [r4]
|
|
movs r0, 0x1
|
|
b _0809820E
|
|
.pool
|
|
_0809820C:
|
|
movs r0, 0
|
|
_0809820E:
|
|
pop {r4}
|
|
pop {r1}
|
|
bx r1
|
|
thumb_func_end ShowFieldMessage
|
|
|
|
thumb_func_start sub_8098214
|
|
sub_8098214: @ 8098214
|
|
push {r4,lr}
|
|
lsls r0, 24
|
|
lsrs r4, r0, 24
|
|
bl sub_8196094
|
|
adds r1, r0, 0
|
|
cmp r1, 0
|
|
bne _0809822E
|
|
ldr r0, =gUnknown_020375BC
|
|
strb r1, [r0]
|
|
adds r0, r4, 0
|
|
bl DestroyTask
|
|
_0809822E:
|
|
pop {r4}
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end sub_8098214
|
|
|
|
thumb_func_start sub_8098238
|
|
sub_8098238: @ 8098238
|
|
push {r4,r5,lr}
|
|
adds r4, r0, 0
|
|
ldr r5, =gUnknown_020375BC
|
|
ldrb r0, [r5]
|
|
cmp r0, 0
|
|
bne _08098270
|
|
ldr r0, =gStringVar4
|
|
adds r1, r4, 0
|
|
bl StringExpandPlaceholders
|
|
ldr r0, =sub_8098214
|
|
movs r1, 0
|
|
bl CreateTask
|
|
adds r0, r4, 0
|
|
bl sub_8196080
|
|
movs r0, 0x2
|
|
strb r0, [r5]
|
|
movs r0, 0x1
|
|
b _08098272
|
|
.pool
|
|
_08098270:
|
|
movs r0, 0
|
|
_08098272:
|
|
pop {r4,r5}
|
|
pop {r1}
|
|
bx r1
|
|
thumb_func_end sub_8098238
|
|
|
|
thumb_func_start ShowFieldAutoScrollMessage
|
|
ShowFieldAutoScrollMessage: @ 8098278
|
|
push {lr}
|
|
adds r1, r0, 0
|
|
ldr r2, =gUnknown_020375BC
|
|
ldrb r0, [r2]
|
|
cmp r0, 0
|
|
bne _08098298
|
|
movs r0, 0x3
|
|
strb r0, [r2]
|
|
adds r0, r1, 0
|
|
movs r1, 0
|
|
bl textbox_fdecode_auto_and_task_add
|
|
movs r0, 0x1
|
|
b _0809829A
|
|
.pool
|
|
_08098298:
|
|
movs r0, 0
|
|
_0809829A:
|
|
pop {r1}
|
|
bx r1
|
|
thumb_func_end ShowFieldAutoScrollMessage
|
|
|
|
thumb_func_start sub_80982A0
|
|
sub_80982A0: @ 80982A0
|
|
push {lr}
|
|
ldr r2, =gUnknown_020375BC
|
|
movs r1, 0x3
|
|
strb r1, [r2]
|
|
movs r1, 0x1
|
|
bl textbox_fdecode_auto_and_task_add
|
|
movs r0, 0x1
|
|
pop {r1}
|
|
bx r1
|
|
.pool
|
|
thumb_func_end sub_80982A0
|
|
|
|
thumb_func_start sub_80982B8
|
|
sub_80982B8: @ 80982B8
|
|
push {lr}
|
|
ldr r1, =gUnknown_020375BC
|
|
ldrb r0, [r1]
|
|
cmp r0, 0
|
|
bne _080982D4
|
|
movs r0, 0x2
|
|
strb r0, [r1]
|
|
bl textbox_auto_and_task_add
|
|
movs r0, 0x1
|
|
b _080982D6
|
|
.pool
|
|
_080982D4:
|
|
movs r0, 0
|
|
_080982D6:
|
|
pop {r1}
|
|
bx r1
|
|
thumb_func_end sub_80982B8
|
|
|
|
thumb_func_start textbox_fdecode_auto_and_task_add
|
|
textbox_fdecode_auto_and_task_add: @ 80982DC
|
|
push {r4,lr}
|
|
adds r2, r0, 0
|
|
adds r4, r1, 0
|
|
ldr r0, =gStringVar4
|
|
adds r1, r2, 0
|
|
bl StringExpandPlaceholders
|
|
lsls r4, 24
|
|
lsrs r4, 24
|
|
adds r0, r4, 0
|
|
bl AddTextPrinterForMessage
|
|
bl task_add_textbox
|
|
pop {r4}
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end textbox_fdecode_auto_and_task_add
|
|
|
|
thumb_func_start textbox_auto_and_task_add
|
|
textbox_auto_and_task_add: @ 8098304
|
|
push {lr}
|
|
movs r0, 0x1
|
|
bl AddTextPrinterForMessage
|
|
bl task_add_textbox
|
|
pop {r0}
|
|
bx r0
|
|
thumb_func_end textbox_auto_and_task_add
|
|
|
|
thumb_func_start HideFieldMessageBox
|
|
HideFieldMessageBox: @ 8098314
|
|
push {lr}
|
|
bl task_del_textbox
|
|
movs r0, 0
|
|
movs r1, 0x1
|
|
bl sub_8197434
|
|
ldr r1, =gUnknown_020375BC
|
|
movs r0, 0
|
|
strb r0, [r1]
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end HideFieldMessageBox
|
|
|
|
thumb_func_start textbox_any_visible
|
|
textbox_any_visible: @ 8098330
|
|
ldr r0, =gUnknown_020375BC
|
|
ldrb r0, [r0]
|
|
bx lr
|
|
.pool
|
|
thumb_func_end textbox_any_visible
|
|
|
|
thumb_func_start IsFieldMessageBoxHidden
|
|
IsFieldMessageBoxHidden: @ 809833C
|
|
push {lr}
|
|
ldr r0, =gUnknown_020375BC
|
|
ldrb r0, [r0]
|
|
cmp r0, 0
|
|
beq _08098350
|
|
movs r0, 0
|
|
b _08098352
|
|
.pool
|
|
_08098350:
|
|
movs r0, 0x1
|
|
_08098352:
|
|
pop {r1}
|
|
bx r1
|
|
thumb_func_end IsFieldMessageBoxHidden
|
|
|
|
thumb_func_start sub_8098358
|
|
sub_8098358: @ 8098358
|
|
push {lr}
|
|
bl task_del_textbox
|
|
movs r0, 0
|
|
movs r1, 0x1
|
|
bl sub_81973FC
|
|
ldr r1, =gUnknown_020375BC
|
|
movs r0, 0
|
|
strb r0, [r1]
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end sub_8098358
|
|
|
|
thumb_func_start sub_8098374
|
|
sub_8098374: @ 8098374
|
|
push {lr}
|
|
bl task_del_textbox
|
|
ldr r1, =gUnknown_020375BC
|
|
movs r0, 0
|
|
strb r0, [r1]
|
|
pop {r0}
|
|
bx r0
|
|
.pool
|
|
thumb_func_end sub_8098374
|
|
|
|
.align 2, 0 @ Don't pad with nop.
|