mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-11-16 11:37:40 +01:00
Make item optional for givemon and setwildbattle
This commit is contained in:
parent
ce55e58ad8
commit
110fbc559c
@ -986,7 +986,7 @@
|
|||||||
|
|
||||||
@ Gives the player a Pokémon of the specified species and level, holding the specified item. The trailing 0s are unused parameters.
|
@ Gives the player a Pokémon of the specified species and level, holding the specified item. The trailing 0s are unused parameters.
|
||||||
@ VAR_RESULT will be set to MON_GIVEN_TO_PARTY, MON_GIVEN_TO_PC, or MON_CANT_GIVE depending on the outcome.
|
@ VAR_RESULT will be set to MON_GIVEN_TO_PARTY, MON_GIVEN_TO_PC, or MON_CANT_GIVE depending on the outcome.
|
||||||
.macro givemon species:req, level:req, item:req
|
.macro givemon species:req, level:req, item=ITEM_NONE
|
||||||
.byte 0x79
|
.byte 0x79
|
||||||
.2byte \species
|
.2byte \species
|
||||||
.byte \level
|
.byte \level
|
||||||
@ -1432,7 +1432,7 @@
|
|||||||
|
|
||||||
@ Prepares to start a wild battle against a 'species' at 'level' holding 'item'. Running this command will not affect
|
@ Prepares to start a wild battle against a 'species' at 'level' holding 'item'. Running this command will not affect
|
||||||
@ normal wild battles. You start the prepared battle with dowildbattle.
|
@ normal wild battles. You start the prepared battle with dowildbattle.
|
||||||
.macro setwildbattle species:req, level:req, item:req
|
.macro setwildbattle species:req, level:req, item=ITEM_NONE
|
||||||
.byte 0xb6
|
.byte 0xb6
|
||||||
.2byte \species
|
.2byte \species
|
||||||
.byte \level
|
.byte \level
|
||||||
|
@ -61,7 +61,7 @@ AncientTomb_EventScript_Registeel::
|
|||||||
playmoncry SPECIES_REGISTEEL, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_REGISTEEL, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_REGISTEEL, 40, ITEM_NONE
|
setwildbattle SPECIES_REGISTEEL, 40
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special StartRegiBattle
|
special StartRegiBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -29,7 +29,7 @@ AquaHideout_B1F_EventScript_ShowElectrode2::
|
|||||||
AquaHideout_B1F_EventScript_Electrode1::
|
AquaHideout_B1F_EventScript_Electrode1::
|
||||||
lock
|
lock
|
||||||
faceplayer
|
faceplayer
|
||||||
setwildbattle SPECIES_ELECTRODE, 30, ITEM_NONE
|
setwildbattle SPECIES_ELECTRODE, 30
|
||||||
waitse
|
waitse
|
||||||
playmoncry SPECIES_ELECTRODE, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_ELECTRODE, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
@ -53,7 +53,7 @@ AquaHideout_B1F_EventScript_DefeatedElectrode1::
|
|||||||
AquaHideout_B1F_EventScript_Electrode2::
|
AquaHideout_B1F_EventScript_Electrode2::
|
||||||
lock
|
lock
|
||||||
faceplayer
|
faceplayer
|
||||||
setwildbattle SPECIES_ELECTRODE, 30, ITEM_NONE
|
setwildbattle SPECIES_ELECTRODE, 30
|
||||||
waitse
|
waitse
|
||||||
playmoncry SPECIES_ELECTRODE, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_ELECTRODE, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
|
@ -129,7 +129,7 @@ BattleFrontier_OutsideEast_EventScript_WaterSudowoodo::
|
|||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setvar VAR_LAST_TALKED, LOCALID_SUDOWOODO
|
setvar VAR_LAST_TALKED, LOCALID_SUDOWOODO
|
||||||
setwildbattle SPECIES_SUDOWOODO, 40, ITEM_NONE
|
setwildbattle SPECIES_SUDOWOODO, 40
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
dowildbattle
|
dowildbattle
|
||||||
clearflag FLAG_SYS_CTRL_OBJ_DELETE
|
clearflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
|
@ -61,7 +61,7 @@ DesertRuins_EventScript_Regirock::
|
|||||||
playmoncry SPECIES_REGIROCK, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_REGIROCK, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_REGIROCK, 40, ITEM_NONE
|
setwildbattle SPECIES_REGIROCK, 40
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special StartRegiBattle
|
special StartRegiBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -94,7 +94,7 @@ IslandCave_EventScript_Regice::
|
|||||||
playmoncry SPECIES_REGICE, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_REGICE, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_REGICE, 40, ITEM_NONE
|
setwildbattle SPECIES_REGICE, 40
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special StartRegiBattle
|
special StartRegiBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -340,7 +340,7 @@ LittlerootTown_ProfessorBirchsLab_EventScript_TakeYourTime::
|
|||||||
LittlerootTown_ProfessorBirchsLab_EventScript_GiveCyndaquil::
|
LittlerootTown_ProfessorBirchsLab_EventScript_GiveCyndaquil::
|
||||||
bufferspeciesname STR_VAR_1, SPECIES_CYNDAQUIL
|
bufferspeciesname STR_VAR_1, SPECIES_CYNDAQUIL
|
||||||
setvar VAR_TEMP_1, SPECIES_CYNDAQUIL
|
setvar VAR_TEMP_1, SPECIES_CYNDAQUIL
|
||||||
givemon SPECIES_CYNDAQUIL, 5, ITEM_NONE
|
givemon SPECIES_CYNDAQUIL, 5
|
||||||
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendCyndaquilToParty
|
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendCyndaquilToParty
|
||||||
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendCyndaquilToPC
|
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendCyndaquilToPC
|
||||||
hidemonpic
|
hidemonpic
|
||||||
@ -381,7 +381,7 @@ LittlerootTown_ProfessorBirchsLab_EventScript_ReceivedCyndaquil::
|
|||||||
LittlerootTown_ProfessorBirchsLab_EventScript_GiveTotodile::
|
LittlerootTown_ProfessorBirchsLab_EventScript_GiveTotodile::
|
||||||
bufferspeciesname STR_VAR_1, SPECIES_TOTODILE
|
bufferspeciesname STR_VAR_1, SPECIES_TOTODILE
|
||||||
setvar VAR_TEMP_1, SPECIES_TOTODILE
|
setvar VAR_TEMP_1, SPECIES_TOTODILE
|
||||||
givemon SPECIES_TOTODILE, 5, ITEM_NONE
|
givemon SPECIES_TOTODILE, 5
|
||||||
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendTotodileToParty
|
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendTotodileToParty
|
||||||
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendTotodileToPC
|
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendTotodileToPC
|
||||||
hidemonpic
|
hidemonpic
|
||||||
@ -422,7 +422,7 @@ LittlerootTown_ProfessorBirchsLab_EventScript_ReceivedTotodile::
|
|||||||
LittlerootTown_ProfessorBirchsLab_EventScript_GiveChikorita::
|
LittlerootTown_ProfessorBirchsLab_EventScript_GiveChikorita::
|
||||||
bufferspeciesname STR_VAR_1, SPECIES_CHIKORITA
|
bufferspeciesname STR_VAR_1, SPECIES_CHIKORITA
|
||||||
setvar VAR_TEMP_1, SPECIES_CHIKORITA
|
setvar VAR_TEMP_1, SPECIES_CHIKORITA
|
||||||
givemon SPECIES_CHIKORITA, 5, ITEM_NONE
|
givemon SPECIES_CHIKORITA, 5
|
||||||
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendChikoritaToParty
|
goto_if_eq VAR_RESULT, 0, LittlerootTown_ProfessorBirchsLab_EventScript_SendChikoritaToParty
|
||||||
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendChikoritaToPC
|
goto_if_eq VAR_RESULT, 1, LittlerootTown_ProfessorBirchsLab_EventScript_SendChikoritaToPC
|
||||||
hidemonpic
|
hidemonpic
|
||||||
|
@ -35,7 +35,7 @@ MarineCave_End_EventScript_Kyogre::
|
|||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setvar VAR_LAST_TALKED, LOCALID_KYOGRE
|
setvar VAR_LAST_TALKED, LOCALID_KYOGRE
|
||||||
setwildbattle SPECIES_KYOGRE, 70, ITEM_NONE
|
setwildbattle SPECIES_KYOGRE, 70
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special BattleSetup_StartLegendaryBattle
|
special BattleSetup_StartLegendaryBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -86,7 +86,7 @@ MossdeepCity_StevensHouse_EventScript_LeaveBeldum::
|
|||||||
|
|
||||||
MossdeepCity_StevensHouse_EventScript_GiveBeldum::
|
MossdeepCity_StevensHouse_EventScript_GiveBeldum::
|
||||||
setvar VAR_TEMP_1, SPECIES_BELDUM
|
setvar VAR_TEMP_1, SPECIES_BELDUM
|
||||||
givemon SPECIES_BELDUM, 5, ITEM_NONE
|
givemon SPECIES_BELDUM, 5
|
||||||
goto_if_eq VAR_RESULT, 0, MossdeepCity_StevensHouse_EventScript_SendBeldumParty
|
goto_if_eq VAR_RESULT, 0, MossdeepCity_StevensHouse_EventScript_SendBeldumParty
|
||||||
goto_if_eq VAR_RESULT, 1, MossdeepCity_StevensHouse_EventScript_SendBeldumPC
|
goto_if_eq VAR_RESULT, 1, MossdeepCity_StevensHouse_EventScript_SendBeldumPC
|
||||||
goto Common_EventScript_NoMoreRoomForPokemon
|
goto Common_EventScript_NoMoreRoomForPokemon
|
||||||
|
@ -176,7 +176,7 @@ NewMauville_Inside_EventScript_GeneratorOff::
|
|||||||
NewMauville_Inside_EventScript_Voltorb1::
|
NewMauville_Inside_EventScript_Voltorb1::
|
||||||
lock
|
lock
|
||||||
faceplayer
|
faceplayer
|
||||||
setwildbattle SPECIES_VOLTORB, 25, ITEM_NONE
|
setwildbattle SPECIES_VOLTORB, 25
|
||||||
waitse
|
waitse
|
||||||
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
@ -200,7 +200,7 @@ NewMauville_Inside_EventScript_DefeatedVoltorb1::
|
|||||||
NewMauville_Inside_EventScript_Voltorb2::
|
NewMauville_Inside_EventScript_Voltorb2::
|
||||||
lock
|
lock
|
||||||
faceplayer
|
faceplayer
|
||||||
setwildbattle SPECIES_VOLTORB, 25, ITEM_NONE
|
setwildbattle SPECIES_VOLTORB, 25
|
||||||
waitse
|
waitse
|
||||||
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
@ -224,7 +224,7 @@ NewMauville_Inside_EventScript_DefeatedVoltorb2::
|
|||||||
NewMauville_Inside_EventScript_Voltorb3::
|
NewMauville_Inside_EventScript_Voltorb3::
|
||||||
lock
|
lock
|
||||||
faceplayer
|
faceplayer
|
||||||
setwildbattle SPECIES_VOLTORB, 25, ITEM_NONE
|
setwildbattle SPECIES_VOLTORB, 25
|
||||||
waitse
|
waitse
|
||||||
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_VOLTORB, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
|
@ -193,7 +193,7 @@ Route120_EventScript_StevenBattleKecleon::
|
|||||||
playmoncry SPECIES_KECLEON, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_KECLEON, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_KECLEON, 30, ITEM_NONE
|
setwildbattle SPECIES_KECLEON, 30
|
||||||
setvar VAR_0x8009, 0
|
setvar VAR_0x8009, 0
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
dowildbattle
|
dowildbattle
|
||||||
|
@ -145,7 +145,7 @@ RustboroCity_DevonCorp_2F_EventScript_AnorithReady::
|
|||||||
|
|
||||||
RustboroCity_DevonCorp_2F_EventScript_ReceiveLileep::
|
RustboroCity_DevonCorp_2F_EventScript_ReceiveLileep::
|
||||||
setvar VAR_TEMP_1, SPECIES_LILEEP
|
setvar VAR_TEMP_1, SPECIES_LILEEP
|
||||||
givemon SPECIES_LILEEP, 20, ITEM_NONE
|
givemon SPECIES_LILEEP, 20
|
||||||
goto_if_eq VAR_RESULT, 0, RustboroCity_DevonCorp_2F_EventScript_ReceiveLileepParty
|
goto_if_eq VAR_RESULT, 0, RustboroCity_DevonCorp_2F_EventScript_ReceiveLileepParty
|
||||||
goto_if_eq VAR_RESULT, 1, RustboroCity_DevonCorp_2F_EventScript_ReceiveLileepPC
|
goto_if_eq VAR_RESULT, 1, RustboroCity_DevonCorp_2F_EventScript_ReceiveLileepPC
|
||||||
goto Common_EventScript_NoMoreRoomForPokemon
|
goto Common_EventScript_NoMoreRoomForPokemon
|
||||||
@ -190,7 +190,7 @@ RustboroCity_DevonCorp_2F_EventScript_FinishReceivingLileep::
|
|||||||
|
|
||||||
RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorith::
|
RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorith::
|
||||||
setvar VAR_TEMP_1, SPECIES_ANORITH
|
setvar VAR_TEMP_1, SPECIES_ANORITH
|
||||||
givemon SPECIES_ANORITH, 20, ITEM_NONE
|
givemon SPECIES_ANORITH, 20
|
||||||
goto_if_eq VAR_RESULT, 0, RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorithParty
|
goto_if_eq VAR_RESULT, 0, RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorithParty
|
||||||
goto_if_eq VAR_RESULT, 1, RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorithPC
|
goto_if_eq VAR_RESULT, 1, RustboroCity_DevonCorp_2F_EventScript_ReceiveAnorithPC
|
||||||
goto Common_EventScript_NoMoreRoomForPokemon
|
goto Common_EventScript_NoMoreRoomForPokemon
|
||||||
|
@ -48,7 +48,7 @@ SkyPillar_Top_EventScript_Rayquaza::
|
|||||||
playmoncry SPECIES_RAYQUAZA, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_RAYQUAZA, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_RAYQUAZA, 70, ITEM_NONE
|
setwildbattle SPECIES_RAYQUAZA, 70
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special BattleSetup_StartLegendaryBattle
|
special BattleSetup_StartLegendaryBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -35,7 +35,7 @@ TerraCave_End_EventScript_Groudon::
|
|||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setvar VAR_LAST_TALKED, LOCALID_GROUDON
|
setvar VAR_LAST_TALKED, LOCALID_GROUDON
|
||||||
setwildbattle SPECIES_GROUDON, 70, ITEM_NONE
|
setwildbattle SPECIES_GROUDON, 70
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
special BattleSetup_StartLegendaryBattle
|
special BattleSetup_StartLegendaryBattle
|
||||||
waitstate
|
waitstate
|
||||||
|
@ -71,7 +71,7 @@ EventScript_BattleKecleon::
|
|||||||
playmoncry SPECIES_KECLEON, CRY_MODE_ENCOUNTER
|
playmoncry SPECIES_KECLEON, CRY_MODE_ENCOUNTER
|
||||||
delay 40
|
delay 40
|
||||||
waitmoncry
|
waitmoncry
|
||||||
setwildbattle SPECIES_KECLEON, 30, ITEM_NONE
|
setwildbattle SPECIES_KECLEON, 30
|
||||||
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
setflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
dowildbattle
|
dowildbattle
|
||||||
clearflag FLAG_SYS_CTRL_OBJ_DELETE
|
clearflag FLAG_SYS_CTRL_OBJ_DELETE
|
||||||
|
Loading…
Reference in New Issue
Block a user