Mockup of Pokemon Space (#22); reorganize delays and sprite updating of regular spaces (#21)

This commit is contained in:
xCrystal 2023-10-23 17:04:59 +02:00
parent 469537e2b8
commit 9fcd72af19
2 changed files with 15 additions and 9 deletions

View File

@ -31,6 +31,10 @@ ItemSpaceScript::
PokemonSpaceScript::
scall ArriveToRegularSpaceScript
iftrue .not_landed
loadpikachudata
startbattle
reloadmapafterbattle
wait 100
scall LandedInRegularSpaceScript
.not_landed
end
@ -72,6 +76,9 @@ GreySpaceScript::
ArriveToRegularSpaceScript:
playsound SFX_PRESENT
callasm ArriveToRegularSpace
iftrue .not_landed
wait 600
.not_landed
end
ArriveToRegularSpace:
@ -90,10 +97,7 @@ ArriveToRegularSpace:
ld hl, wDisplaySecondarySprites
res SECONDARYSPRITES_SPACES_LEFT_F, [hl]
.not_landed
; if End Space, update sprites
ld a, [wPlayerTile]
cp COLL_END_SPACE
ret nz
; update sprites
jp UpdateActiveSprites
LandedInRegularSpaceScript:

View File

@ -17,14 +17,16 @@ NewGame:
ld b, NAME_PLAYER
ld de, wPlayerName
farcall NamingScreen
ld de, .DefaultName
call InitName
if DEF(_DEBUG)
ld a, MEW
ld [wCurPartySpecies], a
ld a, 100
ld [wCurPartyLevel], a
predef TryAddMonToParty
endc
farcall AutoSaveGameOutsideOverworld
jp GameMenu
.DefaultName:
db "DEBUG@@@@@@"
ResetWRAM:
xor a
ldh [hBGMapMode], a