Consistent predef function names

This commit is contained in:
xCrystal
2018-01-02 18:49:25 +01:00
parent b4a49351c1
commit d7970f749a
102 changed files with 549 additions and 548 deletions

View File

@@ -41,7 +41,7 @@ CatchTutorial:: ; 4e554
ld hl, .AutoInput
ld a, BANK(.AutoInput)
call StartAutoInput
callfar StartBattle
callfar Predef_StartBattle
call StopAutoInput
pop af

View File

@@ -565,7 +565,7 @@ DayCare_GiveEgg: ; 169ac
pop hl
push bc
ld b, $0
predef CalcPkmnStats
predef Predef_CalcPkmnStats
pop bc
ld hl, MON_HP
add hl, bc
@@ -639,7 +639,7 @@ DayCare_InitBreeding: ; 16a3b
cp DITTO
ld a, $0
jr z, .LoadWhichBreedmonIsTheMother
farcall GetGender
farcall Predef_GetGender
ld a, $0
jr z, .LoadWhichBreedmonIsTheMother
inc a
@@ -684,7 +684,7 @@ DayCare_InitBreeding: ; 16a3b
ld de, wEggMonMoves
xor a
ld [Buffer1], a
predef FillMoves
predef Predef_FillMoves
farcall InitEggMoves
ld hl, wEggMonID
ld a, [PlayerID]
@@ -726,7 +726,7 @@ DayCare_InitBreeding: ; 16a3b
ld a, TEMPMON
ld [MonType], a
push hl
farcall GetGender
farcall Predef_GetGender
pop hl
ld de, wBreedMon1DVs
ld bc, wBreedMon2DVs
@@ -770,7 +770,7 @@ DayCare_InitBreeding: ; 16a3b
call CopyBytes
ld hl, wEggMonMoves
ld de, wEggMonPP
predef FillPP
predef Predef_FillPP
ld hl, wMonOrItemNameBuffer
ld de, StringBuffer1
ld bc, NAME_LENGTH

View File

@@ -130,7 +130,7 @@ AnimateHallOfFame: ; 864c3
call WaitBGMap
decoord 6, 5
ld c, $6
predef HOF_AnimateFrontpic
predef HOF_Predef_AnimateFrontpic
ld c, 60
call DelayFrames
and a
@@ -244,18 +244,18 @@ AnimateHOFMonEntrance: ; 865b5
ld a, [hli]
ld [TempMonDVs + 1], a
ld hl, TempMonDVs
predef GetUnownLetter
predef Predef_GetUnownLetter
hlcoord 0, 0
ld bc, SCREEN_WIDTH * SCREEN_HEIGHT
ld a, " "
call ByteFill
ld de, vTiles2 tile $31
predef GetMonBackpic
predef Predef_GetMonBackpic
ld a, $31
ld [hGraphicStartTile], a
hlcoord 6, 6
lb bc, 6, 6
predef PlaceGraphic
predef Predef_PlaceGraphic
ld a, $d0
ld [hSCY], a
ld a, $90
@@ -403,7 +403,7 @@ _HallOfFamePC: ; 86650
call SetPalettes
decoord 6, 5
ld c, $6
predef HOF_AnimateFrontpic
predef HOF_Predef_AnimateFrontpic
and a
ret
@@ -478,7 +478,7 @@ DisplayHOFMon: ; 86748
ld [CurPartySpecies], a
ld [wd265], a
ld hl, TempMonDVs
predef GetUnownLetter
predef Predef_GetUnownLetter
xor a
ld [wBoxAlignment], a
hlcoord 6, 5
@@ -499,7 +499,7 @@ DisplayHOFMon: ; 86748
call PlaceString
ld a, TEMPMON
ld [MonType], a
farcall GetGender
farcall Predef_GetGender
ld a, " "
jr c, .got_gender
ld a, "♂"
@@ -546,7 +546,7 @@ HOF_AnimatePlayerPic: ; 86810
ld [hGraphicStartTile], a
hlcoord 6, 6
lb bc, 6, 6
predef PlaceGraphic
predef Predef_PlaceGraphic
ld a, $d0
ld [hSCY], a
ld a, $90
@@ -570,7 +570,7 @@ HOF_AnimatePlayerPic: ; 86810
ld [hGraphicStartTile], a
hlcoord 12, 5
lb bc, 7, 7
predef PlaceGraphic
predef Predef_PlaceGraphic
ld a, $c0
ld [hSCX], a
call WaitBGMap

View File

@@ -30,7 +30,7 @@ ItemFinder: ; 12580
.Script_FoundSomething: ; 0x125ad
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
callasm .ItemfinderSound
writetext .Text_FoundSomething
closetext
@@ -39,7 +39,7 @@ ItemFinder: ; 12580
.Script_FoundNothing: ; 0x125ba
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writetext .Text_FoundNothing
closetext
end

View File

@@ -442,7 +442,7 @@ MagnetTrain_Jumptable_FirstRunThrough: ; 8ceae
ld [wEnvironment], a
ld b, SCGB_MAPPALS
call GetSGBLayout
call Special_UpdateTimePals
call UpdateTimePals
ld a, [rBGP]
ld [wBGP], a
ld a, [rOBP0]

View File

@@ -54,7 +54,7 @@ CheckCanLearnMoveTutorMove: ; 492b9
ld hl, .MenuDataHeader
call LoadMenuDataHeader
predef CanLearnTMHMMove
predef Predef_CanLearnTMHMMove
push bc
ld a, [CurPartyMon]
@@ -78,7 +78,7 @@ CheckCanLearnMoveTutorMove: ; 492b9
callfar KnowsMove
jr c, .didnt_learn
predef LearnMove
predef Predef_LearnMove
ld a, b
and a
jr z, .didnt_learn

View File

@@ -208,7 +208,7 @@ CheckMapForSomethingToCut: ; c7ce
Script_CutFromMenu: ; c7fe
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
Script_Cut: ; 0xc802
callasm GetPartyNick
@@ -318,7 +318,7 @@ UseFlash: ; c8e0
Script_UseFlash: ; 0xc8e6
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writetext UnknownText_0xc8f3
callasm BlindingFlash
closetext
@@ -407,7 +407,7 @@ SurfFunction: ; c909
ret
SurfFromMenuScript: ; c983
special Special_UpdateTimePals
special UpdateTimePals
UsedSurfScript: ; c986
writetext UsedSurfText ; "used SURF!"
@@ -620,7 +620,7 @@ FlyFunction: ; ca3b
.FlyScript: ; 0xcaa3
reloadmappart
callasm HideSprites
special Special_UpdateTimePals
special UpdateTimePals
callasm FlyFromAnim
farscall Script_AbortBugContest
special Special_WarpToSpawnPoint
@@ -680,7 +680,7 @@ CheckMapCanWaterfall: ; cb07
Script_WaterfallFromMenu: ; 0xcb1c
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
Script_UsedWaterfall: ; 0xcb20
callasm GetPartyNick
@@ -856,13 +856,13 @@ dig_incave
.UsedEscapeRopeScript: ; 0xcc2b
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writetext .Text_UsedEscapeRope
jump .UsedDigOrEscapeRopeScript
.UsedDigScript: ; 0xcc35
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writetext .Text_UsedDig
.UsedDigOrEscapeRopeScript: ; 0xcc3c
@@ -950,7 +950,7 @@ TeleportFunction: ; cc61
.TeleportScript: ; 0xccbb
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writetext .Text_ReturnToLastMonCenter
pause 60
reloadmappart
@@ -1021,7 +1021,7 @@ SetStrengthFlag: ; cd12
Script_StrengthFromMenu: ; 0xcd29
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
Script_UsedStrength: ; 0xcd2d
callasm SetStrengthFlag
@@ -1183,7 +1183,7 @@ TryWhirlpoolMenu: ; cdde
Script_WhirlpoolFromMenu: ; 0xce0b
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
Script_UsedWhirlpool: ; 0xce0f
callasm GetPartyNick
@@ -1284,7 +1284,7 @@ UnknownText_0xcea2: ; 0xcea2
HeadbuttFromMenuScript: ; 0xcea7
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
HeadbuttScript: ; 0xceab
callasm GetPartyNick
@@ -1382,7 +1382,7 @@ GetFacingObject: ; cf0d
RockSmashFromMenuScript: ; 0xcf2e
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
RockSmashScript: ; cf32
callasm GetPartyNick
@@ -1611,7 +1611,7 @@ Fishing_CheckFacingUp: ; d06c
Script_FishCastRod: ; 0xd07c
reloadmappart
loadvar hBGMapMode, $0
special Special_UpdateTimePals
special UpdateTimePals
loademote EMOTE_ROD
callasm LoadFishingGFX
loademote EMOTE_SHOCK
@@ -1735,7 +1735,7 @@ BikeFunction: ; d0b3
Script_GetOnBike: ; 0xd13e
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writecode VAR_MOVEMENT, PLAYER_BIKE
writetext GotOnTheBikeText
waitbutton
@@ -1755,7 +1755,7 @@ Script_GetOnBike_Register: ; 0xd14e
Script_GetOffBike: ; 0xd158
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
writecode VAR_MOVEMENT, PLAYER_NORMAL
writetext GotOffTheBikeText
waitbutton

View File

@@ -104,7 +104,7 @@ DoPoisonStep:: ; 505da
ld de, SFX_POISON
call PlaySFX
ld b, $2
predef LoadPoisonBGPals
predef Predef_LoadPoisonBGPals
call DelayFrame
ret
; 50669
@@ -145,7 +145,7 @@ DoPoisonStep:: ; 505da
ld a, [PartyCount]
cp [hl]
jr nz, .party_loop
predef CheckPlayerPartyForFitPkmn
predef Predef_CheckPlayerPartyForFitPkmn
ld a, d
ld [ScriptVar], a
ret

View File

@@ -1,4 +1,4 @@
LoadPoisonBGPals: ; cbcdd
Predef_LoadPoisonBGPals: ; cbcdd
call .LoadPals
ld a, [hCGB]
and a
@@ -20,7 +20,7 @@ LoadPoisonBGPals: ; cbcdd
call DmgToCgbBGPals
ld c, 4
call DelayFrames
farcall _Special_UpdateTimePals
farcall _UpdateTimePals
ret
.cgb
@@ -44,5 +44,5 @@ LoadPoisonBGPals: ; cbcdd
ld [hCGBPalUpdate], a
ld c, 4
call DelayFrames
farcall _Special_UpdateTimePals
farcall _UpdateTimePals
ret

View File

@@ -216,7 +216,7 @@ Function15715: ; 15715
ld hl, KrissPCMenuData
call LoadMenuDataHeader
.asm_15722
call Special_UpdateTimePals
call UpdateTimePals
call DoNthMenu
jr c, .asm_15731
call MenuJumptable
@@ -354,7 +354,7 @@ KrisWithdrawItemMenu: ; 0x157d1
ld [CurItemQuantity], a
ld hl, PCItems
call TossItem
predef PartyMonItemName
predef Predef_PartyMonItemName
ld hl, .WithdrewText
call MenuTextBox
xor a
@@ -518,7 +518,7 @@ KrisDepositItemMenu: ; 0x1588b
ld [CurItemQuantity], a
ld hl, NumItems
call TossItem
predef PartyMonItemName
predef Predef_PartyMonItemName
ld hl, .DepositText
call PrintText
ret

View File

@@ -12,7 +12,7 @@ Pokepic:: ; 244e3
ld [CurSpecies], a
call GetBaseData
ld de, vTiles1
predef GetMonFrontpic
predef Predef_GetMonFrontpic
ld a, [wMenuBorderTopCoord]
inc a
ld b, a
@@ -23,7 +23,7 @@ Pokepic:: ; 244e3
ld a, $80
ld [hGraphicStartTile], a
lb bc, 7, 7
predef PlaceGraphic
predef Predef_PlaceGraphic
call WaitBGMap
ret

View File

@@ -140,13 +140,13 @@ UnownPrinter: ; 16be4
xor a
ld [wBoxAlignment], a
ld de, vTiles2
predef GetMonFrontpic
predef Predef_GetMonFrontpic
call .Load2bppToSRAM
hlcoord 1, 6
xor a
ld [hGraphicStartTile], a
lb bc, 7, 7
predef PlaceGraphic
predef Predef_PlaceGraphic
ld de, vTiles2 tile $31
farcall RotateUnownFrontpic
ret
@@ -228,6 +228,6 @@ PlaceUnownPrinterFrontpic: ; 16dac
ld a, $31
ld [hGraphicStartTile], a
lb bc, 7, 7
predef PlaceGraphic
predef Predef_PlaceGraphic
ret
; 16dc7

View File

@@ -10,7 +10,7 @@ Special_GiveShuckle: ; 7305
ld a, 15
ld [CurPartyLevel], a
predef TryAddMonToParty
predef Predef_TryAddMonToParty
jr nc, .NotGiven
; Caught data.

View File

@@ -7,7 +7,7 @@ _Squirtbottle: ; 50730
.SquirtbottleScript:
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
callasm .CheckCanUseSquirtbottle
iffalse .NothingHappenedScript
farjump WateredWeirdTreeScript

View File

@@ -8,7 +8,7 @@ SweetScentFromMenu: ; 506bc
.SweetScent: ; 0x506c8
reloadmappart
special Special_UpdateTimePals
special UpdateTimePals
callasm GetPartyNick
writetext UnknownText_0x50726
waitbutton