Merge branch '_RHH/upcoming' into _RHH/pr/upcoming/lighting-expansion-v2
3
.github/pull_request_template.md
vendored
@ -1,11 +1,12 @@
|
||||
<!--- Provide a general summary of your changes in the Title above -->
|
||||
|
||||
<!--- Before submitting, please make sure your pull request meets the scope guidelines. If unsure, please open a thread in #pr-discussions.-->
|
||||
<!--- Scope Guidelines: https://github.com/rh-hideout/pokeemerald-expansion/blob/master/docs/scope.md -->
|
||||
<!--- Scope Guidelines: https://github.com/rh-hideout/pokeemerald-expansion/blob/master/docs/team_procedures/scope.md -->
|
||||
<!--- #pr-discussions: https://discord.com/channels/419213663107416084/1102784418369785948 -->
|
||||
|
||||
## Description
|
||||
<!--- Describe your changes in detail -->
|
||||
<!--- If you believe this PR qualifies as a "Big Feature" as defined in docs/team_procedures/schedule.md, please let a Maintainer know! -->
|
||||
|
||||
## Images
|
||||
<!-- Please provide with relevant GIFs or images to make it easier for reviewers to accept your PR quicker.-->
|
||||
|
||||
12
Makefile
@ -72,6 +72,9 @@ HEADLESSELF = $(ROM_NAME:.gba=-test-headless.elf)
|
||||
|
||||
# Pick our active variables
|
||||
ROM := $(ROM_NAME)
|
||||
ifeq ($(TESTELF),$(MAKECMDGOALS))
|
||||
TEST := 1
|
||||
endif
|
||||
ifeq ($(TEST), 0)
|
||||
OBJ_DIR := $(OBJ_DIR_NAME)
|
||||
else
|
||||
@ -80,9 +83,6 @@ endif
|
||||
ifeq ($(DEBUG),1)
|
||||
OBJ_DIR := $(OBJ_DIR_NAME_DEBUG)
|
||||
endif
|
||||
ifeq ($(TESTELF),$(MAKECMDGOALS))
|
||||
TEST := 1
|
||||
endif
|
||||
ELF := $(ROM:.gba=.elf)
|
||||
MAP := $(ROM:.gba=.map)
|
||||
SYM := $(ROM:.gba=.sym)
|
||||
@ -177,7 +177,7 @@ MAKEFLAGS += --no-print-directory
|
||||
# Delete files that weren't built properly
|
||||
.DELETE_ON_ERROR:
|
||||
|
||||
RULES_NO_SCAN += libagbsyscall clean clean-assets tidy tidymodern tidycheck generated clean-generated $(TESTELF)
|
||||
RULES_NO_SCAN += libagbsyscall clean clean-assets tidy tidymodern tidycheck generated clean-generated
|
||||
.PHONY: all rom agbcc modern compare check debug
|
||||
.PHONY: $(RULES_NO_SCAN)
|
||||
|
||||
@ -427,8 +427,8 @@ $(OBJ_DIR)/sym_common.ld: sym_common.txt $(C_OBJS) $(wildcard common_syms/*.txt)
|
||||
$(OBJ_DIR)/sym_ewram.ld: sym_ewram.txt
|
||||
$(RAMSCRGEN) ewram_data $< ENGLISH > $@
|
||||
|
||||
# NOTE: Depending on event_scripts.o is hacky, but we want to depend on everything event_scripts.s depends on without having to alter scaninc
|
||||
$(DATA_SRC_SUBDIR)/pokemon/teachable_learnsets.h: $(DATA_ASM_BUILDDIR)/event_scripts.o
|
||||
TEACHABLE_DEPS := $(shell find data/ -type f -name '*.inc') $(INCLUDE_DIRS)/constants/tms_hms.h $(C_SUBDIR)/pokemon.c
|
||||
$(DATA_SRC_SUBDIR)/pokemon/teachable_learnsets.h: $(TEACHABLE_DEPS)
|
||||
python3 $(TOOLS_DIR)/learnset_helpers/teachable.py
|
||||
|
||||
# Linker script
|
||||
|
||||
@ -478,9 +478,10 @@
|
||||
.byte \battler
|
||||
.endm
|
||||
|
||||
.macro switchinanim battler:req, dontClearSubstitute:req
|
||||
.macro switchinanim battler:req, dontClearTransform:req, dontClearSubstitute:req
|
||||
.byte 0x4e
|
||||
.byte \battler
|
||||
.byte \dontClearTransform
|
||||
.byte \dontClearSubstitute
|
||||
.endm
|
||||
|
||||
@ -2337,11 +2338,11 @@
|
||||
.endm
|
||||
|
||||
.macro swapsidestatuses
|
||||
various BS_ATTACKER, VARIOUS_SWAP_SIDE_STATUSES
|
||||
callnative BS_CourtChangeSwapSideStatuses
|
||||
.endm
|
||||
|
||||
.macro swapstats stat:req
|
||||
various BS_ATTACKER, VARIOUS_SWAP_STATS
|
||||
callnative BS_SwapStats
|
||||
.byte \stat
|
||||
.endm
|
||||
|
||||
|
||||
@ -251,15 +251,26 @@
|
||||
.endm
|
||||
|
||||
@ Calls the native C function stored at func.
|
||||
.macro callnative func:req
|
||||
@ 'callnative's should set 'requests_effects=1' if the native
|
||||
@ contains a call to 'Script_RequestEffects', which allows them
|
||||
@ to be analyzed by 'RunScriptImmediatelyUntilEffect'.
|
||||
.macro callnative func:req, requests_effects=0
|
||||
.byte 0x23
|
||||
.if \requests_effects == 0
|
||||
.4byte \func
|
||||
.else
|
||||
.4byte \func + ROM_SIZE
|
||||
.endif
|
||||
.endm
|
||||
|
||||
@ Replaces the script with the function stored at func. Execution returns to the bytecode script when func returns TRUE.
|
||||
.macro gotonative func:req
|
||||
.macro gotonative func:req, requests_effects=0
|
||||
.byte 0x24
|
||||
.if \requests_effects == 0
|
||||
.4byte \func
|
||||
.else
|
||||
.4byte \func + ROM_SIZE
|
||||
.endif
|
||||
.endm
|
||||
|
||||
@ Calls a function listed in the table in data/specials.inc.
|
||||
@ -996,10 +1007,10 @@
|
||||
|
||||
@ Gives the player a Pokémon of the specified species and level, and allows to customize extra parameters.
|
||||
@ 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, ball, nature, abilityNum, gender, hpEv, atkEv, defEv, speedEv, spAtkEv, spDefEv, hpIv, atkIv, defIv, speedIv, spAtkIv, spDefIv, move1, move2, move3, move4, isShiny, ggMaxFactor, teraType
|
||||
callnative ScrCmd_createmon
|
||||
.macro givemon species:req, level:req, item, ball, nature, abilityNum, gender, hpEv, atkEv, defEv, speedEv, spAtkEv, spDefEv, hpIv, atkIv, defIv, speedIv, spAtkIv, spDefIv, move1, move2, move3, move4, isShiny, gmaxFactor, teraType, dmaxLevel
|
||||
callnative ScrCmd_createmon, requests_effects=1
|
||||
.byte 0
|
||||
.byte 6 @ PARTY_SIZE - assign to first empty slot
|
||||
.byte PARTY_SIZE @ assign to first empty slot
|
||||
.set givemon_flags, 0
|
||||
.2byte \species
|
||||
.2byte \level
|
||||
@ -1025,8 +1036,9 @@
|
||||
.ifnb \move3; .set givemon_flags, givemon_flags | (1 << 19); .endif
|
||||
.ifnb \move4; .set givemon_flags, givemon_flags | (1 << 20); .endif
|
||||
.ifnb \isShiny; .set givemon_flags, givemon_flags | (1 << 21); .endif
|
||||
.ifnb \ggMaxFactor; .set givemon_flags, givemon_flags | (1 << 22); .endif
|
||||
.ifnb \gmaxFactor; .set givemon_flags, givemon_flags | (1 << 22); .endif
|
||||
.ifnb \teraType; .set givemon_flags, givemon_flags | (1 << 23); .endif
|
||||
.ifnb \dmaxLevel; .set givemon_flags, givemon_flags | (1 << 24); .endif
|
||||
.4byte givemon_flags
|
||||
.ifnb \item; .2byte \item; .endif
|
||||
.ifnb \ball; .2byte \ball; .endif
|
||||
@ -1050,14 +1062,15 @@
|
||||
.ifnb \move3; .2byte \move3; .endif
|
||||
.ifnb \move4; .2byte \move4; .endif
|
||||
.ifnb \isShiny; .2byte \isShiny; .endif
|
||||
.ifnb \ggMaxFactor; .2byte \ggMaxFactor; .endif
|
||||
.ifnb \gmaxFactor; .2byte \gmaxFactor; .endif
|
||||
.ifnb \teraType; .2byte \teraType; .endif
|
||||
.ifnb \dmaxLevel; .2byte \dmaxLevel; .endif
|
||||
.endm
|
||||
|
||||
@ creates a mon for a given party and slot
|
||||
@ otherwise
|
||||
.macro createmon side:req, slot:req, species:req, level:req, item, ball, nature, abilityNum, gender, hpEv, atkEv, defEv, speedEv, spAtkEv, spDefEv, hpIv, atkIv, defIv, speedIv, spAtkIv, spDefIv, move1, move2, move3, move4, isShiny, ggMaxFactor, teraType
|
||||
callnative ScrCmd_createmon
|
||||
.macro createmon side:req, slot:req, species:req, level:req, item, ball, nature, abilityNum, gender, hpEv, atkEv, defEv, speedEv, spAtkEv, spDefEv, hpIv, atkIv, defIv, speedIv, spAtkIv, spDefIv, move1, move2, move3, move4, isShiny, gmaxFactor, teraType, dmaxLevel
|
||||
callnative ScrCmd_createmon, requests_effects=1
|
||||
.byte \side @ 0 - player, 1 - opponent
|
||||
.byte \slot @ 0-5
|
||||
.set givemon_flags, 0
|
||||
@ -1085,8 +1098,9 @@
|
||||
.ifnb \move3; .set givemon_flags, givemon_flags | (1 << 19); .endif
|
||||
.ifnb \move4; .set givemon_flags, givemon_flags | (1 << 20); .endif
|
||||
.ifnb \isShiny; .set givemon_flags, givemon_flags | (1 << 21); .endif
|
||||
.ifnb \ggMaxFactor; .set givemon_flags, givemon_flags | (1 << 22); .endif
|
||||
.ifnb \gmaxFactor; .set givemon_flags, givemon_flags | (1 << 22); .endif
|
||||
.ifnb \teraType; .set givemon_flags, givemon_flags | (1 << 23); .endif
|
||||
.ifnb \dmaxLevel; .set givemon_flags, givemon_flags | (1 << 24); .endif
|
||||
.4byte givemon_flags
|
||||
.ifnb \item; .2byte \item; .endif
|
||||
.ifnb \ball; .2byte \ball; .endif
|
||||
@ -1110,8 +1124,9 @@
|
||||
.ifnb \move3; .2byte \move3; .endif
|
||||
.ifnb \move4; .2byte \move4; .endif
|
||||
.ifnb \isShiny; .2byte \isShiny; .endif
|
||||
.ifnb \ggMaxFactor; .2byte \ggMaxFactor; .endif
|
||||
.ifnb \gmaxFactor; .2byte \gmaxFactor; .endif
|
||||
.ifnb \teraType; .2byte \teraType; .endif
|
||||
.ifnb \dmaxLevel; .2byte \dmaxLevel; .endif
|
||||
.endm
|
||||
|
||||
@ Gives the player an Egg of the specified species.
|
||||
@ -2105,7 +2120,7 @@
|
||||
.endm
|
||||
|
||||
.macro setdynamicaifunc func:req
|
||||
callnative ScriptSetDynamicAiFunc
|
||||
callnative ScriptSetDynamicAiFunc, requests_effects=1
|
||||
.4byte \func
|
||||
.endm
|
||||
|
||||
@ -2114,7 +2129,7 @@
|
||||
@ The rest of the arguments are the stat change values to each stat.
|
||||
@ For example, giving the first opponent +1 to atk and -2 to speed would be: settotemboost B_POSITION_OPPONENT_LEFT, 1, 0, -2
|
||||
.macro settotemboost battler:req, atk=0,def=0,speed=0,spatk=0,spdef=0,acc=0,evas=0
|
||||
callnative ScriptSetTotemBoost
|
||||
callnative ScriptSetTotemBoost, requests_effects=1
|
||||
.2byte \battler
|
||||
.2byte \atk
|
||||
.2byte \def
|
||||
@ -2185,21 +2200,21 @@
|
||||
.macro ai_vs_ai_battle trainer1:req, trainer2:req
|
||||
setflag B_FLAG_AI_VS_AI_BATTLE
|
||||
setvar VAR_0x8004, \trainer1
|
||||
callnative CreateTrainerPartyForPlayer
|
||||
callnative CreateTrainerPartyForPlayer, requests_effects=1
|
||||
trainerbattle_no_intro \trainer2, NULL
|
||||
.endm
|
||||
|
||||
@ Sets VAR_RESULT to TRUE if stat can be hyper trained, or to
|
||||
@ FALSE otherwise.
|
||||
.macro canhypertrain stat:req, slot:req
|
||||
callnative CanHyperTrain
|
||||
callnative CanHyperTrain, requests_effects=1
|
||||
.byte \stat
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ Hyper Trains a stat.
|
||||
.macro hypertrain stat:req, slot:req
|
||||
callnative HyperTrain
|
||||
callnative HyperTrain, requests_effects=1
|
||||
.byte \stat
|
||||
.2byte \slot
|
||||
.endm
|
||||
@ -2207,7 +2222,7 @@
|
||||
@ Sets VAR_RESULT to TRUE if the Pokemon has the Gigantamax Factor,
|
||||
@ or to FALSE otherwise.
|
||||
.macro hasgigantamaxfactor slot:req
|
||||
callnative HasGigantamaxFactor
|
||||
callnative HasGigantamaxFactor, requests_effects=1
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ -2215,7 +2230,7 @@
|
||||
@ Fails for Melmetal (vanilla behavior).
|
||||
@ Sets VAR_RESULT to TRUE if it succeeds, and FALSE otherwise.
|
||||
.macro togglegigantamaxfactor slot:req
|
||||
callnative ToggleGigantamaxFactor
|
||||
callnative ToggleGigantamaxFactor, requests_effects=1
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ -2253,27 +2268,27 @@
|
||||
@ Inflicts \status1 to the Pokémon in \slot.
|
||||
@ If \slot is greater or equal than PARTY_SIZE, the status is inflicted on each of the Player's Pokémon.
|
||||
.macro setstatus1 status1:req, slot:req
|
||||
callnative Script_SetStatus1
|
||||
callnative Script_SetStatus1, requests_effects=1
|
||||
.2byte \status1
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ Sets VAR_RESULT to the Pokémon in \slot's Tera Type
|
||||
.macro checkteratype slot:req
|
||||
callnative CheckTeraType
|
||||
callnative CheckTeraType, requests_effects=1
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ Sets the Pokémon in \slot's Tera Type
|
||||
.macro setteratype type:req, slot:req
|
||||
callnative SetTeraType
|
||||
callnative SetTeraType, requests_effects=1
|
||||
.byte \type
|
||||
.2byte \slot
|
||||
.endm
|
||||
|
||||
@ Saves species and forms of Daycare Pokémon to specific vars. Saves the amount of Daycare mon to VAR_RESULT.
|
||||
.macro getdaycaregfx varSpecies1:req varSpecies2:req varForm1:req varForm2:req
|
||||
callnative GetDaycareGraphics
|
||||
callnative GetDaycareGraphics, requests_effects=1
|
||||
.2byte \varSpecies1
|
||||
.2byte \varSpecies2
|
||||
.2byte \varForm1
|
||||
@ -2282,12 +2297,12 @@
|
||||
|
||||
@ Plays the cry of the first alive party member.
|
||||
.macro playfirstmoncry
|
||||
callnative PlayFirstMonCry
|
||||
callnative PlayFirstMonCry, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ Buffers the nickname of the first alive party member.
|
||||
.macro bufferlivemonnickname out:req
|
||||
callnative BufferFirstLiveMonNickname
|
||||
callnative BufferFirstLiveMonNickname, requests_effects=1
|
||||
.byte \out
|
||||
.endm
|
||||
|
||||
@ -2298,13 +2313,13 @@
|
||||
|
||||
@ Checks if Field move is being used by the current follower.
|
||||
.macro isfollowerfieldmoveuser var:req
|
||||
callnative IsFollowerFieldMoveUser
|
||||
callnative IsFollowerFieldMoveUser, requests_effects=1
|
||||
.2byte \var
|
||||
.endm
|
||||
|
||||
@ Saves the direction from where source object event would need to turn to to face the target into the specified var.
|
||||
.macro getdirectiontoface var:req, sourceId:req, targetId:req
|
||||
callnative GetDirectionToFaceScript
|
||||
callnative GetDirectionToFaceScript, requests_effects=1
|
||||
.2byte \var
|
||||
.byte \sourceId
|
||||
.byte \targetId
|
||||
@ -2313,50 +2328,50 @@
|
||||
@ set the wild double battle flag
|
||||
@ can be used in conjunection with createmon to set up a wild battle with 2 player mons vs. 1 enemy mon
|
||||
.macro setwilddoubleflag
|
||||
callnative ScriptSetDoubleBattleFlag
|
||||
callnative ScriptSetDoubleBattleFlag, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ When OW_USE_FAKE_RTC and OW_FLAG_PAUSE_TIME is assigned, this macro will stop the flow of time.
|
||||
.macro pausefakertc
|
||||
callnative Script_PauseFakeRtc
|
||||
callnative Script_PauseFakeRtc, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ When OW_USE_FAKE_RTC and OW_FLAG_PAUSE_TIME is assigned, this macro will resume the flow of time.
|
||||
.macro resumefakertc
|
||||
callnative Script_ResumeFakeRtc
|
||||
callnative Script_ResumeFakeRtc, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ When OW_USE_FAKE_RTC and OW_FLAG_PAUSE_TIME is assigned, this macro will resume the flow of time if paused, and stop the flow of time otherwise.
|
||||
.macro togglefakertc
|
||||
callnative Script_ToggleFakeRtc
|
||||
callnative Script_ToggleFakeRtc, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ ============================ @
|
||||
@ ITEM DESCRIPTION HEADER MACROS
|
||||
@ Used with OW_SHOW_ITEM_DESCRIPTIONS config
|
||||
.macro showitemdescription
|
||||
callnative ScriptShowItemDescription
|
||||
callnative ScriptShowItemDescription, requests_effects=1
|
||||
.byte 0
|
||||
.endm
|
||||
|
||||
.macro showberrydescription
|
||||
callnative ScriptShowItemDescription
|
||||
callnative ScriptShowItemDescription, requests_effects=1
|
||||
.byte 1
|
||||
.endm
|
||||
|
||||
.macro hideitemdescription
|
||||
callnative ScriptHideItemDescription
|
||||
callnative ScriptHideItemDescription, requests_effects=1
|
||||
.endm
|
||||
|
||||
@ Remove all of specified item from the player's bag and return the number of removed items to VAR_RESULT
|
||||
.macro removeallitem itemId:req
|
||||
callnative ScrCmd_removeallitem
|
||||
callnative ScrCmd_removeallitem, requests_effects=1
|
||||
.2byte \itemId
|
||||
.endm
|
||||
|
||||
@ Stores the position of the given object in destX and destY. Mode CURRENT_POSITION will take the object's current position. Mode TEMPLATE_POSITION will take the object's template position.
|
||||
.macro getobjectxy localId:req, posType:req, destX:req, destY:req
|
||||
callnative ScrCmd_getobjectxy
|
||||
callnative ScrCmd_getobjectxy, request_effects=1
|
||||
.2byte \localId
|
||||
.2byte \posType
|
||||
.2byte \destX
|
||||
@ -2364,7 +2379,7 @@
|
||||
.endm
|
||||
|
||||
.macro getobjecttemplatexy localId:req, posType = TEMPLATE_POSITION, destX:req, destY:req
|
||||
callnative ScrCmd_getobjectxy
|
||||
callnative ScrCmd_getobjectxy, request_effects=1
|
||||
.2byte \localId
|
||||
.2byte \posType
|
||||
.2byte \destX
|
||||
@ -2372,7 +2387,7 @@
|
||||
.endm
|
||||
|
||||
.macro getobjectcurrentxy localId:req, posType = CURRENT_POSITION, destX:req, destY:req
|
||||
callnative ScrCmd_getobjectxy
|
||||
callnative ScrCmd_getobjectxy, request_effects=1
|
||||
.2byte \localId
|
||||
.2byte \posType
|
||||
.2byte \destX
|
||||
@ -2381,7 +2396,7 @@
|
||||
|
||||
@ Return TRUE to dest if there is an object at the position x and y.
|
||||
.macro checkobjectat x:req, y:req, dest = VAR_RESULT
|
||||
callnative ScrCmd_checkobjectat
|
||||
callnative ScrCmd_checkobjectat, request_effects=1
|
||||
.2byte \x
|
||||
.2byte \y
|
||||
.2byte \dest
|
||||
@ -2389,28 +2404,28 @@
|
||||
|
||||
@ Returns the state of the Pokedex Seen Flag to VAR_RESULT for the Pokemon with speciesId
|
||||
.macro getseenmon species:req
|
||||
callnative Scrcmd_getsetpokedexflag
|
||||
callnative Scrcmd_getsetpokedexflag, request_effects=1
|
||||
.2byte \species
|
||||
.2byte FLAG_GET_SEEN
|
||||
.endm
|
||||
|
||||
@ Returns the state of the Pokedex Caught Flag to VAR_RESULT for the Pokemon with speciesId
|
||||
.macro getcaughtmon species:req
|
||||
callnative Scrcmd_getsetpokedexflag
|
||||
callnative Scrcmd_getsetpokedexflag, request_effects=1
|
||||
.2byte \species
|
||||
.2byte FLAG_GET_CAUGHT
|
||||
.endm
|
||||
|
||||
@ Sets the Pokedex Seen Flag for the Pokemon with speciesId
|
||||
.macro setseenmon species:req
|
||||
callnative Scrcmd_getsetpokedexflag
|
||||
callnative Scrcmd_getsetpokedexflag, request_effects=1
|
||||
.2byte \species
|
||||
.2byte FLAG_SET_SEEN
|
||||
.endm
|
||||
|
||||
@ Sets the Pokedex Caught Flag for the Pokemon with speciesId
|
||||
.macro setcaughtmon species:req
|
||||
callnative Scrcmd_getsetpokedexflag
|
||||
callnative Scrcmd_getsetpokedexflag, request_effects=1
|
||||
.2byte \species
|
||||
.2byte FLAG_SET_CAUGHT
|
||||
.endm
|
||||
@ -2420,10 +2435,10 @@
|
||||
.if \mode == OPEN_PARTY_SCREEN
|
||||
special ChoosePartyMon
|
||||
waitstate
|
||||
callnative Scrcmd_checkspecies_choose
|
||||
callnative Scrcmd_checkspecies_choose, request_effects=1
|
||||
.2byte \speciesId
|
||||
.else
|
||||
callnative Scrcmd_checkspecies
|
||||
callnative Scrcmd_checkspecies, request_effects=1
|
||||
.2byte \speciesId
|
||||
.endif
|
||||
.endm
|
||||
@ -2434,8 +2449,85 @@
|
||||
|
||||
@ Gets the facing direction of a given event object and stores it in the variable dest.
|
||||
.macro getobjectfacingdirection localId:req, dest:req
|
||||
callnative Scrcmd_getobjectfacingdirection
|
||||
callnative Scrcmd_getobjectfacingdirection, request_effects=1
|
||||
.2byte \localId
|
||||
.2byte \dest
|
||||
.endm
|
||||
|
||||
.macro increasedifficulty
|
||||
callnative Script_IncreaseDifficulty, requests_effects=1
|
||||
.endm
|
||||
|
||||
.macro decreasedifficulty
|
||||
callnative Script_DecreaseDifficulty, requests_effects=1
|
||||
.endm
|
||||
|
||||
.macro getdifficulty var:req
|
||||
callnative Script_GetDifficulty, requests_effects=1
|
||||
.endm
|
||||
|
||||
.macro setdifficulty difficulty:req
|
||||
callnative Script_SetDifficulty, requests_effects=1
|
||||
.byte \difficulty
|
||||
.endm
|
||||
|
||||
@ Makes the trainer unable to see the player if executed.
|
||||
@ This is a no-op if the player interacts with the trainer.
|
||||
.macro cant_see_if, condition:req
|
||||
callnative Script_EndTrainerCanSeeIf, requests_effects=1
|
||||
.byte \condition
|
||||
.endm
|
||||
|
||||
.macro cant_see
|
||||
cant_see_if_unset 0 @ flag 0 is always FALSE.
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_unset, flag:req
|
||||
checkflag \flag
|
||||
cant_see_if FALSE
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_set, flag:req
|
||||
checkflag \flag
|
||||
cant_see_if TRUE
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_trainerflag_unset, trainer:req
|
||||
checktrainerflag \trainer
|
||||
cant_see_if FALSE
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_trainerflag_set, trainer:req
|
||||
checktrainerflag \trainer
|
||||
cant_see_if TRUE
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_lt, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 0
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_eq, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 1
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_gt, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 2
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_le, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 3
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_ge, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 4
|
||||
.endm
|
||||
|
||||
.macro cant_see_if_ne, a:req, b:req
|
||||
compare \a, \b
|
||||
cant_see_if 5
|
||||
.endm
|
||||
|
||||
@ -29,6 +29,9 @@
|
||||
|
||||
.set OAM, 0x7000000
|
||||
|
||||
.set ROM, 0x8000000
|
||||
.set ROM_SIZE, 0x2000000
|
||||
|
||||
.set SOUND_INFO_PTR, 0x3007FF0
|
||||
.set INTR_CHECK, 0x3007FF8
|
||||
.set INTR_VECTOR, 0x3007FFC
|
||||
|
||||
@ -272,7 +272,7 @@ BattleScript_EffectChillyReception::
|
||||
jumpifhalfword CMP_COMMON_BITS, gBattleWeather, B_WEATHER_RAIN_PRIMAL, BattleScript_EffectChillyReceptionBlockedByPrimalRain
|
||||
jumpifhalfword CMP_COMMON_BITS, gBattleWeather, B_WEATHER_STRONG_WINDS, BattleScript_EffectChillyReceptionBlockedByStrongWinds
|
||||
call BattleScript_EffectChillyReceptionPlayAnimation
|
||||
setfieldweather ENUM_WEATHER_SNOW
|
||||
setfieldweather BATTLE_WEATHER_SNOW
|
||||
call BattleScript_MoveWeatherChangeRet
|
||||
goto BattleScript_MoveSwitch
|
||||
BattleScript_EffectChillyReceptionPlayAnimation:
|
||||
@ -330,7 +330,7 @@ BattleScript_MoveSwitchOpenPartyScreen::
|
||||
printstring STRINGID_EMPTYSTRING3
|
||||
waitmessage 1
|
||||
printstring STRINGID_SWITCHINMON
|
||||
switchinanim BS_ATTACKER, TRUE
|
||||
switchinanim BS_ATTACKER, FALSE, TRUE
|
||||
waitstate
|
||||
switchineffects BS_ATTACKER
|
||||
BattleScript_MoveSwitchEnd:
|
||||
@ -477,7 +477,7 @@ BattleScript_EffectRevivalBlessingSendOut:
|
||||
getswitchedmondata BS_SCRIPTING
|
||||
switchindataupdate BS_SCRIPTING
|
||||
hpthresholds BS_SCRIPTING
|
||||
switchinanim BS_SCRIPTING, FALSE
|
||||
switchinanim BS_SCRIPTING, FALSE, FALSE
|
||||
waitstate
|
||||
switchineffects BS_SCRIPTING
|
||||
goto BattleScript_MoveEnd
|
||||
@ -2398,7 +2398,7 @@ BattleScript_EffectHealingWish::
|
||||
trytoclearprimalweather
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
switchinanim BS_ATTACKER, TRUE
|
||||
switchinanim BS_ATTACKER, FALSE, TRUE
|
||||
waitstate
|
||||
switchineffects BS_ATTACKER
|
||||
.endif
|
||||
@ -4273,7 +4273,7 @@ BattleScript_EffectSandstorm::
|
||||
attackstring
|
||||
ppreduce
|
||||
call BattleScript_CheckPrimalWeather
|
||||
setfieldweather ENUM_WEATHER_SANDSTORM
|
||||
setfieldweather BATTLE_WEATHER_SANDSTORM
|
||||
goto BattleScript_MoveWeatherChange
|
||||
|
||||
BattleScript_EffectRollout::
|
||||
@ -4408,7 +4408,7 @@ BattleScript_EffectBatonPass::
|
||||
trytoclearprimalweather
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
switchinanim BS_ATTACKER, TRUE
|
||||
switchinanim BS_ATTACKER, FALSE, TRUE
|
||||
waitstate
|
||||
switchineffects BS_ATTACKER
|
||||
goto BattleScript_MoveEnd
|
||||
@ -4439,7 +4439,7 @@ BattleScript_EffectRainDance::
|
||||
attackstring
|
||||
ppreduce
|
||||
call BattleScript_CheckPrimalWeather
|
||||
setfieldweather ENUM_WEATHER_RAIN
|
||||
setfieldweather BATTLE_WEATHER_RAIN
|
||||
BattleScript_MoveWeatherChange::
|
||||
attackanimation
|
||||
waitanimation
|
||||
@ -4457,7 +4457,7 @@ BattleScript_EffectSunnyDay::
|
||||
attackstring
|
||||
ppreduce
|
||||
call BattleScript_CheckPrimalWeather
|
||||
setfieldweather ENUM_WEATHER_SUN
|
||||
setfieldweather BATTLE_WEATHER_SUN
|
||||
goto BattleScript_MoveWeatherChange
|
||||
|
||||
BattleScript_ExtremelyHarshSunlightWasNotLessened:
|
||||
@ -4816,7 +4816,7 @@ BattleScript_EffectHail::
|
||||
attackstring
|
||||
ppreduce
|
||||
call BattleScript_CheckPrimalWeather
|
||||
setfieldweather ENUM_WEATHER_HAIL
|
||||
setfieldweather BATTLE_WEATHER_HAIL
|
||||
goto BattleScript_MoveWeatherChange
|
||||
|
||||
BattleScript_EffectTorment::
|
||||
@ -5512,7 +5512,7 @@ BattleScript_FaintedMonTryChoose:
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
hidepartystatussummary BS_ATTACKER
|
||||
switchinanim BS_ATTACKER, 0
|
||||
switchinanim BS_ATTACKER, FALSE, FALSE
|
||||
waitstate
|
||||
setbyte sSHIFT_SWITCHED, 1
|
||||
BattleScript_FaintedMonSendOutNew:
|
||||
@ -5524,7 +5524,7 @@ BattleScript_FaintedMonSendOutNew:
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
hidepartystatussummary BS_FAINTED
|
||||
switchinanim BS_FAINTED, FALSE
|
||||
switchinanim BS_FAINTED, FALSE, FALSE
|
||||
waitstate
|
||||
resetplayerfainted
|
||||
trytrainerslidelastonmsg BS_FAINTED
|
||||
@ -5558,7 +5558,7 @@ BattleScript_HandleFaintedMonLoop::
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
hidepartystatussummary BS_FAINTED
|
||||
switchinanim BS_FAINTED, FALSE
|
||||
switchinanim BS_FAINTED, FALSE, FALSE
|
||||
waitstate
|
||||
switchineffects BS_FAINTED_MULTIPLE_1
|
||||
jumpifbytenotequal gBattlerFainted, gBattlersCount, BattleScript_HandleFaintedMonLoop
|
||||
@ -5774,7 +5774,7 @@ BattleScript_DoSwitchOut::
|
||||
flushtextbox
|
||||
printstring STRINGID_SWITCHINMON
|
||||
hidepartystatussummary BS_ATTACKER
|
||||
switchinanim BS_ATTACKER, FALSE
|
||||
switchinanim BS_ATTACKER, FALSE, FALSE
|
||||
waitstate
|
||||
switchineffects BS_ATTACKER
|
||||
moveendcase MOVEEND_STATUS_IMMUNITY_ABILITIES
|
||||
@ -5822,20 +5822,18 @@ BattleScript_LearnedNewMove::
|
||||
BattleScript_LearnMoveReturn::
|
||||
return
|
||||
|
||||
BattleScript_RainContinuesOrEnds::
|
||||
printfromtable gRainContinuesStringIds
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
jumpifbyte CMP_EQUAL, cMULTISTRING_CHOOSER, B_MSG_RAIN_STOPPED, BattleScript_RainContinuesOrEndsEnd
|
||||
playanimation BS_ATTACKER, B_ANIM_RAIN_CONTINUES
|
||||
BattleScript_RainContinuesOrEndsEnd::
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_DamagingWeatherContinues::
|
||||
printfromtable gSandStormHailSnowContinuesStringIds
|
||||
BattleScript_WeatherContinues::
|
||||
printfromtable gWeatherTurnStringIds
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
playanimation_var BS_ATTACKER, sB_ANIM_ARG1
|
||||
setbyte gBattleCommunication, 0
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_WeatherFaded::
|
||||
printfromtable gWeatherEndsStringIds
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_DamagingWeather::
|
||||
@ -5845,6 +5843,12 @@ BattleScript_DamagingWeather::
|
||||
hitanimation BS_SCRIPTING
|
||||
goto BattleScript_DoTurnDmg
|
||||
|
||||
BattleScript_FogEnded_Ret::
|
||||
printstring STRINGID_FOGLIFTED
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
return
|
||||
|
||||
BattleScript_IceBodyHeal::
|
||||
call BattleScript_AbilityPopUpScripting
|
||||
playanimation BS_SCRIPTING, B_ANIM_SIMPLE_HEAL
|
||||
@ -5854,42 +5858,6 @@ BattleScript_IceBodyHeal::
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
end2
|
||||
|
||||
BattleScript_SandStormHailSnowEnds::
|
||||
printfromtable gSandStormHailSnowEndStringIds
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_SunlightContinues::
|
||||
printstring STRINGID_SUNLIGHTSTRONG
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
playanimation BS_ATTACKER, B_ANIM_SUN_CONTINUES
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_SunlightFaded::
|
||||
printstring STRINGID_SUNLIGHTFADED
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_FogContinues::
|
||||
printstring STRINGID_FOGISDEEP
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
playanimation BS_ATTACKER, B_ANIM_FOG_CONTINUES
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
end2
|
||||
|
||||
BattleScript_FogEnded_Ret::
|
||||
printstring STRINGID_FOGLIFTED
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
call BattleScript_ActivateWeatherAbilities
|
||||
return
|
||||
|
||||
BattleScript_FogEnded::
|
||||
call BattleScript_FogEnded_Ret
|
||||
end2
|
||||
|
||||
BattleScript_OverworldStatusStarts::
|
||||
printfromtable gStartingStatusStringIds
|
||||
waitmessage B_WAIT_TIME_LONG
|
||||
@ -6060,7 +6028,7 @@ BattleScript_RoarSuccessSwitch::
|
||||
switchindataupdate BS_TARGET
|
||||
trytoclearprimalweather
|
||||
flushtextbox
|
||||
switchinanim BS_TARGET, FALSE
|
||||
switchinanim BS_TARGET, FALSE, FALSE
|
||||
waitstate
|
||||
printstring STRINGID_PKMNWASDRAGGEDOUT
|
||||
switchineffects BS_TARGET
|
||||
@ -7625,7 +7593,7 @@ BattleScript_EmergencyExitNoPopUp::
|
||||
switchindataupdate BS_TARGET
|
||||
hpthresholds BS_TARGET
|
||||
printstring STRINGID_SWITCHINMON
|
||||
switchinanim BS_TARGET, TRUE
|
||||
switchinanim BS_TARGET, FALSE, TRUE
|
||||
waitstate
|
||||
switchineffects BS_TARGET
|
||||
BattleScript_EmergencyExitRet:
|
||||
@ -9587,7 +9555,7 @@ BattleScript_EjectButtonActivates::
|
||||
trytoclearprimalweather
|
||||
flushtextbox
|
||||
printstring 0x3
|
||||
switchinanim BS_SCRIPTING 0x1
|
||||
switchinanim BS_SCRIPTING, FALSE, TRUE
|
||||
waitstate
|
||||
switchineffects BS_SCRIPTING
|
||||
BattleScript_EjectButtonEnd:
|
||||
@ -9951,7 +9919,7 @@ BattleScript_DynamaxBegins::
|
||||
returnatktoball
|
||||
pause B_WAIT_TIME_SHORT
|
||||
returntoball BS_SCRIPTING, TRUE
|
||||
switchinanim BS_SCRIPTING, TRUE
|
||||
switchinanim BS_SCRIPTING, TRUE, TRUE
|
||||
updatedynamax
|
||||
playanimation BS_SCRIPTING, B_ANIM_DYNAMAX_GROWTH
|
||||
waitanimation
|
||||
@ -10035,7 +10003,7 @@ BattleScript_EffectSnow::
|
||||
attackstring
|
||||
ppreduce
|
||||
call BattleScript_CheckPrimalWeather
|
||||
setfieldweather ENUM_WEATHER_SNOW
|
||||
setfieldweather BATTLE_WEATHER_SNOW
|
||||
goto BattleScript_MoveWeatherChange
|
||||
|
||||
BattleScript_SleepClauseBlocked::
|
||||
|
||||
@ -75,7 +75,7 @@ BattleScript_ItemRestoreHP_Party::
|
||||
return
|
||||
|
||||
BattleScript_ItemRestoreHP_SendOutRevivedBattler:
|
||||
switchinanim BS_SCRIPTING, FALSE
|
||||
switchinanim BS_SCRIPTING, FALSE, FALSE
|
||||
waitstate
|
||||
switchineffects BS_SCRIPTING
|
||||
end
|
||||
|
||||
@ -20,6 +20,7 @@
|
||||
#include "constants/contest.h"
|
||||
#include "constants/daycare.h"
|
||||
#include "constants/decorations.h"
|
||||
#include "constants/difficulty.h"
|
||||
#include "constants/easy_chat.h"
|
||||
#include "constants/event_objects.h"
|
||||
#include "constants/event_object_movement.h"
|
||||
|
||||
@ -1,234 +1,245 @@
|
||||
@ 'requests_effects' should be set to 1 if the command contains a call
|
||||
@ to 'Script_RequestEffects', which allows it to be analyzed with
|
||||
@ 'RunScriptImmediatelyUntilEffect'.
|
||||
.macro cmd func:req, requests_effects=0
|
||||
.if \requests_effects == 0
|
||||
.4byte \func
|
||||
.else
|
||||
.4byte \func + ROM_SIZE
|
||||
.endif
|
||||
.endm
|
||||
|
||||
.align 2
|
||||
gScriptCmdTable::
|
||||
.4byte ScrCmd_nop @ 0x00
|
||||
.4byte ScrCmd_nop1 @ 0x01
|
||||
.4byte ScrCmd_end @ 0x02
|
||||
.4byte ScrCmd_return @ 0x03
|
||||
.4byte ScrCmd_call @ 0x04
|
||||
.4byte ScrCmd_goto @ 0x05
|
||||
.4byte ScrCmd_goto_if @ 0x06
|
||||
.4byte ScrCmd_call_if @ 0x07
|
||||
.4byte ScrCmd_gotostd @ 0x08
|
||||
.4byte ScrCmd_callstd @ 0x09
|
||||
.4byte ScrCmd_gotostd_if @ 0x0a
|
||||
.4byte ScrCmd_callstd_if @ 0x0b
|
||||
.4byte ScrCmd_returnram @ 0x0c
|
||||
.4byte ScrCmd_endram @ 0x0d
|
||||
.4byte ScrCmd_setmysteryeventstatus @ 0x0e
|
||||
.4byte ScrCmd_loadword @ 0x0f
|
||||
.4byte ScrCmd_loadbyte @ 0x10
|
||||
.4byte ScrCmd_setptr @ 0x11
|
||||
.4byte ScrCmd_loadbytefromptr @ 0x12
|
||||
.4byte ScrCmd_setptrbyte @ 0x13
|
||||
.4byte ScrCmd_copylocal @ 0x14
|
||||
.4byte ScrCmd_copybyte @ 0x15
|
||||
.4byte ScrCmd_setvar @ 0x16
|
||||
.4byte ScrCmd_addvar @ 0x17
|
||||
.4byte ScrCmd_subvar @ 0x18
|
||||
.4byte ScrCmd_copyvar @ 0x19
|
||||
.4byte ScrCmd_setorcopyvar @ 0x1a
|
||||
.4byte ScrCmd_compare_local_to_local @ 0x1b
|
||||
.4byte ScrCmd_compare_local_to_value @ 0x1c
|
||||
.4byte ScrCmd_compare_local_to_ptr @ 0x1d
|
||||
.4byte ScrCmd_compare_ptr_to_local @ 0x1e
|
||||
.4byte ScrCmd_compare_ptr_to_value @ 0x1f
|
||||
.4byte ScrCmd_compare_ptr_to_ptr @ 0x20
|
||||
.4byte ScrCmd_compare_var_to_value @ 0x21
|
||||
.4byte ScrCmd_compare_var_to_var @ 0x22
|
||||
.4byte ScrCmd_callnative @ 0x23
|
||||
.4byte ScrCmd_gotonative @ 0x24
|
||||
.4byte ScrCmd_special @ 0x25
|
||||
.4byte ScrCmd_specialvar @ 0x26
|
||||
.4byte ScrCmd_waitstate @ 0x27
|
||||
.4byte ScrCmd_delay @ 0x28
|
||||
.4byte ScrCmd_setflag @ 0x29
|
||||
.4byte ScrCmd_clearflag @ 0x2a
|
||||
.4byte ScrCmd_checkflag @ 0x2b
|
||||
.4byte ScrCmd_initclock @ 0x2c
|
||||
.4byte ScrCmd_dotimebasedevents @ 0x2d
|
||||
.4byte ScrCmd_gettime @ 0x2e
|
||||
.4byte ScrCmd_playse @ 0x2f
|
||||
.4byte ScrCmd_waitse @ 0x30
|
||||
.4byte ScrCmd_playfanfare @ 0x31
|
||||
.4byte ScrCmd_waitfanfare @ 0x32
|
||||
.4byte ScrCmd_playbgm @ 0x33
|
||||
.4byte ScrCmd_savebgm @ 0x34
|
||||
.4byte ScrCmd_fadedefaultbgm @ 0x35
|
||||
.4byte ScrCmd_fadenewbgm @ 0x36
|
||||
.4byte ScrCmd_fadeoutbgm @ 0x37
|
||||
.4byte ScrCmd_fadeinbgm @ 0x38
|
||||
.4byte ScrCmd_warp @ 0x39
|
||||
.4byte ScrCmd_warpsilent @ 0x3a
|
||||
.4byte ScrCmd_warpdoor @ 0x3b
|
||||
.4byte ScrCmd_warphole @ 0x3c
|
||||
.4byte ScrCmd_warpteleport @ 0x3d
|
||||
.4byte ScrCmd_setwarp @ 0x3e
|
||||
.4byte ScrCmd_setdynamicwarp @ 0x3f
|
||||
.4byte ScrCmd_setdivewarp @ 0x40
|
||||
.4byte ScrCmd_setholewarp @ 0x41
|
||||
.4byte ScrCmd_getplayerxy @ 0x42
|
||||
.4byte ScrCmd_getpartysize @ 0x43
|
||||
.4byte ScrCmd_additem @ 0x44
|
||||
.4byte ScrCmd_removeitem @ 0x45
|
||||
.4byte ScrCmd_checkitemspace @ 0x46
|
||||
.4byte ScrCmd_checkitem @ 0x47
|
||||
.4byte ScrCmd_checkitemtype @ 0x48
|
||||
.4byte ScrCmd_addpcitem @ 0x49
|
||||
.4byte ScrCmd_checkpcitem @ 0x4a
|
||||
.4byte ScrCmd_adddecoration @ 0x4b
|
||||
.4byte ScrCmd_removedecoration @ 0x4c
|
||||
.4byte ScrCmd_checkdecor @ 0x4d
|
||||
.4byte ScrCmd_checkdecorspace @ 0x4e
|
||||
.4byte ScrCmd_applymovement @ 0x4f
|
||||
.4byte ScrCmd_applymovementat @ 0x50
|
||||
.4byte ScrCmd_waitmovement @ 0x51
|
||||
.4byte ScrCmd_waitmovementat @ 0x52
|
||||
.4byte ScrCmd_removeobject @ 0x53
|
||||
.4byte ScrCmd_removeobjectat @ 0x54
|
||||
.4byte ScrCmd_addobject @ 0x55
|
||||
.4byte ScrCmd_addobjectat @ 0x56
|
||||
.4byte ScrCmd_setobjectxy @ 0x57
|
||||
.4byte ScrCmd_showobjectat @ 0x58
|
||||
.4byte ScrCmd_hideobjectat @ 0x59
|
||||
.4byte ScrCmd_faceplayer @ 0x5a
|
||||
.4byte ScrCmd_turnobject @ 0x5b
|
||||
.4byte ScrCmd_trainerbattle @ 0x5c
|
||||
.4byte ScrCmd_dotrainerbattle @ 0x5d
|
||||
.4byte ScrCmd_gotopostbattlescript @ 0x5e
|
||||
.4byte ScrCmd_gotobeatenscript @ 0x5f
|
||||
.4byte ScrCmd_checktrainerflag @ 0x60
|
||||
.4byte ScrCmd_settrainerflag @ 0x61
|
||||
.4byte ScrCmd_cleartrainerflag @ 0x62
|
||||
.4byte ScrCmd_setobjectxyperm @ 0x63
|
||||
.4byte ScrCmd_copyobjectxytoperm @ 0x64
|
||||
.4byte ScrCmd_setobjectmovementtype @ 0x65
|
||||
.4byte ScrCmd_waitmessage @ 0x66
|
||||
.4byte ScrCmd_message @ 0x67
|
||||
.4byte ScrCmd_closemessage @ 0x68
|
||||
.4byte ScrCmd_lockall @ 0x69
|
||||
.4byte ScrCmd_lock @ 0x6a
|
||||
.4byte ScrCmd_releaseall @ 0x6b
|
||||
.4byte ScrCmd_release @ 0x6c
|
||||
.4byte ScrCmd_waitbuttonpress @ 0x6d
|
||||
.4byte ScrCmd_yesnobox @ 0x6e
|
||||
.4byte ScrCmd_multichoice @ 0x6f
|
||||
.4byte ScrCmd_multichoicedefault @ 0x70
|
||||
.4byte ScrCmd_multichoicegrid @ 0x71
|
||||
.4byte ScrCmd_drawbox @ 0x72
|
||||
.4byte ScrCmd_erasebox @ 0x73
|
||||
.4byte ScrCmd_drawboxtext @ 0x74
|
||||
.4byte ScrCmd_showmonpic @ 0x75
|
||||
.4byte ScrCmd_hidemonpic @ 0x76
|
||||
.4byte ScrCmd_showcontestpainting @ 0x77
|
||||
.4byte ScrCmd_braillemessage @ 0x78
|
||||
.4byte ScrCmd_nop1 @ 0x79
|
||||
.4byte ScrCmd_giveegg @ 0x7a
|
||||
.4byte ScrCmd_setmonmove @ 0x7b
|
||||
.4byte ScrCmd_checkpartymove @ 0x7c
|
||||
.4byte ScrCmd_bufferspeciesname @ 0x7d
|
||||
.4byte ScrCmd_bufferleadmonspeciesname @ 0x7e
|
||||
.4byte ScrCmd_bufferpartymonnick @ 0x7f
|
||||
.4byte ScrCmd_bufferitemname @ 0x80
|
||||
.4byte ScrCmd_bufferdecorationname @ 0x81
|
||||
.4byte ScrCmd_buffermovename @ 0x82
|
||||
.4byte ScrCmd_buffernumberstring @ 0x83
|
||||
.4byte ScrCmd_bufferstdstring @ 0x84
|
||||
.4byte ScrCmd_bufferstring @ 0x85
|
||||
.4byte ScrCmd_pokemart @ 0x86
|
||||
.4byte ScrCmd_pokemartdecoration @ 0x87
|
||||
.4byte ScrCmd_pokemartdecoration2 @ 0x88
|
||||
.4byte ScrCmd_playslotmachine @ 0x89
|
||||
.4byte ScrCmd_setberrytree @ 0x8a
|
||||
.4byte ScrCmd_choosecontestmon @ 0x8b
|
||||
.4byte ScrCmd_startcontest @ 0x8c
|
||||
.4byte ScrCmd_showcontestresults @ 0x8d
|
||||
.4byte ScrCmd_contestlinktransfer @ 0x8e
|
||||
.4byte ScrCmd_random @ 0x8f
|
||||
.4byte ScrCmd_addmoney @ 0x90
|
||||
.4byte ScrCmd_removemoney @ 0x91
|
||||
.4byte ScrCmd_checkmoney @ 0x92
|
||||
.4byte ScrCmd_showmoneybox @ 0x93
|
||||
.4byte ScrCmd_hidemoneybox @ 0x94
|
||||
.4byte ScrCmd_updatemoneybox @ 0x95
|
||||
.4byte ScrCmd_getpokenewsactive @ 0x96
|
||||
.4byte ScrCmd_fadescreen @ 0x97
|
||||
.4byte ScrCmd_fadescreenspeed @ 0x98
|
||||
.4byte ScrCmd_setflashlevel @ 0x99
|
||||
.4byte ScrCmd_animateflash @ 0x9a
|
||||
.4byte ScrCmd_messageautoscroll @ 0x9b
|
||||
.4byte ScrCmd_dofieldeffect @ 0x9c
|
||||
.4byte ScrCmd_setfieldeffectargument @ 0x9d
|
||||
.4byte ScrCmd_waitfieldeffect @ 0x9e
|
||||
.4byte ScrCmd_setrespawn @ 0x9f
|
||||
.4byte ScrCmd_checkplayergender @ 0xa0
|
||||
.4byte ScrCmd_playmoncry @ 0xa1
|
||||
.4byte ScrCmd_setmetatile @ 0xa2
|
||||
.4byte ScrCmd_resetweather @ 0xa3
|
||||
.4byte ScrCmd_setweather @ 0xa4
|
||||
.4byte ScrCmd_doweather @ 0xa5
|
||||
.4byte ScrCmd_setstepcallback @ 0xa6
|
||||
.4byte ScrCmd_setmaplayoutindex @ 0xa7
|
||||
.4byte ScrCmd_setobjectsubpriority @ 0xa8
|
||||
.4byte ScrCmd_resetobjectsubpriority @ 0xa9
|
||||
.4byte ScrCmd_createvobject @ 0xaa
|
||||
.4byte ScrCmd_turnvobject @ 0xab
|
||||
.4byte ScrCmd_opendoor @ 0xac
|
||||
.4byte ScrCmd_closedoor @ 0xad
|
||||
.4byte ScrCmd_waitdooranim @ 0xae
|
||||
.4byte ScrCmd_setdooropen @ 0xaf
|
||||
.4byte ScrCmd_setdoorclosed @ 0xb0
|
||||
.4byte ScrCmd_addelevmenuitem @ 0xb1
|
||||
.4byte ScrCmd_showelevmenu @ 0xb2
|
||||
.4byte ScrCmd_checkcoins @ 0xb3
|
||||
.4byte ScrCmd_addcoins @ 0xb4
|
||||
.4byte ScrCmd_removecoins @ 0xb5
|
||||
.4byte ScrCmd_setwildbattle @ 0xb6
|
||||
.4byte ScrCmd_dowildbattle @ 0xb7
|
||||
.4byte ScrCmd_setvaddress @ 0xb8
|
||||
.4byte ScrCmd_vgoto @ 0xb9
|
||||
.4byte ScrCmd_vcall @ 0xba
|
||||
.4byte ScrCmd_vgoto_if @ 0xbb
|
||||
.4byte ScrCmd_vcall_if @ 0xbc
|
||||
.4byte ScrCmd_vmessage @ 0xbd
|
||||
.4byte ScrCmd_vbuffermessage @ 0xbe
|
||||
.4byte ScrCmd_vbufferstring @ 0xbf
|
||||
.4byte ScrCmd_showcoinsbox @ 0xc0
|
||||
.4byte ScrCmd_hidecoinsbox @ 0xc1
|
||||
.4byte ScrCmd_updatecoinsbox @ 0xc2
|
||||
.4byte ScrCmd_incrementgamestat @ 0xc3
|
||||
.4byte ScrCmd_setescapewarp @ 0xc4
|
||||
.4byte ScrCmd_waitmoncry @ 0xc5
|
||||
.4byte ScrCmd_bufferboxname @ 0xc6
|
||||
.4byte ScrCmd_nop1 @ 0xc7
|
||||
.4byte ScrCmd_nop1 @ 0xc8
|
||||
.4byte ScrCmd_nop1 @ 0xc9
|
||||
.4byte ScrCmd_nop1 @ 0xca
|
||||
.4byte ScrCmd_nop1 @ 0xcb
|
||||
.4byte ScrCmd_nop1 @ 0xcc
|
||||
.4byte ScrCmd_setmodernfatefulencounter @ 0xcd
|
||||
.4byte ScrCmd_checkmodernfatefulencounter @ 0xce
|
||||
.4byte ScrCmd_trywondercardscript @ 0xcf
|
||||
.4byte ScrCmd_nop1 @ 0xd0
|
||||
.4byte ScrCmd_warpspinenter @ 0xd1
|
||||
.4byte ScrCmd_setmonmetlocation @ 0xd2
|
||||
.4byte ScrCmd_moverotatingtileobjects @ 0xd3
|
||||
.4byte ScrCmd_turnrotatingtileobjects @ 0xd4
|
||||
.4byte ScrCmd_initrotatingtilepuzzle @ 0xd5
|
||||
.4byte ScrCmd_freerotatingtilepuzzle @ 0xd6
|
||||
.4byte ScrCmd_warpmossdeepgym @ 0xd7
|
||||
.4byte ScrCmd_selectapproachingtrainer @ 0xd8
|
||||
.4byte ScrCmd_lockfortrainer @ 0xd9
|
||||
.4byte ScrCmd_closebraillemessage @ 0xda
|
||||
.4byte ScrCmd_messageinstant @ 0xdb
|
||||
.4byte ScrCmd_fadescreenswapbuffers @ 0xdc
|
||||
.4byte ScrCmd_buffertrainerclassname @ 0xdd
|
||||
.4byte ScrCmd_buffertrainername @ 0xde
|
||||
.4byte ScrCmd_pokenavcall @ 0xdf
|
||||
.4byte ScrCmd_warpwhitefade @ 0xe0
|
||||
.4byte ScrCmd_buffercontestname @ 0xe1
|
||||
.4byte ScrCmd_bufferitemnameplural @ 0xe2
|
||||
.4byte ScrCmd_dynmultichoice @ 0xe3
|
||||
.4byte ScrCmd_dynmultipush @ 0xe4
|
||||
cmd ScrCmd_nop, requests_effects=1 @ 0x00
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0x01
|
||||
cmd ScrCmd_end, requests_effects=1 @ 0x02
|
||||
cmd ScrCmd_return, requests_effects=1 @ 0x03
|
||||
cmd ScrCmd_call, requests_effects=1 @ 0x04
|
||||
cmd ScrCmd_goto, requests_effects=1 @ 0x05
|
||||
cmd ScrCmd_goto_if, requests_effects=1 @ 0x06
|
||||
cmd ScrCmd_call_if, requests_effects=1 @ 0x07
|
||||
cmd ScrCmd_gotostd, requests_effects=1 @ 0x08
|
||||
cmd ScrCmd_callstd, requests_effects=1 @ 0x09
|
||||
cmd ScrCmd_gotostd_if, requests_effects=1 @ 0x0a
|
||||
cmd ScrCmd_callstd_if, requests_effects=1 @ 0x0b
|
||||
cmd ScrCmd_returnram, requests_effects=1 @ 0x0c
|
||||
cmd ScrCmd_endram, requests_effects=1 @ 0x0d
|
||||
cmd ScrCmd_setmysteryeventstatus, requests_effects=1 @ 0x0e
|
||||
cmd ScrCmd_loadword, requests_effects=1 @ 0x0f
|
||||
cmd ScrCmd_loadbyte, requests_effects=1 @ 0x10
|
||||
cmd ScrCmd_setptr, requests_effects=1 @ 0x11
|
||||
cmd ScrCmd_loadbytefromptr, requests_effects=1 @ 0x12
|
||||
cmd ScrCmd_setptrbyte, requests_effects=1 @ 0x13
|
||||
cmd ScrCmd_copylocal, requests_effects=1 @ 0x14
|
||||
cmd ScrCmd_copybyte, requests_effects=1 @ 0x15
|
||||
cmd ScrCmd_setvar, requests_effects=1 @ 0x16
|
||||
cmd ScrCmd_addvar, requests_effects=1 @ 0x17
|
||||
cmd ScrCmd_subvar, requests_effects=1 @ 0x18
|
||||
cmd ScrCmd_copyvar, requests_effects=1 @ 0x19
|
||||
cmd ScrCmd_setorcopyvar, requests_effects=1 @ 0x1a
|
||||
cmd ScrCmd_compare_local_to_local, requests_effects=1 @ 0x1b
|
||||
cmd ScrCmd_compare_local_to_value, requests_effects=1 @ 0x1c
|
||||
cmd ScrCmd_compare_local_to_ptr, requests_effects=1 @ 0x1d
|
||||
cmd ScrCmd_compare_ptr_to_local, requests_effects=1 @ 0x1e
|
||||
cmd ScrCmd_compare_ptr_to_value, requests_effects=1 @ 0x1f
|
||||
cmd ScrCmd_compare_ptr_to_ptr, requests_effects=1 @ 0x20
|
||||
cmd ScrCmd_compare_var_to_value, requests_effects=1 @ 0x21
|
||||
cmd ScrCmd_compare_var_to_var, requests_effects=1 @ 0x22
|
||||
cmd ScrCmd_callnative, requests_effects=1 @ 0x23
|
||||
cmd ScrCmd_gotonative, requests_effects=1 @ 0x24
|
||||
cmd ScrCmd_special, requests_effects=1 @ 0x25
|
||||
cmd ScrCmd_specialvar, requests_effects=1 @ 0x26
|
||||
cmd ScrCmd_waitstate, requests_effects=1 @ 0x27
|
||||
cmd ScrCmd_delay, requests_effects=1 @ 0x28
|
||||
cmd ScrCmd_setflag, requests_effects=1 @ 0x29
|
||||
cmd ScrCmd_clearflag, requests_effects=1 @ 0x2a
|
||||
cmd ScrCmd_checkflag, requests_effects=1 @ 0x2b
|
||||
cmd ScrCmd_initclock, requests_effects=1 @ 0x2c
|
||||
cmd ScrCmd_dotimebasedevents, requests_effects=1 @ 0x2d
|
||||
cmd ScrCmd_gettime, requests_effects=1 @ 0x2e
|
||||
cmd ScrCmd_playse, requests_effects=1 @ 0x2f
|
||||
cmd ScrCmd_waitse, requests_effects=1 @ 0x30
|
||||
cmd ScrCmd_playfanfare, requests_effects=1 @ 0x31
|
||||
cmd ScrCmd_waitfanfare, requests_effects=1 @ 0x32
|
||||
cmd ScrCmd_playbgm, requests_effects=1 @ 0x33
|
||||
cmd ScrCmd_savebgm, requests_effects=1 @ 0x34
|
||||
cmd ScrCmd_fadedefaultbgm, requests_effects=1 @ 0x35
|
||||
cmd ScrCmd_fadenewbgm, requests_effects=1 @ 0x36
|
||||
cmd ScrCmd_fadeoutbgm, requests_effects=1 @ 0x37
|
||||
cmd ScrCmd_fadeinbgm, requests_effects=1 @ 0x38
|
||||
cmd ScrCmd_warp, requests_effects=1 @ 0x39
|
||||
cmd ScrCmd_warpsilent, requests_effects=1 @ 0x3a
|
||||
cmd ScrCmd_warpdoor, requests_effects=1 @ 0x3b
|
||||
cmd ScrCmd_warphole, requests_effects=1 @ 0x3c
|
||||
cmd ScrCmd_warpteleport, requests_effects=1 @ 0x3d
|
||||
cmd ScrCmd_setwarp, requests_effects=1 @ 0x3e
|
||||
cmd ScrCmd_setdynamicwarp, requests_effects=1 @ 0x3f
|
||||
cmd ScrCmd_setdivewarp, requests_effects=1 @ 0x40
|
||||
cmd ScrCmd_setholewarp, requests_effects=1 @ 0x41
|
||||
cmd ScrCmd_getplayerxy, requests_effects=1 @ 0x42
|
||||
cmd ScrCmd_getpartysize, requests_effects=1 @ 0x43
|
||||
cmd ScrCmd_additem, requests_effects=1 @ 0x44
|
||||
cmd ScrCmd_removeitem, requests_effects=1 @ 0x45
|
||||
cmd ScrCmd_checkitemspace, requests_effects=1 @ 0x46
|
||||
cmd ScrCmd_checkitem, requests_effects=1 @ 0x47
|
||||
cmd ScrCmd_checkitemtype, requests_effects=1 @ 0x48
|
||||
cmd ScrCmd_addpcitem, requests_effects=1 @ 0x49
|
||||
cmd ScrCmd_checkpcitem, requests_effects=1 @ 0x4a
|
||||
cmd ScrCmd_adddecoration, requests_effects=1 @ 0x4b
|
||||
cmd ScrCmd_removedecoration, requests_effects=1 @ 0x4c
|
||||
cmd ScrCmd_checkdecor, requests_effects=1 @ 0x4d
|
||||
cmd ScrCmd_checkdecorspace, requests_effects=1 @ 0x4e
|
||||
cmd ScrCmd_applymovement, requests_effects=1 @ 0x4f
|
||||
cmd ScrCmd_applymovementat, requests_effects=1 @ 0x50
|
||||
cmd ScrCmd_waitmovement, requests_effects=1 @ 0x51
|
||||
cmd ScrCmd_waitmovementat, requests_effects=1 @ 0x52
|
||||
cmd ScrCmd_removeobject, requests_effects=1 @ 0x53
|
||||
cmd ScrCmd_removeobjectat, requests_effects=1 @ 0x54
|
||||
cmd ScrCmd_addobject, requests_effects=1 @ 0x55
|
||||
cmd ScrCmd_addobjectat, requests_effects=1 @ 0x56
|
||||
cmd ScrCmd_setobjectxy, requests_effects=1 @ 0x57
|
||||
cmd ScrCmd_showobjectat, requests_effects=1 @ 0x58
|
||||
cmd ScrCmd_hideobjectat, requests_effects=1 @ 0x59
|
||||
cmd ScrCmd_faceplayer, requests_effects=1 @ 0x5a
|
||||
cmd ScrCmd_turnobject, requests_effects=1 @ 0x5b
|
||||
cmd ScrCmd_trainerbattle, requests_effects=1 @ 0x5c
|
||||
cmd ScrCmd_dotrainerbattle, requests_effects=1 @ 0x5d
|
||||
cmd ScrCmd_gotopostbattlescript, requests_effects=1 @ 0x5e
|
||||
cmd ScrCmd_gotobeatenscript, requests_effects=1 @ 0x5f
|
||||
cmd ScrCmd_checktrainerflag, requests_effects=1 @ 0x60
|
||||
cmd ScrCmd_settrainerflag, requests_effects=1 @ 0x61
|
||||
cmd ScrCmd_cleartrainerflag, requests_effects=1 @ 0x62
|
||||
cmd ScrCmd_setobjectxyperm, requests_effects=1 @ 0x63
|
||||
cmd ScrCmd_copyobjectxytoperm, requests_effects=1 @ 0x64
|
||||
cmd ScrCmd_setobjectmovementtype, requests_effects=1 @ 0x65
|
||||
cmd ScrCmd_waitmessage, requests_effects=1 @ 0x66
|
||||
cmd ScrCmd_message, requests_effects=1 @ 0x67
|
||||
cmd ScrCmd_closemessage, requests_effects=1 @ 0x68
|
||||
cmd ScrCmd_lockall, requests_effects=1 @ 0x69
|
||||
cmd ScrCmd_lock, requests_effects=1 @ 0x6a
|
||||
cmd ScrCmd_releaseall, requests_effects=1 @ 0x6b
|
||||
cmd ScrCmd_release, requests_effects=1 @ 0x6c
|
||||
cmd ScrCmd_waitbuttonpress, requests_effects=1 @ 0x6d
|
||||
cmd ScrCmd_yesnobox, requests_effects=1 @ 0x6e
|
||||
cmd ScrCmd_multichoice, requests_effects=1 @ 0x6f
|
||||
cmd ScrCmd_multichoicedefault, requests_effects=1 @ 0x70
|
||||
cmd ScrCmd_multichoicegrid, requests_effects=1 @ 0x71
|
||||
cmd ScrCmd_drawbox, requests_effects=1 @ 0x72
|
||||
cmd ScrCmd_erasebox, requests_effects=1 @ 0x73
|
||||
cmd ScrCmd_drawboxtext, requests_effects=1 @ 0x74
|
||||
cmd ScrCmd_showmonpic, requests_effects=1 @ 0x75
|
||||
cmd ScrCmd_hidemonpic, requests_effects=1 @ 0x76
|
||||
cmd ScrCmd_showcontestpainting, requests_effects=1 @ 0x77
|
||||
cmd ScrCmd_braillemessage, requests_effects=1 @ 0x78
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0x79
|
||||
cmd ScrCmd_giveegg, requests_effects=1 @ 0x7a
|
||||
cmd ScrCmd_setmonmove, requests_effects=1 @ 0x7b
|
||||
cmd ScrCmd_checkpartymove, requests_effects=1 @ 0x7c
|
||||
cmd ScrCmd_bufferspeciesname, requests_effects=1 @ 0x7d
|
||||
cmd ScrCmd_bufferleadmonspeciesname, requests_effects=1 @ 0x7e
|
||||
cmd ScrCmd_bufferpartymonnick, requests_effects=1 @ 0x7f
|
||||
cmd ScrCmd_bufferitemname, requests_effects=1 @ 0x80
|
||||
cmd ScrCmd_bufferdecorationname, requests_effects=1 @ 0x81
|
||||
cmd ScrCmd_buffermovename, requests_effects=1 @ 0x82
|
||||
cmd ScrCmd_buffernumberstring, requests_effects=1 @ 0x83
|
||||
cmd ScrCmd_bufferstdstring, requests_effects=1 @ 0x84
|
||||
cmd ScrCmd_bufferstring, requests_effects=1 @ 0x85
|
||||
cmd ScrCmd_pokemart, requests_effects=1 @ 0x86
|
||||
cmd ScrCmd_pokemartdecoration, requests_effects=1 @ 0x87
|
||||
cmd ScrCmd_pokemartdecoration2, requests_effects=1 @ 0x88
|
||||
cmd ScrCmd_playslotmachine, requests_effects=1 @ 0x89
|
||||
cmd ScrCmd_setberrytree, requests_effects=1 @ 0x8a
|
||||
cmd ScrCmd_choosecontestmon, requests_effects=1 @ 0x8b
|
||||
cmd ScrCmd_startcontest, requests_effects=1 @ 0x8c
|
||||
cmd ScrCmd_showcontestresults, requests_effects=1 @ 0x8d
|
||||
cmd ScrCmd_contestlinktransfer, requests_effects=1 @ 0x8e
|
||||
cmd ScrCmd_random, requests_effects=1 @ 0x8f
|
||||
cmd ScrCmd_addmoney, requests_effects=1 @ 0x90
|
||||
cmd ScrCmd_removemoney, requests_effects=1 @ 0x91
|
||||
cmd ScrCmd_checkmoney, requests_effects=1 @ 0x92
|
||||
cmd ScrCmd_showmoneybox, requests_effects=1 @ 0x93
|
||||
cmd ScrCmd_hidemoneybox, requests_effects=1 @ 0x94
|
||||
cmd ScrCmd_updatemoneybox, requests_effects=1 @ 0x95
|
||||
cmd ScrCmd_getpokenewsactive, requests_effects=1 @ 0x96
|
||||
cmd ScrCmd_fadescreen, requests_effects=1 @ 0x97
|
||||
cmd ScrCmd_fadescreenspeed, requests_effects=1 @ 0x98
|
||||
cmd ScrCmd_setflashlevel, requests_effects=1 @ 0x99
|
||||
cmd ScrCmd_animateflash, requests_effects=1 @ 0x9a
|
||||
cmd ScrCmd_messageautoscroll, requests_effects=1 @ 0x9b
|
||||
cmd ScrCmd_dofieldeffect, requests_effects=1 @ 0x9c
|
||||
cmd ScrCmd_setfieldeffectargument, requests_effects=1 @ 0x9d
|
||||
cmd ScrCmd_waitfieldeffect, requests_effects=1 @ 0x9e
|
||||
cmd ScrCmd_setrespawn, requests_effects=1 @ 0x9f
|
||||
cmd ScrCmd_checkplayergender, requests_effects=1 @ 0xa0
|
||||
cmd ScrCmd_playmoncry, requests_effects=1 @ 0xa1
|
||||
cmd ScrCmd_setmetatile, requests_effects=1 @ 0xa2
|
||||
cmd ScrCmd_resetweather, requests_effects=1 @ 0xa3
|
||||
cmd ScrCmd_setweather, requests_effects=1 @ 0xa4
|
||||
cmd ScrCmd_doweather, requests_effects=1 @ 0xa5
|
||||
cmd ScrCmd_setstepcallback, requests_effects=1 @ 0xa6
|
||||
cmd ScrCmd_setmaplayoutindex, requests_effects=1 @ 0xa7
|
||||
cmd ScrCmd_setobjectsubpriority, requests_effects=1 @ 0xa8
|
||||
cmd ScrCmd_resetobjectsubpriority, requests_effects=1 @ 0xa9
|
||||
cmd ScrCmd_createvobject, requests_effects=1 @ 0xaa
|
||||
cmd ScrCmd_turnvobject, requests_effects=1 @ 0xab
|
||||
cmd ScrCmd_opendoor, requests_effects=1 @ 0xac
|
||||
cmd ScrCmd_closedoor, requests_effects=1 @ 0xad
|
||||
cmd ScrCmd_waitdooranim, requests_effects=1 @ 0xae
|
||||
cmd ScrCmd_setdooropen, requests_effects=1 @ 0xaf
|
||||
cmd ScrCmd_setdoorclosed, requests_effects=1 @ 0xb0
|
||||
cmd ScrCmd_addelevmenuitem, requests_effects=1 @ 0xb1
|
||||
cmd ScrCmd_showelevmenu, requests_effects=1 @ 0xb2
|
||||
cmd ScrCmd_checkcoins, requests_effects=1 @ 0xb3
|
||||
cmd ScrCmd_addcoins, requests_effects=1 @ 0xb4
|
||||
cmd ScrCmd_removecoins, requests_effects=1 @ 0xb5
|
||||
cmd ScrCmd_setwildbattle, requests_effects=1 @ 0xb6
|
||||
cmd ScrCmd_dowildbattle, requests_effects=1 @ 0xb7
|
||||
cmd ScrCmd_setvaddress, requests_effects=1 @ 0xb8
|
||||
cmd ScrCmd_vgoto, requests_effects=1 @ 0xb9
|
||||
cmd ScrCmd_vcall, requests_effects=1 @ 0xba
|
||||
cmd ScrCmd_vgoto_if, requests_effects=1 @ 0xbb
|
||||
cmd ScrCmd_vcall_if, requests_effects=1 @ 0xbc
|
||||
cmd ScrCmd_vmessage, requests_effects=1 @ 0xbd
|
||||
cmd ScrCmd_vbuffermessage, requests_effects=1 @ 0xbe
|
||||
cmd ScrCmd_vbufferstring, requests_effects=1 @ 0xbf
|
||||
cmd ScrCmd_showcoinsbox, requests_effects=1 @ 0xc0
|
||||
cmd ScrCmd_hidecoinsbox, requests_effects=1 @ 0xc1
|
||||
cmd ScrCmd_updatecoinsbox, requests_effects=1 @ 0xc2
|
||||
cmd ScrCmd_incrementgamestat, requests_effects=1 @ 0xc3
|
||||
cmd ScrCmd_setescapewarp, requests_effects=1 @ 0xc4
|
||||
cmd ScrCmd_waitmoncry, requests_effects=1 @ 0xc5
|
||||
cmd ScrCmd_bufferboxname, requests_effects=1 @ 0xc6
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xc7
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xc8
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xc9
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xca
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xcb
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xcc
|
||||
cmd ScrCmd_setmodernfatefulencounter, requests_effects=1 @ 0xcd
|
||||
cmd ScrCmd_checkmodernfatefulencounter, requests_effects=1 @ 0xce
|
||||
cmd ScrCmd_trywondercardscript, requests_effects=1 @ 0xcf
|
||||
cmd ScrCmd_nop1, requests_effects=1 @ 0xd0
|
||||
cmd ScrCmd_warpspinenter, requests_effects=1 @ 0xd1
|
||||
cmd ScrCmd_setmonmetlocation, requests_effects=1 @ 0xd2
|
||||
cmd ScrCmd_moverotatingtileobjects, requests_effects=1 @ 0xd3
|
||||
cmd ScrCmd_turnrotatingtileobjects, requests_effects=1 @ 0xd4
|
||||
cmd ScrCmd_initrotatingtilepuzzle, requests_effects=1 @ 0xd5
|
||||
cmd ScrCmd_freerotatingtilepuzzle, requests_effects=1 @ 0xd6
|
||||
cmd ScrCmd_warpmossdeepgym, requests_effects=1 @ 0xd7
|
||||
cmd ScrCmd_selectapproachingtrainer, requests_effects=1 @ 0xd8
|
||||
cmd ScrCmd_lockfortrainer, requests_effects=1 @ 0xd9
|
||||
cmd ScrCmd_closebraillemessage, requests_effects=1 @ 0xda
|
||||
cmd ScrCmd_messageinstant, requests_effects=1 @ 0xdb
|
||||
cmd ScrCmd_fadescreenswapbuffers, requests_effects=1 @ 0xdc
|
||||
cmd ScrCmd_buffertrainerclassname, requests_effects=1 @ 0xdd
|
||||
cmd ScrCmd_buffertrainername, requests_effects=1 @ 0xde
|
||||
cmd ScrCmd_pokenavcall, requests_effects=1 @ 0xdf
|
||||
cmd ScrCmd_warpwhitefade, requests_effects=1 @ 0xe0
|
||||
cmd ScrCmd_buffercontestname, requests_effects=1 @ 0xe1
|
||||
cmd ScrCmd_bufferitemnameplural, requests_effects=1 @ 0xe2
|
||||
cmd ScrCmd_dynmultichoice, requests_effects=1 @ 0xe3
|
||||
cmd ScrCmd_dynmultipush, requests_effects=1 @ 0xe4
|
||||
|
||||
gScriptCmdTableEnd::
|
||||
.4byte ScrCmd_nop
|
||||
|
||||
@ -385,6 +385,18 @@ EventScript_UseDig::
|
||||
lockall
|
||||
goto EventScript_DigCommon
|
||||
|
||||
|
||||
EventScript_CutGrassCommon:
|
||||
isfollowerfieldmoveuser VAR_0x8004
|
||||
setfieldeffectargument 3, VAR_0x8004 @ skip pose if true
|
||||
dofieldeffect FLDEFF_USE_CUT_ON_GRASS
|
||||
waitstate
|
||||
|
||||
@ Use Cut grass from party menu
|
||||
EventScript_UseCutGrass::
|
||||
lockall
|
||||
goto EventScript_CutGrassCommon
|
||||
|
||||
Text_CantDive:
|
||||
.string "The sea is deep here. A POKéMON\n"
|
||||
.string "may be able to go underwater.$"
|
||||
|
||||
@ -20,3 +20,9 @@ EventScript_GotoTrainerScript::
|
||||
gotobeatenscript
|
||||
releaseall
|
||||
end
|
||||
|
||||
EventScript_ObjectApproachPlayer::
|
||||
lock
|
||||
special DoTrainerApproach
|
||||
waitstate
|
||||
gotonative LoadTrainerObjectScript
|
||||
|
||||
@ -1,9 +1,16 @@
|
||||
.macro def_special ptr
|
||||
@ 'requests_effects' should be set to 1 if the special contains a call
|
||||
@ to 'Script_RequestEffects', which allows it to be analyzed with
|
||||
@ 'RunScriptImmediatelyUntilEffect'.
|
||||
.macro def_special ptr:req, requests_effects=0
|
||||
.global SPECIAL_\ptr
|
||||
.set SPECIAL_\ptr, __special__
|
||||
.set __special__, __special__ + 1
|
||||
.if \requests_effects == 0
|
||||
.4byte \ptr
|
||||
.endm
|
||||
.else
|
||||
.4byte \ptr + ROM_SIZE
|
||||
.endif
|
||||
.endm
|
||||
|
||||
.set __special__, 0
|
||||
.align 2
|
||||
@ -297,7 +304,7 @@ gSpecials::
|
||||
def_special WaitWeather
|
||||
def_special BufferEReaderTrainerName
|
||||
def_special GetSlotMachineId
|
||||
def_special GetPlayerFacingDirection
|
||||
def_special GetPlayerFacingDirection, requests_effects=TRUE
|
||||
def_special FoundAbandonedShipRoom1Key
|
||||
def_special FoundAbandonedShipRoom2Key
|
||||
def_special FoundAbandonedShipRoom4Key
|
||||
|
||||
@ -70,4 +70,5 @@
|
||||
- [Version 0.9.0](changelogs/0.9.x/0.9.0.md)
|
||||
- [Team Procedures]()
|
||||
- [How to make an Expansion version](team_procedures/expansion_versions.md)
|
||||
- [Scope Guidelines](scope.md)
|
||||
- [Release Schedule and Process](team_procedures/schedule.md)
|
||||
- [Scope Guidelines](team_procedures/scope.md)
|
||||
|
||||
@ -12,13 +12,13 @@ If you want the best performance and least amount of issues with Windows interfe
|
||||
2. Once the process finishes, restart your machine.
|
||||
|
||||
### WSL1
|
||||
3a. Open Windows Powershell **as Administrator** again (after restarting), and run the following command to configure Ubuntu to use WSL1.
|
||||
3. Open Windows Powershell **as Administrator** again (after restarting), and run the following command to configure Ubuntu to use WSL1.
|
||||
|
||||
```powershell
|
||||
wsl --set-version Ubuntu 1
|
||||
```
|
||||
### WSL2
|
||||
3a. Open Windows Powershell **as Administrator** again (after restarting), and run the following command to configure Ubuntu to use WSL2.
|
||||
3. Open Windows Powershell **as Administrator** again (after restarting), and run the following command to configure Ubuntu to use WSL2.
|
||||
|
||||
```powershell
|
||||
wsl --set-version Ubuntu 2
|
||||
|
||||
@ -1,54 +0,0 @@
|
||||
# Document Purpose
|
||||
|
||||
This document is a guide for contributors and Senate to decide if a feature is within "scope" for pokeemerald-expansion. If a feature is not in scope, then it should not be merged. Even if an opened PR is within scope, this does not mean it will be merged, as acceptance criteria will often come down to the details of the implementation.
|
||||
|
||||
# Definitions
|
||||
|
||||
* **Showdown Supported (SS)**: A core series game who's metagame can be played on Showdown.
|
||||
* Notably, this is every [core series game](https://bulbapedia.bulbagarden.net/wiki/Core_series#List_of_core_series_games) except Pokémon Legends: Arceus.
|
||||
* **Base Expansion Version**: "A .gba file built from an unmodified `master` or `upcoming` branch of `pokeemerald-expansion`.
|
||||
* **Vanilla Emerald Version**: A .gba file built from an unmodified `master` branch of pret's `pokeemerald`.
|
||||
|
||||
# Guidelines
|
||||
|
||||
A pull request meets the scope criteria if:
|
||||
* The feature does not belong to a category considered “not in scope” AND
|
||||
* The feature belongs to a category considered “in scope”
|
||||
|
||||
## In Scope Categories
|
||||
|
||||
1. **SS Species:** Adds Species that have appeared in a Showdown-supported title
|
||||
2. **SS Moves:** Adds Moves and Move Animations that have appeared in a Showdown-supported title
|
||||
3. **SS Abilities:** Adds Abilities that have appeared in a Showdown-supported title
|
||||
4. **SS Items:** Adds Items that have appeared in a Showdown-supported title
|
||||
5. **SS Gimmicks:** Adds Gimmicks that have appeared in a Showdown-supported title
|
||||
6. **SS Battle Types:** Adds Special Battle Types that have appeared in a Showdown-supported title
|
||||
7. **SS Battle Mechanics:** Adds mechanical battle changes that have appeared in a Showdown-supported title
|
||||
8. **Improve Battle AI:** Improve the Battle AI in a way that allows it to approach the skill and capability of a human competitive player
|
||||
9. **Base Link Compatibility:** Link compatibility with base
|
||||
10. **SS Overworld / Menu Updates:** Replicate overworld or menu changes from Showdown-supported Pokémon titles
|
||||
11. **Speed Up:** Speed up the player experience of features found in base
|
||||
12. **Compression:** Automatically compress assets
|
||||
13. **Novel Experience:** Adds a novel experience included in another Showdown Supported title
|
||||
15. **Helper Features:** Eases the addition or inclusion of any of the aforementioned
|
||||
|
||||
## Not In Scope Categories
|
||||
|
||||
1. **Non-SS Species**: Adds Species that have NOT appeared in a Showdown-supported title
|
||||
2. **Non-SS Moves**: Adds Moves and Move Animations that have NOT appeared in a Showdown-supported title
|
||||
3. **Non-SS Abilities**: Adds Abilities that have NOT appeared in a Showdown-supported title
|
||||
4. **Non-SS Items**: Adds Items that have NOT appeared in a Showdown-supported title
|
||||
5. **Non-SS Gimmicks**: Adds Gimmicks that have NOT appeared in a Showdown-supported title
|
||||
6. **Non-SS Battle Types**: Adds Special Battle Types that have NOT appeared in a Showdown-supported title
|
||||
7. **Duplicate Feature UI**: Adds functionality that duplicates the core functionality of an existing vanilla feature
|
||||
8. **Vanilla Link Compatibility**: Link compatibility with vanilla
|
||||
|
||||
## Discussion Required Categories
|
||||
|
||||
Pull Requests that fall into this category should be brought up to maintainers, who will discuss and vote as to whether or not the feature is considered in scope. Considerations for acceptance may include invasiveness of implementation, popularity, ease of maintenance, etc.
|
||||
|
||||
1. **Developer Ease of Use:** Lowers barrier of entry for developers to use existing behavior
|
||||
2. **Fangame Features:** Adds a popular feature from other fangames
|
||||
3. **Popular Non-SS Features:** Exceptions can be made for uniquely popular or requested features (Drowsy, PLA Legend Plate, etc.)
|
||||
4. **External Program**: External programs like poryscript, porymoves, etc.
|
||||
|
||||
51
docs/team_procedures/schedule.md
Normal file
@ -0,0 +1,51 @@
|
||||
# Release Schedule and Process
|
||||
|
||||
## Version Lifecycle
|
||||
|
||||
### Minor Release (90 days to next Minor Release)
|
||||
`upcoming` and `master` are synchronized. Minor Release should occur once every three months. Maintainers can vote to do extra Minor Releases for special cases, but this should be considered highly irregular.
|
||||
|
||||
### Patch Release (60 / 30 days to the next Minor Release)
|
||||
Releases that focus primarily on bugfixes or improvements to the test system. Patch Releases should occur AT LEAST once a month, but can be more frequent than that.
|
||||
|
||||
### Big Feature Freeze (30 days to the next Minor Release)
|
||||
PRs with the Github label [`type: big feature`](https://github.com/rh-hideout/pokeemerald-expansion/issues?q=sort%3Aupdated-desc+is%3Aopen+label%3A%22type%3A+big+feature%22) will NOT be merged until after the next Minor Release.
|
||||
|
||||
### Merge Freeze (14 days to the next Minor Release)
|
||||
PRs that DO NOT have the Github labels [`bugfix`](https://github.com/rh-hideout/pokeemerald-expansion/issues?q=sort%3Aupdated-desc+label%3Abugfix) or [`type: cleanup`](https://github.com/rh-hideout/pokeemerald-expansion/issues?q=sort%3Aupdated-desc+label%3A%22type%3A+cleanup%22+) will NOT be merged until after the next Minor Release.
|
||||
|
||||
|
||||
### Sample Schedule
|
||||
| Major | Minor | Patch | Type | Goal Date |
|
||||
| ----- | ----- | ----- | ------------------ | ----------- |
|
||||
| 2 | 1 | 0 | Minor | Dec 1 2025 |
|
||||
| 2 | 1 | 1 | Patch | Dec 31 2025 |
|
||||
| 2 | 1 | 2 | Patch | Jan 30 2026 |
|
||||
| 2 | 1 | 2 | Big Feature Freeze | Jan 30 2026 |
|
||||
| 2 | 1 | 2 | Merge Freeze | Feb 15 2026 |
|
||||
| 2 | 1 | 3 | Patch | Mar 1 2026 |
|
||||
| 2 | 2 | 0 | Minor | Mar 1 2026 |
|
||||
|
||||
---
|
||||
|
||||
## What is a "Big Feature"?
|
||||
* If the original owner of the PR thinks a feature should be labeled a Big Feature, it is, no questions asked
|
||||
* If a reviewer thinks a PR is a Big Feature, then it is
|
||||
* If the two disagree, it can be discussed in a PR thread, and can ultimately be resolved with a Maintainer vote.
|
||||
|
||||
### How To Identify a Big Feature
|
||||
* **Big diffs**: It's easy for something to go unnoticed in review when it's a tiny part of a massive diff.
|
||||
* **High-impact**: High-impact changes are harder to review because they often have consequences that aren't obvious to the reviewer. We catch these consequences from users who use upcoming reporting them.
|
||||
* **Subjective**: Subjective changes are more likely to have differences of opinions between senate members.
|
||||
* **Pervasive**: The PR touches several different parts of the codebase or is involved in several different parts of the codebase, even if those elements are small.
|
||||
|
||||
---
|
||||
|
||||
## Release Blocking and Milestones
|
||||
When an issue or PR is assigned to a [milestone on Github](https://github.com/rh-hideout/pokeemerald-expansion/milestones) by a Maintainer, that means it is "Blocking". If another Maintainer agrees with this, then that version cannot be released until that issue is resolved or PR is merged.
|
||||
|
||||
This designation should be reserved for instances where an existing feature on `upcoming` or `master` is broken and causing problems for users or players.
|
||||
|
||||
Blocking issues or PRs can be deferred to future releases but should be discussed with the Maintainers that assigned the designation in the first place.
|
||||
|
||||
If a version's milestone does not have any issues or PRs assigned to it, that version should be [released](https://github.com/rh-hideout/pokeemerald-expansion/blob/master/docs/team_procedures/expansion_versions.md) as close to the goal date as possible.
|
||||
69
docs/team_procedures/scope.md
Normal file
@ -0,0 +1,69 @@
|
||||
# Document Purpose
|
||||
|
||||
This document is a guide for contributors and Senate to decide if a feature is within "scope" for pokeemerald-expansion. "Scope" in this case comprises a list of features and concepts that could be merged if an appropriate implementation is submitted. If a feature is not in scope, then it should not be merged. Even if an opened PR is within scope, this does not mean it will be merged, as acceptance criteria will often come down to the details of the implementation.
|
||||
|
||||
# Definitions
|
||||
|
||||
* **Showdown Supported (SS)**: A core series game who's metagame can be played on Showdown.
|
||||
* Includes every [core series game](https://bulbapedia.bulbagarden.net/wiki/Core_series#List_of_core_series_games) except Pokémon Legends: Arceus.
|
||||
* Does not include [spin-off games](https://bulbapedia.bulbagarden.net/wiki/Spin-off_Pokémon_games) such as Pokémon Colosseum, Pokémon XD, Pokémon Trozei!, etc.
|
||||
* **Base Expansion Version**: "A .gba file built from an unmodified `master` or `upcoming` branch of `pokeemerald-expansion`.
|
||||
* **Vanilla Emerald Version**: A .gba file built from an unmodified `master` branch of pret's `pokeemerald`.
|
||||
|
||||
# Guidelines
|
||||
|
||||
A pull request meets the scope criteria if:
|
||||
* The feature does not belong to a category considered “not in scope” AND
|
||||
* The feature belongs to a category considered “in scope”
|
||||
|
||||
## In Scope Categories
|
||||
|
||||
1. **SS Species**: Adds Species that have appeared in a Showdown-supported title. Includes follower sprites for all defined species including battle-only ones (ie. Megas)
|
||||
2. **SS Moves**: Adds Moves and Move Animations that have appeared in a Showdown-supported title
|
||||
3. **SS Abilities**: Adds Abilities that have appeared in a Showdown-supported title
|
||||
4. **SS Items**: Adds Items that have appeared in a Showdown-supported title
|
||||
5. **SS Gimmicks**: Adds Gimmicks that have appeared in a Showdown-supported title (Dynamax, Mega Evolution, etc.)
|
||||
6. **SS Battle Types**: Adds Special Battle Types that have appeared in a Showdown-supported title (Triple battles, etc.)
|
||||
7. **SS Battle Mechanics**: Adds mechanical battle changes that have appeared in a Showdown-supported title, and allow developers to choose which generation suits them where applicable
|
||||
8. **Battle AI Behaviour**: Improvements towards the capability of a human competitive player, and unique or interesting behaviours otherwise
|
||||
9. **Base Link Compatibility**: The ability for two Base Expansion Version's to connect, trade, and battle one another
|
||||
10. **SS Overworld Features**: Add overworld changes / additions from Showdown-supported Pokémon titles (followers, raids, sideways stairs, etc.)
|
||||
11. **SS Menu Features**: Add menu changes / additions from Showdown-supported Pokémon titles (type effectivness indicator, PC functions, etc.)
|
||||
12. **Speed Up**: Optimize code to run more efficiently, take up less space, and work better overall to improves the developer and / or player experience
|
||||
13. **Compression**: Reduces the size of graphic or sound assets, etc. Includes automatic compression
|
||||
14. **Novel Experience**: Adds a novel experience included in another Showdown Supported title (poffins, fishing minigames, etc.)
|
||||
15. **Helper Features**: Eases the addition or inclusion of any of the aforementioned, or facilitates developer ease of use
|
||||
|
||||
## Not In Scope Categories
|
||||
|
||||
1. **Non-SS Species**: Adds Species that have NOT appeared in a Showdown-supported title (Fakemon, CAP Pokémon, etc.)
|
||||
2. **Non-SS Moves**: Adds Moves and Move Animations that have NOT appeared in a Showdown-supported title
|
||||
3. **Non-SS Abilities**: Adds Abilities that have NOT appeared in a Showdown-supported title
|
||||
4. **Non-SS Items**: Adds Items that have NOT appeared in a Showdown-supported title
|
||||
5. **Non-SS Gimmicks**: Adds Gimmicks that have NOT appeared in a Showdown-supported title (Showdown's Other Metagames, etc.)
|
||||
6. **Non-SS Battle Types**: Adds Special Battle Types that have NOT appeared in a Showdown-supported title
|
||||
7. **Overworld Maps**: Adds overworld maps from either Showdown-supported titles or non-Showdown-supported titles
|
||||
8. **Duplicate UIs**: Adds additional user interface that covers the same functionality of an existing feature (HGSS Pokédex, BW Summary Screen, etc.)
|
||||
9. **Vanilla Link Compatibility**: The ability for Base Expansion Version and Vanilla Emerald Version to connect, trade, and battle one another
|
||||
|
||||
## Discussion Required Categories
|
||||
|
||||
Pull Requests that fall into this category are not in scope by default and should be brought up to maintainers, who will discuss and vote as to whether or not the feature is considered in scope. Considerations for acceptance may include invasiveness of implementation, popularity, ease of maintenance, etc.
|
||||
|
||||
1. **Developer Ease of Use**: Lowers barrier of entry for developers to use existing behavior
|
||||
2. **Fangame Features**: Adds a popular feature from other fangames
|
||||
3. **Popular Non-SS Features**: Exceptions can be made for uniquely popular or requested features (Drowsy, PLA Legend Plate, etc.)
|
||||
4. **External Program**: External programs like poryscript, porymoves, etc.
|
||||
|
||||
## Workflow for Proposed Feature Scope Discussion
|
||||
For the contributor:
|
||||
- Make a thread for the feature on Discord
|
||||
- Describe how the feature fits into this scope document, and why you feel it should be considered
|
||||
- Optionally include either a draft PR or describe in some detail the proposed implementation. Non-mandatory, but implementation invasiveness, maintenance cost, etc. are major considerations, so use your judgement. The senate may ask for this information during discussion.
|
||||
|
||||
For the senate:
|
||||
- Make a senate thread for the discussion
|
||||
- Make and pin a two-week voting poll
|
||||
- Discuss, conclude, and cast votes before the two-week deadline
|
||||
- Inform contributor as to the results and reasons in their thread
|
||||
- Amend this scope document if necessary
|
||||
@ -67,7 +67,7 @@ AI will generally behave more recklessly. This AI enables the following behaviou
|
||||
* Switch offensively mid battle rather than defensively (if using `AI_FLAG_SMART_MON_CHOICES`)
|
||||
* Prioritize Explosion moves
|
||||
|
||||
## `AI_FLAG_PREFER_STRONGEST_MOVE`
|
||||
## `AI_FLAG_TRY_TO_2HKO`
|
||||
Adds score bonus to any move the AI has that either OHKOs or 2HKOs the player.
|
||||
|
||||
Keep in mind that this is a weaker form of `AI_FLAG_TRY_TO_FAINT` at scoring OHKOs as it does not take into account who is attacking first, it does however handle 2HKOs.
|
||||
@ -168,3 +168,6 @@ AI will always switch out after a KO in exactly party order as defined in the tr
|
||||
|
||||
## `AI_FLAG_WEIGH_ABILITY_PREDICTION`
|
||||
AI will predict the player's ability based to its aiRating. Without this flag the AI randomly assumes an ability with an even distribution between all possible abilities until one is confirmed. With this flag, it instead guesses proportionally to each ability's aiRating, making it far more likely to guess an ability like Water Absorb than Damp if both are options.
|
||||
|
||||
## `AI_FLAG_PREFER_HIGHEST_DAMAGE_MOVE`
|
||||
AI will add score to its highest damaging move, regardless of accuracy or secondary effects. Replaces deprecated `AI_FLAG_PREFER_STRONGEST_MOVE`.
|
||||
|
||||
@ -28,7 +28,7 @@ Let's look at an example:
|
||||
```c
|
||||
[MOVE_THUNDER_SHOCK] =
|
||||
{
|
||||
.name = HANDLE_EXPANDED_MOVE_NAME("ThunderShock", "Thunder Shock"),
|
||||
.name = COMPOUND_STRING("Thunder Shock"),
|
||||
.description = COMPOUND_STRING(
|
||||
"An electrical attack that\n"
|
||||
"may paralyze the foe."),
|
||||
@ -51,7 +51,7 @@ Let's look at an example:
|
||||
.contestComboMoves = {COMBO_STARTER_CHARGE},
|
||||
},
|
||||
```
|
||||
The `HANDLE_EXPANDED_MOVE_NAME` allows the usage of a name of extended character length, so long as the `B_EXPANDED_MOVE_NAMES` is set to `TRUE`, whereas by default it's limited in Gen 3 to 12 characters. Most of the fields here are obvious, but the two important ones for determining what a move actually *does* are `effect` and `additionalEffects`.
|
||||
Most of the fields here are obvious, but the two important ones for determining what a move actually *does* are `effect` and `additionalEffects`.
|
||||
|
||||
The `effect` represents how the move actually works when called in battle - it can be a two turn move, or a move that only works if the target is holding an item, for example. How each effect works is pretty much unique, but the way a move of a particular effect is executed is defined by a script [`data/battle_scripts_1.s`](#databattle_scripts_1s), and any *variable* characteristics such as typing or power are defined in either [`src/battle_script_commands.c`](#srcbattle_script_commandsc) or [`src/battle_util.c`](#srcbattle_utilc), depending on the effect. The vast majority of non-status moves are simply `EFFECT_HIT`, in that they deal damage and apply `additionalEffects` (if defined).
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 710 B After Width: | Height: | Size: 710 B |
|
Before Width: | Height: | Size: 471 B After Width: | Height: | Size: 471 B |
|
Before Width: | Height: | Size: 849 B After Width: | Height: | Size: 849 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 710 B After Width: | Height: | Size: 710 B |
|
Before Width: | Height: | Size: 474 B After Width: | Height: | Size: 474 B |
|
Before Width: | Height: | Size: 941 B After Width: | Height: | Size: 941 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 657 B After Width: | Height: | Size: 657 B |
|
Before Width: | Height: | Size: 508 B After Width: | Height: | Size: 508 B |
|
Before Width: | Height: | Size: 909 B After Width: | Height: | Size: 909 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 610 B After Width: | Height: | Size: 610 B |
|
Before Width: | Height: | Size: 493 B After Width: | Height: | Size: 493 B |
|
Before Width: | Height: | Size: 908 B After Width: | Height: | Size: 908 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 635 B After Width: | Height: | Size: 635 B |
|
Before Width: | Height: | Size: 467 B After Width: | Height: | Size: 467 B |
|
Before Width: | Height: | Size: 932 B After Width: | Height: | Size: 932 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 630 B After Width: | Height: | Size: 630 B |
|
Before Width: | Height: | Size: 459 B After Width: | Height: | Size: 459 B |
|
Before Width: | Height: | Size: 908 B After Width: | Height: | Size: 908 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 732 B After Width: | Height: | Size: 732 B |
|
Before Width: | Height: | Size: 471 B After Width: | Height: | Size: 471 B |
|
Before Width: | Height: | Size: 930 B After Width: | Height: | Size: 930 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 724 B After Width: | Height: | Size: 724 B |
|
Before Width: | Height: | Size: 458 B After Width: | Height: | Size: 458 B |
|
Before Width: | Height: | Size: 938 B After Width: | Height: | Size: 938 B |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 683 B After Width: | Height: | Size: 683 B |
|
Before Width: | Height: | Size: 512 B After Width: | Height: | Size: 512 B |
|
Before Width: | Height: | Size: 946 B After Width: | Height: | Size: 946 B |
105
include/battle.h
@ -68,23 +68,6 @@
|
||||
|
||||
#define BATTLE_BUFFER_LINK_SIZE 0x1000
|
||||
|
||||
// Special indicator value for shellBellDmg in SpecialStatus
|
||||
#define IGNORE_SHELL_BELL 0xFFFF
|
||||
|
||||
struct ResourceFlags
|
||||
{
|
||||
u32 flags[MAX_BATTLERS_COUNT];
|
||||
};
|
||||
|
||||
#define RESOURCE_FLAG_FLASH_FIRE 0x1
|
||||
#define RESOURCE_FLAG_ROOST 0x2
|
||||
#define RESOURCE_FLAG_UNBURDEN 0x4
|
||||
#define RESOURCE_FLAG_UNUSED 0x8
|
||||
#define RESOURCE_FLAG_UNUSED_2 0x10
|
||||
#define RESOURCE_FLAG_EMERGENCY_EXIT 0x20
|
||||
#define RESOURCE_FLAG_NEUTRALIZING_GAS 0x40
|
||||
#define RESOURCE_FLAG_ICE_FACE 0x80
|
||||
|
||||
struct DisableStruct
|
||||
{
|
||||
u32 transformedMonPersonality;
|
||||
@ -121,6 +104,7 @@ struct DisableStruct
|
||||
u8 laserFocusTimer;
|
||||
u8 throatChopTimer;
|
||||
u8 wrapTurns;
|
||||
u8 syrupBombTimer;
|
||||
u8 tormentTimer:4; // used for G-Max Meltdown
|
||||
u8 usedMoves:4;
|
||||
u8 truantCounter:1;
|
||||
@ -133,14 +117,23 @@ struct DisableStruct
|
||||
u8 toxicSpikesDone:1;
|
||||
u8 stickyWebDone:1;
|
||||
u8 stealthRockDone:1;
|
||||
u8 syrupBombTimer;
|
||||
u8 syrupBombIsShiny:1;
|
||||
u8 steelSurgeDone:1;
|
||||
u8 weatherAbilityDone:1;
|
||||
u8 terrainAbilityDone:1;
|
||||
u8 syrupBombIsShiny:1;
|
||||
u8 steelSurgeDone:1;
|
||||
u8 usedProteanLibero:1;
|
||||
u8 flashFireBoosted:1;
|
||||
u16 overwrittenAbility; // abilities overwritten during battle (keep separate from battle history in case of switching)
|
||||
u8 boosterEnergyActivates:1;
|
||||
u8 roostActive:1;
|
||||
u8 unbrudenActive:1;
|
||||
u8 startEmergencyExit:1;
|
||||
u8 neutralizingGas:1;
|
||||
u8 iceFaceActivationPrevention:1; // fixes hit escape move edge case
|
||||
u8 padding:2;
|
||||
};
|
||||
|
||||
// Fully Cleared each turn after end turn effects are done. A few things are cleared before end turn effects
|
||||
struct ProtectStruct
|
||||
{
|
||||
u32 protected:1;
|
||||
@ -194,12 +187,11 @@ struct ProtectStruct
|
||||
u32 specialDmg;
|
||||
u8 physicalBattlerId;
|
||||
u8 specialBattlerId;
|
||||
|
||||
};
|
||||
|
||||
// Cleared at the start of HandleAction_ActionFinished
|
||||
struct SpecialStatus
|
||||
{
|
||||
s32 shellBellDmg;
|
||||
s32 physicalDmg;
|
||||
s32 specialDmg;
|
||||
u8 physicalBattlerId;
|
||||
@ -211,7 +203,8 @@ struct SpecialStatus
|
||||
u8 faintedHasReplacement:1;
|
||||
u8 focusBanded:1;
|
||||
u8 focusSashed:1;
|
||||
u8 unused:2;
|
||||
u8 emergencyExited:1;
|
||||
u8 afterYou:1;
|
||||
// End of byte
|
||||
u8 sturdied:1;
|
||||
u8 stormDrainRedirected:1;
|
||||
@ -230,16 +223,15 @@ struct SpecialStatus
|
||||
u8 neutralizingGasRemoved:1; // See VARIOUS_TRY_END_NEUTRALIZING_GAS
|
||||
u8 affectionEndured:1;
|
||||
// End of byte
|
||||
u8 damagedMons:4; // Mons that have been damaged directly by using a move, includes substitute.
|
||||
u8 dancerUsedMove:1;
|
||||
u8 dancerOriginalTarget:3;
|
||||
// End of byte
|
||||
u8 emergencyExited:1;
|
||||
u8 afterYou:1;
|
||||
u8 preventLifeOrbDamage:1; // So that Life Orb doesn't activate various effects.
|
||||
u8 distortedTypeMatchups:1;
|
||||
u8 teraShellAbilityDone:1;
|
||||
u8 criticalHit:1;
|
||||
// End of byte
|
||||
u8 enduredDamage:1;
|
||||
u8 padding:7;
|
||||
};
|
||||
|
||||
struct SideTimer
|
||||
@ -365,9 +357,12 @@ struct AiLogicData
|
||||
u8 weatherHasEffect:1; // The same as WEATHER_HAS_EFFECT. Stored here, so it's called only once.
|
||||
u8 ejectButtonSwitch:1; // Tracks whether current switch out was from Eject Button
|
||||
u8 ejectPackSwitch:1; // Tracks whether current switch out was from Eject Pack
|
||||
u8 padding:5;
|
||||
u8 predictingSwitch:1; // Determines whether AI will use predictions this turn or not
|
||||
u8 aiSwitchPredictionInProgress:1; // Tracks whether the AI is in the middle of running prediction calculations
|
||||
u8 padding:3;
|
||||
u8 shouldSwitch; // Stores result of ShouldSwitch, which decides whether a mon should be switched out
|
||||
u8 aiCalcInProgress:1;
|
||||
u8 battlerDoingPrediction; // Stores which battler is currently running its prediction calcs
|
||||
};
|
||||
|
||||
struct AI_ThinkingStruct
|
||||
@ -417,7 +412,6 @@ struct StatsArray
|
||||
struct BattleResources
|
||||
{
|
||||
struct SecretBase* secretBase;
|
||||
struct ResourceFlags *flags;
|
||||
struct BattleScriptsStack* battleScriptsStack;
|
||||
struct BattleCallbacksStack* battleCallbackStack;
|
||||
struct StatsArray* beforeLvlUp;
|
||||
@ -577,7 +571,6 @@ struct DynamaxData
|
||||
u8 dynamaxTurns[MAX_BATTLERS_COUNT];
|
||||
u16 baseMoves[MAX_BATTLERS_COUNT]; // base move of Max Move
|
||||
u16 lastUsedBaseMove;
|
||||
u16 levelUpHP;
|
||||
};
|
||||
|
||||
struct BattleGimmickData
|
||||
@ -626,8 +619,32 @@ enum BattleIntroStates
|
||||
BATTLE_INTRO_STATE_SET_DEX_AND_BATTLE_VARS
|
||||
};
|
||||
|
||||
struct BattlerState
|
||||
{
|
||||
u8 targetsDone[MAX_BATTLERS_COUNT];
|
||||
|
||||
u32 commandingDondozo:1;
|
||||
u32 absentBattlerFlags:1;
|
||||
u32 focusPunchBattlers:1;
|
||||
u32 multipleSwitchInBattlers:1;
|
||||
u32 alreadyStatusedMoveAttempt:1; // For example when using Thunder Wave on an already paralyzed Pokémon.
|
||||
u32 activeAbilityPopUps:1;
|
||||
u32 lastMoveFailed:1; // For Stomping Tantrum
|
||||
u32 forcedSwitch:1;
|
||||
u32 storedHealingWish:1;
|
||||
u32 storedLunarDance:1;
|
||||
u32 usedEjectItem:1;
|
||||
u32 sleepClauseEffectExempt:1; // Stores whether effect should be exempt from triggering Sleep Clause (Effect Spore)
|
||||
u32 usedMicleBerry:1;
|
||||
u32 pursuitTarget:1;
|
||||
u32 padding:17;
|
||||
// End of Word
|
||||
};
|
||||
|
||||
// Cleared at the beginning of the battle. Fields need to be cleared when needed manually otherwise.
|
||||
struct BattleStruct
|
||||
{
|
||||
struct BattlerState battlerState[MAX_BATTLERS_COUNT];
|
||||
u8 turnEffectsTracker;
|
||||
u8 turnEffectsBattlerId;
|
||||
u8 turnCountersTracker;
|
||||
@ -645,7 +662,6 @@ struct BattleStruct
|
||||
u8 wildVictorySong;
|
||||
u8 dynamicMoveType;
|
||||
u8 wrappedBy[MAX_BATTLERS_COUNT];
|
||||
u8 focusPunchBattlers; // as bits
|
||||
u8 battlerPreventingSwitchout;
|
||||
u8 moneyMultiplier:6;
|
||||
u8 moneyMultiplierItem:1;
|
||||
@ -686,9 +702,9 @@ struct BattleStruct
|
||||
u8 hpScale;
|
||||
u16 synchronizeMoveEffect;
|
||||
u8 anyMonHasTransformed:1; // Only used in battle_tv.c
|
||||
u8 multipleSwitchInBattlers:4; // One bit per battler
|
||||
u8 multipleSwitchInState:2;
|
||||
u8 multipleSwitchInCursor:3;
|
||||
u8 padding1:2;
|
||||
u8 multipleSwitchInSortedBattlers[MAX_BATTLERS_COUNT];
|
||||
void (*savedCallback)(void);
|
||||
u16 usedHeldItems[PARTY_SIZE][NUM_BATTLE_SIDES]; // For each party member and side. For harvest, recycle
|
||||
@ -725,7 +741,6 @@ struct BattleStruct
|
||||
u16 arenaStartHp[2];
|
||||
u8 arenaLostPlayerMons; // Bits for party member, lost as in referee's decision, not by fainting.
|
||||
u8 arenaLostOpponentMons;
|
||||
u8 alreadyStatusedMoveAttempt; // As bits for battlers; For example when using Thunder Wave on an already paralyzed Pokémon.
|
||||
u8 debugBattler;
|
||||
u8 magnitudeBasePower;
|
||||
u8 presentBasePower;
|
||||
@ -735,7 +750,6 @@ struct BattleStruct
|
||||
u8 savedTargetCount:4;
|
||||
u8 savedAttackerCount:4;
|
||||
bool8 ateBoost[MAX_BATTLERS_COUNT];
|
||||
u8 activeAbilityPopUps; // as bits for each battler
|
||||
u8 abilityPopUpSpriteIds[MAX_BATTLERS_COUNT][2]; // two per battler
|
||||
struct ZMoveData zmove;
|
||||
struct DynamaxData dynamax;
|
||||
@ -744,7 +758,6 @@ struct BattleStruct
|
||||
enum BattleIntroStates introState:8;
|
||||
u8 ateBerry[2]; // array id determined by side, each party pokemon as bit
|
||||
u8 stolenStats[NUM_BATTLE_STATS]; // hp byte is used for which stats to raise, other inform about by how many stages
|
||||
u8 lastMoveFailed; // as bits for each battler, for the sake of Stomping Tantrum
|
||||
u8 lastMoveTarget[MAX_BATTLERS_COUNT]; // The last target on which each mon used a move, for the sake of Instruct
|
||||
u16 tracedAbility[MAX_BATTLERS_COUNT];
|
||||
u16 hpBefore[MAX_BATTLERS_COUNT]; // Hp of battlers before using a move. For Berserk and Anger Shell.
|
||||
@ -759,8 +772,6 @@ struct BattleStruct
|
||||
u16 changedSpecies[NUM_BATTLE_SIDES][PARTY_SIZE]; // For forms when multiple mons can change into the same pokemon.
|
||||
u8 quickClawBattlerId;
|
||||
struct LostItem itemLost[NUM_BATTLE_SIDES][PARTY_SIZE]; // Pokemon that had items consumed or stolen (two bytes per party member per side)
|
||||
u8 forcedSwitch:4; // For each battler
|
||||
u8 additionalEffectsCounter:4; // A counter for the additionalEffects applied by the current move in Cmd_setadditionaleffects
|
||||
u8 blunderPolicy:1; // should blunder policy activate
|
||||
u8 swapDamageCategory:1; // Photon Geyser, Shell Side Arm, Light That Burns the Sky
|
||||
u8 bouncedMoveIsUsed:1;
|
||||
@ -778,11 +789,7 @@ struct BattleStruct
|
||||
u8 hitSwitchTargetFailed:1;
|
||||
u8 effectsBeforeUsingMoveDone:1; // Mega Evo and Focus Punch/Shell Trap effects.
|
||||
u8 spriteIgnore0Hp:1;
|
||||
u8 targetsDone[MAX_BATTLERS_COUNT]; // Each battler as a bit.
|
||||
u16 overwrittenAbilities[MAX_BATTLERS_COUNT]; // abilities overwritten during battle (keep separate from battle history in case of switching)
|
||||
u8 battleBondTransformed[NUM_BATTLE_SIDES]; // Bitfield for each party.
|
||||
u8 storedHealingWish:4; // Each battler as a bit.
|
||||
u8 storedLunarDance:4; // Each battler as a bit.
|
||||
u8 bonusCritStages[MAX_BATTLERS_COUNT]; // G-Max Chi Strike boosts crit stages of allies.
|
||||
u8 itemPartyIndex[MAX_BATTLERS_COUNT];
|
||||
u8 itemMoveIndex[MAX_BATTLERS_COUNT];
|
||||
@ -801,7 +808,6 @@ struct BattleStruct
|
||||
u32 aiDelayTimer; // Counts number of frames AI takes to choose an action.
|
||||
u32 aiDelayFrames; // Number of frames it took to choose an action.
|
||||
u8 timesGotHit[NUM_BATTLE_SIDES][PARTY_SIZE];
|
||||
u8 enduredDamage;
|
||||
u8 transformZeroToHero[NUM_BATTLE_SIDES];
|
||||
u8 stickySyrupdBy[MAX_BATTLERS_COUNT];
|
||||
u8 intrepidSwordBoost[NUM_BATTLE_SIDES];
|
||||
@ -812,18 +818,13 @@ struct BattleStruct
|
||||
u8 quickDrawRandom[MAX_BATTLERS_COUNT];
|
||||
u8 shellSideArmCategory[MAX_BATTLERS_COUNT][MAX_BATTLERS_COUNT];
|
||||
u8 speedTieBreaks; // MAX_BATTLERS_COUNT! values.
|
||||
u8 boosterEnergyActivates;
|
||||
u8 categoryOverride; // for Z-Moves and Max Moves
|
||||
u8 commandingDondozo;
|
||||
u16 commanderActive[MAX_BATTLERS_COUNT];
|
||||
u32 stellarBoostFlags[NUM_BATTLE_SIDES]; // stored as a bitfield of flags for all types for each side
|
||||
u8 redCardActivates:1;
|
||||
u8 padding1:7;
|
||||
u8 usedEjectItem;
|
||||
u8 monCausingSleepClause[NUM_BATTLE_SIDES]; // Stores which pokemon on a given side is causing Sleep Clause to be active as the mon's index in the party
|
||||
u8 sleepClauseEffectExempt:4; // Stores whether effect should be exempt from triggering Sleep Clause (Effect Spore)
|
||||
u8 usedMicleBerry:4;
|
||||
u8 pursuitTarget:4; // Each battler as a bit.
|
||||
u8 additionalEffectsCounter:4; // A counter for the additionalEffects applied by the current move in Cmd_setadditionaleffects
|
||||
u8 redCardActivates:1;
|
||||
u8 padding2:2; // padding in the middle so pursuit fields are together
|
||||
u8 pursuitSwitchByMove:1;
|
||||
u8 pursuitStoredSwitch; // Stored id for the Pursuit target's switch
|
||||
s32 battlerExpReward;
|
||||
@ -839,7 +840,7 @@ struct BattleStruct
|
||||
u8 calculatedSpreadMoveAccuracy:1;
|
||||
u8 printedStrongWindsWeakenedAttack:1;
|
||||
u8 numSpreadTargets:2;
|
||||
u8 padding2:2;
|
||||
u8 padding3:2;
|
||||
};
|
||||
|
||||
// The palaceFlags member of struct BattleStruct contains 1 flag per move to indicate which moves the AI should consider,
|
||||
@ -1196,7 +1197,7 @@ static inline bool32 IsBattlerTurnDamaged(u32 battler)
|
||||
{
|
||||
return gSpecialStatuses[battler].physicalDmg != 0
|
||||
|| gSpecialStatuses[battler].specialDmg != 0
|
||||
|| gBattleStruct->enduredDamage & (1u << battler);
|
||||
|| gSpecialStatuses[battler].enduredDamage;
|
||||
}
|
||||
|
||||
static inline bool32 IsBattlerAtMaxHp(u32 battler)
|
||||
|
||||
@ -123,7 +123,7 @@ bool32 HasMoveWithMoveEffectExcept(u32 battlerId, u32 moveEffect, u32 exception)
|
||||
bool32 HasMoveThatLowersOwnStats(u32 battlerId);
|
||||
bool32 HasMoveWithLowAccuracy(u32 battlerAtk, u32 battlerDef, u32 accCheck, bool32 ignoreStatus, u32 atkAbility, u32 defAbility, u32 atkHoldEffect, u32 defHoldEffect);
|
||||
bool32 HasAnyKnownMove(u32 battlerId);
|
||||
bool32 IsAromaVeilProtectedMove(u32 move);
|
||||
bool32 IsAromaVeilProtectedEffect(u32 moveEffect);
|
||||
bool32 IsNonVolatileStatusMoveEffect(u32 moveEffect);
|
||||
bool32 IsMoveRedirectionPrevented(u32 move, u32 atkAbility);
|
||||
bool32 IsMoveEncouragedToHit(u32 battlerAtk, u32 battlerDef, u32 move);
|
||||
@ -182,6 +182,7 @@ bool32 PartnerHasSameMoveEffectWithoutTarget(u32 battlerAtkPartner, u32 move, u3
|
||||
bool32 PartnerMoveEffectIsStatusSameTarget(u32 battlerAtkPartner, u32 battlerDef, u32 partnerMove);
|
||||
bool32 IsMoveEffectWeather(u32 move);
|
||||
bool32 PartnerMoveEffectIsTerrain(u32 battlerAtkPartner, u32 partnerMove);
|
||||
bool32 PartnerMoveEffectIs(u32 battlerAtkPartner, u32 partnerMove, u32 effectCheck);
|
||||
bool32 PartnerMoveIs(u32 battlerAtkPartner, u32 partnerMove, u32 moveCheck);
|
||||
bool32 PartnerMoveIsSameAsAttacker(u32 battlerAtkPartner, u32 battlerDef, u32 move, u32 partnerMove);
|
||||
bool32 PartnerMoveIsSameNoTarget(u32 battlerAtkPartner, u32 move, u32 partnerMove);
|
||||
@ -214,5 +215,6 @@ bool32 AI_ShouldSetUpHazards(u32 battlerAtk, u32 battlerDef, struct AiLogicData
|
||||
void IncreaseTidyUpScore(u32 battlerAtk, u32 battlerDef, u32 move, s32 *score);
|
||||
bool32 AI_ShouldSpicyExtract(u32 battlerAtk, u32 battlerAtkPartner, u32 move, struct AiLogicData *aiData);
|
||||
void IncreaseSubstituteMoveScore(u32 battlerAtk, u32 battlerDef, u32 move, s32 *score);
|
||||
bool32 IsBattlerPredictedToSwitch(u32 battler);
|
||||
|
||||
#endif //GUARD_BATTLE_AI_UTIL_H
|
||||
|
||||
@ -168,10 +168,6 @@ enum
|
||||
CONTROLLER_CHOSENMONRETURNVALUE,
|
||||
CONTROLLER_ONERETURNVALUE,
|
||||
CONTROLLER_ONERETURNVALUE_DUPLICATE,
|
||||
CONTROLLER_CLEARUNKVAR,
|
||||
CONTROLLER_SETUNKVAR,
|
||||
CONTROLLER_CLEARUNKFLAG,
|
||||
CONTROLLER_TOGGLEUNKFLAG,
|
||||
CONTROLLER_HITANIMATION,
|
||||
CONTROLLER_CANTSWITCH,
|
||||
CONTROLLER_PLAYSE,
|
||||
@ -210,7 +206,7 @@ void PrepareBufferDataTransferLink(u32 battler, u32 bufferId, u16 size, u8 *data
|
||||
void BtlController_EmitGetMonData(u32 battler, u32 bufferId, u8 requestId, u8 monToCheck);
|
||||
void BtlController_EmitSetMonData(u32 battler, u32 bufferId, u8 requestId, u8 monToCheck, u8 bytes, void *data);
|
||||
void BtlController_EmitLoadMonSprite(u32 battler, u32 bufferId);
|
||||
void BtlController_EmitSwitchInAnim(u32 battler, u32 bufferId, u8 partyId, bool8 dontClearSubstituteBit);
|
||||
void BtlController_EmitSwitchInAnim(u32 battler, u32 bufferId, u8 partyId, bool8 dontClearTransform, bool8 dontClearSubstituteBit);
|
||||
void BtlController_EmitReturnMonToBall(u32 battler, u32 bufferId, bool8 skipAnim);
|
||||
void BtlController_EmitDrawTrainerPic(u32 battler, u32 bufferId);
|
||||
void BtlController_EmitTrainerSlide(u32 battler, u32 bufferId);
|
||||
@ -255,7 +251,7 @@ void BattleControllerComplete(u32 battler); // Can be used for all the controlle
|
||||
void BtlController_Empty(u32 battler); // Empty command, does nothing, only completes the execution.
|
||||
void BtlController_TerminatorNop(u32 battler); // Dummy function at the end of the table.
|
||||
void BattleControllerDummy(u32 battler);
|
||||
void StartSendOutAnim(u32 battler, bool32 dontClearSubstituteBit, bool32 doSlideIn);
|
||||
void StartSendOutAnim(u32 battler, bool32 dontClearTransform, bool32 dontClearSubstituteBit, bool32 doSlideIn);
|
||||
void Controller_WaitForString(u32 battler);
|
||||
void Controller_WaitForHealthBar(u32 battler);
|
||||
|
||||
|
||||
@ -58,7 +58,7 @@ enum MaxMoveEffect
|
||||
|
||||
bool32 CanDynamax(u32 battler);
|
||||
bool32 IsGigantamaxed(u32 battler);
|
||||
void ApplyDynamaxHPMultiplier(u32 battler, struct Pokemon* mon);
|
||||
void ApplyDynamaxHPMultiplier(struct Pokemon* mon);
|
||||
void ActivateDynamax(u32 battler);
|
||||
u16 GetNonDynamaxHP(u32 battler);
|
||||
u16 GetNonDynamaxMaxHP(u32 battler);
|
||||
|
||||
@ -38,7 +38,7 @@ void SpriteCB_SetInvisible(struct Sprite *sprite);
|
||||
void SetBattlerShadowSpriteCallback(u8 battler, u16 species);
|
||||
void HideBattlerShadowSprite(u8 battler);
|
||||
void FillAroundBattleWindows(void);
|
||||
void ClearTemporarySpeciesSpriteData(u8 battler, bool8 dontClearSubstitute);
|
||||
void ClearTemporarySpeciesSpriteData(u32 battler, bool32 dontClearTransform, bool32 dontClearSubstitute);
|
||||
void AllocateMonSpritesGfx(void);
|
||||
void FreeMonSpritesGfx(void);
|
||||
bool32 ShouldPlayNormalMonCry(struct Pokemon *mon);
|
||||
|
||||
@ -50,17 +50,12 @@ extern const u8 BattleScript_DoSwitchOut[];
|
||||
extern const u8 BattleScript_MoveSwitchOpenPartyScreen[];
|
||||
extern const u8 BattleScript_Pausex20[];
|
||||
extern const u8 BattleScript_LevelUp[];
|
||||
extern const u8 BattleScript_RainContinuesOrEnds[];
|
||||
extern const u8 BattleScript_SnowContinuesOrEnds[];
|
||||
extern const u8 BattleScript_WeatherContinues[];
|
||||
extern const u8 BattleScript_WeatherFaded[];
|
||||
extern const u8 BattleScript_DamagingWeatherContinues[];
|
||||
extern const u8 BattleScript_DamagingWeather[];
|
||||
extern const u8 BattleScript_IceBodyHeal[];
|
||||
extern const u8 BattleScript_SandStormHailSnowEnds[];
|
||||
extern const u8 BattleScript_SunlightContinues[];
|
||||
extern const u8 BattleScript_SunlightFaded[];
|
||||
extern const u8 BattleScript_FogContinues[];
|
||||
extern const u8 BattleScript_FogEnded_Ret[];
|
||||
extern const u8 BattleScript_FogEnded[];
|
||||
extern const u8 BattleScript_IceBodyHeal[];
|
||||
extern const u8 BattleScript_OverworldStatusStarts[];
|
||||
extern const u8 BattleScript_OverworldWeatherStarts[];
|
||||
extern const u8 BattleScript_OverworldTerrain[];
|
||||
|
||||
@ -206,7 +206,7 @@ void TryClearRageAndFuryCutter(void);
|
||||
u32 AtkCanceller_MoveSuccessOrder(void);
|
||||
void SetAtkCancellerForCalledMove(void);
|
||||
bool32 HasNoMonsToSwitch(u32 battler, u8 r1, u8 r2);
|
||||
bool32 TryChangeBattleWeather(u32 battler, u32 weatherEnumId, bool32 viaAbility);
|
||||
bool32 TryChangeBattleWeather(u32 battler, u32 battleWeatherId, bool32 viaAbility);
|
||||
u32 CanAbilityBlockMove(u32 battlerAtk, u32 battlerDef, u32 move, u32 abilityDef);
|
||||
u32 CanPartnerAbilityBlockMove(u32 battlerAtk, u32 battlerDef, u32 move, u32 abilityDef);
|
||||
u32 CanAbilityAbsorbMove(u32 battlerAtk, u32 battlerDef, u32 abilityDef, u32 move, u32 moveType);
|
||||
@ -248,8 +248,9 @@ uq4_12_t CalcTypeEffectivenessMultiplier(u32 move, u32 moveType, u32 battlerAtk,
|
||||
uq4_12_t CalcPartyMonTypeEffectivenessMultiplier(u16 move, u16 speciesDef, u16 abilityDef);
|
||||
uq4_12_t GetTypeModifier(u32 atkType, u32 defType);
|
||||
uq4_12_t GetOverworldTypeEffectiveness(struct Pokemon *mon, u8 moveType);
|
||||
s32 GetStealthHazardDamage(u8 hazardType, u32 battler);
|
||||
s32 GetStealthHazardDamageByTypesAndHP(u8 hazardType, u8 type1, u8 type2, u32 maxHp);
|
||||
void UpdateMoveResultFlags(uq4_12_t modifier, u16 *resultFlags);
|
||||
s32 GetStealthHazardDamage(enum TypeSideHazard hazardType, u32 battler);
|
||||
s32 GetStealthHazardDamageByTypesAndHP(enum TypeSideHazard hazardType, u8 type1, u8 type2, u32 maxHp);
|
||||
bool32 CanMegaEvolve(u32 battler);
|
||||
bool32 CanUltraBurst(u32 battler);
|
||||
void ActivateMegaEvolution(u32 battler);
|
||||
@ -296,7 +297,7 @@ u32 GetBattlerMoveTargetType(u32 battler, u32 move);
|
||||
bool32 CanTargetBattler(u32 battlerAtk, u32 battlerDef, u16 move);
|
||||
void CopyMonLevelAndBaseStatsToBattleMon(u32 battler, struct Pokemon *mon);
|
||||
void CopyMonAbilityAndTypesToBattleMon(u32 battler, struct Pokemon *mon);
|
||||
void RecalcBattlerStats(u32 battler, struct Pokemon *mon);
|
||||
void RecalcBattlerStats(u32 battler, struct Pokemon *mon, bool32 isDynamaxing);
|
||||
bool32 IsAlly(u32 battlerAtk, u32 battlerDef);
|
||||
bool32 IsGen6ExpShareEnabled(void);
|
||||
bool32 MoveHasAdditionalEffect(u32 move, u32 moveEffect);
|
||||
@ -338,5 +339,9 @@ bool32 IsSleepClauseEnabled();
|
||||
void ClearDamageCalcResults(void);
|
||||
u32 DoesDestinyBondFail(u32 battler);
|
||||
bool32 IsMoveEffectBlockedByTarget(u32 ability);
|
||||
u32 NumAffectedSpreadMoveTargets(void);
|
||||
bool32 IsPursuitTargetSet(void);
|
||||
void ClearPursuitValuesIfSet(u32 battler);
|
||||
void ClearPursuitValues(void);
|
||||
|
||||
#endif // GUARD_BATTLE_UTIL_H
|
||||
|
||||
@ -144,6 +144,7 @@
|
||||
#define B_SYMBIOSIS_GEMS GEN_LATEST // In Gen7+, Symbiosis passes an item after a gem-boosted attack. Previously, items are passed before the gem-boosted attack hits, making the item effect apply.
|
||||
#define B_ABSORBING_ABILITY_STRING GEN_LATEST // In Gen5+, the abilities that absorb moves of a certain type use a generic string for stat increases and decreases.
|
||||
#define B_REDIRECT_ABILITY_IMMUNITY GEN_LATEST // In Gen5+, Pokémon with Lightning Rod/Storm Drain become immune to Electric/Water-type moves and increase their Sp. Attack by 1 stage on top of the redirecting effect.
|
||||
#define B_REDIRECT_ABILITY_ALLIES GEN_LATEST // In Gen4+, Lightning Rod/Storm Drain redirect ally's moves as well.
|
||||
#define B_LEAF_GUARD_PREVENTS_REST GEN_LATEST // In Gen5+, Leaf Guard prevents the use of Rest in harsh sunlight.
|
||||
#define B_SNOW_WARNING GEN_LATEST // In Gen9+, Snow Warning will summon snow instead of hail.
|
||||
#define B_TRANSISTOR_BOOST GEN_LATEST // In Gen9+, Transistor will only boost Electric-type moves by 1.3x as opposed to 1.5x.
|
||||
@ -206,6 +207,7 @@
|
||||
#define B_VAR_STARTING_STATUS 0 // If this var has a value, assigning a STATUS_FIELD_xx_TERRAIN to it before battle causes the battle to start with that terrain active.
|
||||
#define B_VAR_STARTING_STATUS_TIMER 0 // If this var has a value greater or equal than 1 field terrains will last that number of turns, otherwise they will last until they're overwritten.
|
||||
#define B_VAR_WILD_AI_FLAGS 0 // If not 0, you can use this var to add to default wild AI flags. NOT usable with flags above (1 << 15)
|
||||
#define B_VAR_DIFFICULTY 0 // If not 0, you can use this var to control which difficulty version of a Trainer is loaded. This should be manually set by the developer using Script_SetDifficulty AFTER NewGameInitData has run.
|
||||
|
||||
// Sky Battles
|
||||
#define B_FLAG_SKY_BATTLE 0 // If this flag has a value, the player will be able to engage in scripted Sky Battles.
|
||||
|
||||