Merge branch 'followers' into lighting
This commit is contained in:
commit
a4e032c28d
4
.github/pull_request_template.md
vendored
4
.github/pull_request_template.md
vendored
@ -4,5 +4,5 @@
|
||||
<!--- Describe your changes in detail -->
|
||||
|
||||
## **Discord contact info**
|
||||
<!--- formatted as name#numbers, e.g. PikalaxALT#5823 -->
|
||||
<!--- Contributors must join https://discord.gg/d5dubZ3 -->
|
||||
<!--- Formatted as username (e.g. pikalaxalt) or username#numbers (e.g. PikalaxALT#5823) -->
|
||||
<!--- Contributors must join https://discord.gg/d5dubZ3 -->
|
||||
|
||||
28
.github/workflows/build.yml
vendored
28
.github/workflows/build.yml
vendored
@ -10,10 +10,30 @@ jobs:
|
||||
name: Build ROM
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Install dependencies
|
||||
run: sudo apt-get install binutils-arm-none-eabi gcc-arm-none-eabi
|
||||
- name: Build & install agbcc
|
||||
- name: Checkout
|
||||
uses: actions/checkout@master
|
||||
|
||||
- name: Checkout syms
|
||||
if: ${{ github.event_name == 'push' }}
|
||||
uses: actions/checkout@master
|
||||
with:
|
||||
path: symbols
|
||||
ref: symbols
|
||||
|
||||
- name: Checkout agbcc
|
||||
uses: actions/checkout@master
|
||||
with:
|
||||
path: agbcc
|
||||
repository: pret/agbcc
|
||||
|
||||
- name: Install binutils
|
||||
run: |
|
||||
sudo apt install gcc-arm-none-eabi binutils-arm-none-eabi libpng-dev
|
||||
# build-essential and git are already installed
|
||||
# gcc-arm-none-eabi is only needed for the modern build
|
||||
# as an alternative to dkP
|
||||
|
||||
- name: Install agbcc
|
||||
run: |
|
||||
cd ..
|
||||
git clone --depth 1 https://github.com/pret/agbcc
|
||||
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@ -44,3 +44,5 @@ prefabs.json
|
||||
*.js
|
||||
agbcc/
|
||||
/*.zip
|
||||
/pokeemerald-*.png
|
||||
/pokeemerald_modern-*.png
|
||||
|
||||
31
INSTALL.md
31
INSTALL.md
@ -24,7 +24,7 @@ Unscientific benchmarks suggest **msys2 is 2x slower** than WSL1, and **Cygwin i
|
||||
|
||||
All of the Windows instructions assume that the default drive is C:\\. If this differs to your actual drive letter, then replace C with the correct drive letter when reading the instructions.
|
||||
|
||||
**A note of caution**: As Windows 7 is officially unsupported by Microsoft and Windows 8 has very little usage, some maintainers are unwilling to maintain the Windows 7/8 instructions. Thus, these instructions may break in the future with fixes taking longer than fixes to the Windows 10 instructions.
|
||||
**A note of caution**: As Windows 7 and Windows 8 are officially unsupported by Microsoft, some maintainers are unwilling to maintain the Windows 7/8 instructions. Thus, these instructions may break in the future with fixes taking longer than fixes to the Windows 10/11 instructions.
|
||||
|
||||
## Windows 10/11 (WSL1)
|
||||
WSL1 is the preferred terminal to build **pokeemerald**. The following instructions will explain how to install WSL1 (referred to interchangeably as WSL).
|
||||
@ -33,27 +33,23 @@ WSL1 is the preferred terminal to build **pokeemerald**. The following instructi
|
||||
- Otherwise, **open WSL** and go to [Choosing where to store pokeemerald (WSL1)](#Choosing-where-to-store-pokeemerald-WSL1).
|
||||
|
||||
### Installing WSL1
|
||||
1. Open [Windows Powershell **as Administrator**](https://i.imgur.com/QKmVbP9.png), and run the following command (Right Click or Shift+Insert is paste in the Powershell).
|
||||
1. Open [Windows Powershell **as Administrator**](https://i.imgur.com/QKmVbP9.png), and run the following commands (Right Click or Shift+Insert is paste in the Powershell).
|
||||
|
||||
```powershell
|
||||
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
|
||||
wsl --install -d Ubuntu --enable-wsl1
|
||||
```
|
||||
|
||||
2. Once the process finishes, restart your machine.
|
||||
|
||||
3. The next step is to choose and install a Linux distribution from the Microsoft Store. The following instructions will assume Ubuntu as the Linux distribution of choice.
|
||||
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
|
||||
```
|
||||
<details>
|
||||
<summary><i>Note for advanced users...</i></summary>
|
||||
<summary><i>Note...</i></summary>
|
||||
|
||||
> You can pick a preferred Linux distribution, but setup instructions may differ. Debian should work with the given instructions, but has not been tested.
|
||||
</details>
|
||||
|
||||
4. Open the [Microsoft Store Linux Selection](https://aka.ms/wslstore), click Ubuntu, then click Get, which will install the Ubuntu distribution.
|
||||
<details>
|
||||
<summary><i>Notes...</i></summary>
|
||||
|
||||
> Note 1: If a dialog pops up asking for you to sign into a Microsoft Account, then just close the dialog.
|
||||
> Note 2: If the link does not work, then open the Microsoft Store manually, and search for the Ubuntu app (choose the one with no version number).
|
||||
> WSL may open automatically after restarting, but you can ignore it for now.
|
||||
</details>
|
||||
|
||||
### Setting up WSL1
|
||||
@ -354,6 +350,13 @@ Then proceed to [Choosing where to store pokeemerald (Linux)](#choosing-where-to
|
||||
> [install devkitARM on Arch Linux](#installing-devkitarm-on-arch-linux).
|
||||
</details>
|
||||
|
||||
### NixOS
|
||||
Run the following command to start an interactive shell with the necessary packages:
|
||||
```bash
|
||||
nix-shell -p pkgsCross.arm-embedded.stdenv.cc git pkg-config libpng
|
||||
```
|
||||
Then proceed to [Choosing where to store pokeemerald (Linux)](#choosing-where-to-store-pokeemerald-linux).
|
||||
|
||||
### Other distributions
|
||||
_(Specific instructions for other distributions would be greatly appreciated!)_
|
||||
|
||||
|
||||
438
Makefile
438
Makefile
@ -1,49 +1,53 @@
|
||||
TOOLCHAIN := $(DEVKITARM)
|
||||
COMPARE ?= 0
|
||||
# GBA rom header
|
||||
TITLE := POKEMON EMER
|
||||
GAME_CODE := BPEE
|
||||
MAKER_CODE := 01
|
||||
REVISION := 0
|
||||
MODERN ?= 0
|
||||
KEEP_TEMPS ?= 0
|
||||
|
||||
# `File name`.gba ('_modern' will be appended to the modern builds)
|
||||
FILE_NAME := pokeemerald
|
||||
BUILD_DIR := build
|
||||
|
||||
# Builds the ROM using a modern compiler
|
||||
MODERN ?= 0
|
||||
# Compares the ROM to a checksum of the original - only makes sense using when non-modern
|
||||
COMPARE ?= 0
|
||||
|
||||
ifeq (modern,$(MAKECMDGOALS))
|
||||
MODERN := 1
|
||||
endif
|
||||
ifeq (compare,$(MAKECMDGOALS))
|
||||
COMPARE := 1
|
||||
endif
|
||||
|
||||
# Default make rule
|
||||
all: rom
|
||||
|
||||
# Toolchain selection
|
||||
TOOLCHAIN := $(DEVKITARM)
|
||||
# don't use dkP's base_tools anymore
|
||||
# because the redefinition of $(CC) conflicts
|
||||
# with when we want to use $(CC) to preprocess files
|
||||
# thus, manually create the variables for the bin
|
||||
# files, or use arm-none-eabi binaries on the system
|
||||
# if dkP is not installed on this system
|
||||
|
||||
ifneq (,$(TOOLCHAIN))
|
||||
ifneq ($(wildcard $(TOOLCHAIN)/bin),)
|
||||
export PATH := $(TOOLCHAIN)/bin:$(PATH)
|
||||
endif
|
||||
ifneq ($(wildcard $(TOOLCHAIN)/bin),)
|
||||
export PATH := $(TOOLCHAIN)/bin:$(PATH)
|
||||
endif
|
||||
endif
|
||||
|
||||
PREFIX := arm-none-eabi-
|
||||
OBJCOPY := $(PREFIX)objcopy
|
||||
OBJDUMP := $(PREFIX)objdump
|
||||
AS := $(PREFIX)as
|
||||
|
||||
LD := $(PREFIX)ld
|
||||
|
||||
# note: the makefile must be set up so MODERNCC is never called
|
||||
# if MODERN=0
|
||||
MODERNCC := $(PREFIX)gcc
|
||||
PATH_MODERNCC := PATH="$(PATH)" $(MODERNCC)
|
||||
|
||||
ifeq ($(OS),Windows_NT)
|
||||
EXE := .exe
|
||||
else
|
||||
EXE :=
|
||||
endif
|
||||
|
||||
TITLE := POKEMON EMER
|
||||
GAME_CODE := BPEE
|
||||
MAKER_CODE := 01
|
||||
REVISION := 0
|
||||
MODERN ?= 0
|
||||
|
||||
ifeq (modern,$(MAKECMDGOALS))
|
||||
MODERN := 1
|
||||
ifeq ($(OS),Windows_NT)
|
||||
EXE := .exe
|
||||
endif
|
||||
|
||||
# use arm-none-eabi-cpp for macOS
|
||||
@ -63,79 +67,89 @@ else
|
||||
CPP := $(PREFIX)cpp
|
||||
endif
|
||||
|
||||
ROM_NAME := pokeemerald.gba
|
||||
ROM_NAME := $(FILE_NAME).gba
|
||||
OBJ_DIR_NAME := $(BUILD_DIR)/emerald
|
||||
MODERN_ROM_NAME := $(FILE_NAME)_modern.gba
|
||||
MODERN_OBJ_DIR_NAME := $(BUILD_DIR)/modern
|
||||
|
||||
ELF_NAME := $(ROM_NAME:.gba=.elf)
|
||||
MAP_NAME := $(ROM_NAME:.gba=.map)
|
||||
OBJ_DIR_NAME := build/emerald
|
||||
|
||||
MODERN_ROM_NAME := pokeemerald_modern.gba
|
||||
MODERN_ELF_NAME := $(MODERN_ROM_NAME:.gba=.elf)
|
||||
MODERN_MAP_NAME := $(MODERN_ROM_NAME:.gba=.map)
|
||||
MODERN_OBJ_DIR_NAME := build/modern
|
||||
|
||||
SHELL := /bin/bash -o pipefail
|
||||
|
||||
ELF = $(ROM:.gba=.elf)
|
||||
MAP = $(ROM:.gba=.map)
|
||||
SYM = $(ROM:.gba=.sym)
|
||||
# Pick our active variables
|
||||
ifeq ($(MODERN),0)
|
||||
ROM := $(ROM_NAME)
|
||||
OBJ_DIR := $(OBJ_DIR_NAME)
|
||||
else
|
||||
ROM := $(MODERN_ROM_NAME)
|
||||
OBJ_DIR := $(MODERN_OBJ_DIR_NAME)
|
||||
endif
|
||||
ELF := $(ROM:.gba=.elf)
|
||||
MAP := $(ROM:.gba=.map)
|
||||
SYM := $(ROM:.gba=.sym)
|
||||
|
||||
# Commonly used directories
|
||||
C_SUBDIR = src
|
||||
GFLIB_SUBDIR = gflib
|
||||
ASM_SUBDIR = asm
|
||||
DATA_SRC_SUBDIR = src/data
|
||||
DATA_ASM_SUBDIR = data
|
||||
SONG_SUBDIR = sound/songs
|
||||
MID_SUBDIR = sound/songs/midi
|
||||
SAMPLE_SUBDIR = sound/direct_sound_samples
|
||||
CRY_SUBDIR = sound/direct_sound_samples/cries
|
||||
|
||||
C_BUILDDIR = $(OBJ_DIR)/$(C_SUBDIR)
|
||||
GFLIB_BUILDDIR = $(OBJ_DIR)/$(GFLIB_SUBDIR)
|
||||
ASM_BUILDDIR = $(OBJ_DIR)/$(ASM_SUBDIR)
|
||||
DATA_ASM_BUILDDIR = $(OBJ_DIR)/$(DATA_ASM_SUBDIR)
|
||||
SONG_BUILDDIR = $(OBJ_DIR)/$(SONG_SUBDIR)
|
||||
MID_BUILDDIR = $(OBJ_DIR)/$(MID_SUBDIR)
|
||||
|
||||
SHELL := bash -o pipefail
|
||||
|
||||
# Set flags for tools
|
||||
ASFLAGS := -mcpu=arm7tdmi --defsym MODERN=$(MODERN)
|
||||
|
||||
INCLUDE_DIRS := include
|
||||
INCLUDE_CPP_ARGS := $(INCLUDE_DIRS:%=-iquote %)
|
||||
INCLUDE_SCANINC_ARGS := $(INCLUDE_DIRS:%=-I %)
|
||||
|
||||
O_LEVEL ?= 2
|
||||
CPPFLAGS := $(INCLUDE_CPP_ARGS) -Wno-trigraphs -DMODERN=$(MODERN)
|
||||
ifeq ($(MODERN),0)
|
||||
CC1 := tools/agbcc/bin/agbcc$(EXE)
|
||||
override CFLAGS += -mthumb-interwork -Wimplicit -Wparentheses -Werror -O2 -fhex-asm -g
|
||||
ROM := $(ROM_NAME)
|
||||
OBJ_DIR := $(OBJ_DIR_NAME)
|
||||
LIBPATH := -L ../../tools/agbcc/lib
|
||||
LIB := $(LIBPATH) -lgcc -lc -L../../libagbsyscall -lagbsyscall
|
||||
CPPFLAGS += -I tools/agbcc/include -I tools/agbcc -nostdinc -undef
|
||||
CC1 := tools/agbcc/bin/agbcc$(EXE)
|
||||
override CFLAGS += -mthumb-interwork -Wimplicit -Wparentheses -Werror -O$(O_LEVEL) -fhex-asm -g
|
||||
LIBPATH := -L ../../tools/agbcc/lib
|
||||
LIB := $(LIBPATH) -lgcc -lc -L../../libagbsyscall -lagbsyscall
|
||||
else
|
||||
CC1 = $(shell $(PATH_MODERNCC) --print-prog-name=cc1) -quiet
|
||||
override CFLAGS += -mthumb -mthumb-interwork -O2 -mabi=apcs-gnu -mtune=arm7tdmi -march=armv4t -fno-toplevel-reorder -Wno-pointer-to-int-cast
|
||||
ROM := $(MODERN_ROM_NAME)
|
||||
OBJ_DIR := $(MODERN_OBJ_DIR_NAME)
|
||||
LIBPATH := -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libgcc.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libnosys.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libc.a))"
|
||||
LIB := $(LIBPATH) -lc -lnosys -lgcc -L../../libagbsyscall -lagbsyscall
|
||||
# Note: The makefile must be set up to not call these if modern == 0
|
||||
MODERNCC := $(PREFIX)gcc
|
||||
PATH_MODERNCC := PATH="$(PATH)" $(MODERNCC)
|
||||
CC1 := $(shell $(PATH_MODERNCC) --print-prog-name=cc1) -quiet
|
||||
override CFLAGS += -mthumb -mthumb-interwork -O$(O_LEVEL) -mabi=apcs-gnu -mtune=arm7tdmi -march=armv4t -fno-toplevel-reorder -Wno-pointer-to-int-cast
|
||||
LIBPATH := -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libgcc.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libnosys.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libc.a))"
|
||||
LIB := $(LIBPATH) -lc -lnosys -lgcc -L../../libagbsyscall -lagbsyscall
|
||||
endif
|
||||
# Enable debug info if set
|
||||
ifeq ($(DINFO),1)
|
||||
override CFLAGS += -g
|
||||
endif
|
||||
|
||||
CPPFLAGS := -iquote include -iquote $(GFLIB_SUBDIR) -Wno-trigraphs -DMODERN=$(MODERN)
|
||||
ifneq ($(MODERN),1)
|
||||
CPPFLAGS += -I tools/agbcc/include -I tools/agbcc -nostdinc -undef
|
||||
endif
|
||||
|
||||
SHA1 := $(shell { command -v sha1sum || command -v shasum; } 2>/dev/null) -c
|
||||
GFX := tools/gbagfx/gbagfx$(EXE)
|
||||
AIF := tools/aif2pcm/aif2pcm$(EXE)
|
||||
MID := tools/mid2agb/mid2agb$(EXE)
|
||||
SCANINC := tools/scaninc/scaninc$(EXE)
|
||||
PREPROC := tools/preproc/preproc$(EXE)
|
||||
RAMSCRGEN := tools/ramscrgen/ramscrgen$(EXE)
|
||||
FIX := tools/gbafix/gbafix$(EXE)
|
||||
MAPJSON := tools/mapjson/mapjson$(EXE)
|
||||
JSONPROC := tools/jsonproc/jsonproc$(EXE)
|
||||
# Variable filled out in other make files
|
||||
AUTO_GEN_TARGETS :=
|
||||
include make_tools.mk
|
||||
# Tool executables
|
||||
GFX := $(TOOLS_DIR)/gbagfx/gbagfx$(EXE)
|
||||
AIF := $(TOOLS_DIR)/aif2pcm/aif2pcm$(EXE)
|
||||
MID := $(TOOLS_DIR)/mid2agb/mid2agb$(EXE)
|
||||
SCANINC := $(TOOLS_DIR)/scaninc/scaninc$(EXE)
|
||||
PREPROC := $(TOOLS_DIR)/preproc/preproc$(EXE)
|
||||
RAMSCRGEN := $(TOOLS_DIR)/ramscrgen/ramscrgen$(EXE)
|
||||
FIX := $(TOOLS_DIR)/gbafix/gbafix$(EXE)
|
||||
MAPJSON := $(TOOLS_DIR)/mapjson/mapjson$(EXE)
|
||||
JSONPROC := $(TOOLS_DIR)/jsonproc/jsonproc$(EXE)
|
||||
|
||||
PERL := perl
|
||||
|
||||
# Inclusive list. If you don't want a tool to be built, don't add it here.
|
||||
TOOLDIRS := tools/aif2pcm tools/bin2c tools/gbafix tools/gbagfx tools/jsonproc tools/mapjson tools/mid2agb tools/preproc tools/ramscrgen tools/rsfont tools/scaninc
|
||||
TOOLBASE = $(TOOLDIRS:tools/%=%)
|
||||
TOOLS = $(foreach tool,$(TOOLBASE),tools/$(tool)/$(tool)$(EXE))
|
||||
SHA1 := $(shell { command -v sha1sum || command -v shasum; } 2>/dev/null) -c
|
||||
|
||||
MAKEFLAGS += --no-print-directory
|
||||
|
||||
@ -146,45 +160,46 @@ MAKEFLAGS += --no-print-directory
|
||||
# Delete files that weren't built properly
|
||||
.DELETE_ON_ERROR:
|
||||
|
||||
# Secondary expansion is required for dependency variables in object rules.
|
||||
.SECONDEXPANSION:
|
||||
|
||||
.PHONY: all rom clean compare tidy tools mostlyclean clean-tools $(TOOLDIRS) libagbsyscall modern tidymodern tidynonmodern
|
||||
RULES_NO_SCAN += libagbsyscall clean clean-assets tidy tidymodern tidynonmodern generated clean-generated
|
||||
.PHONY: all rom modern compare
|
||||
.PHONY: $(RULES_NO_SCAN)
|
||||
|
||||
infoshell = $(foreach line, $(shell $1 | sed "s/ /__SPACE__/g"), $(info $(subst __SPACE__, ,$(line))))
|
||||
|
||||
# Build tools when building the rom
|
||||
# Disable dependency scanning for clean/tidy/tools
|
||||
# Use a separate minimal makefile for speed
|
||||
# Since we don't need to reload most of this makefile
|
||||
ifeq (,$(filter-out all rom compare modern libagbsyscall syms,$(MAKECMDGOALS)))
|
||||
$(call infoshell, $(MAKE) -f make_tools.mk)
|
||||
else
|
||||
NODEP ?= 1
|
||||
endif
|
||||
|
||||
# check if we need to scan dependencies based on the rule
|
||||
ifeq (,$(MAKECMDGOALS))
|
||||
SCAN_DEPS ?= 1
|
||||
else
|
||||
# clean, tidy, tools, mostlyclean, clean-tools, $(TOOLDIRS), tidymodern, tidynonmodern don't even build the ROM
|
||||
# libagbsyscall does its own thing
|
||||
ifeq (,$(filter-out clean tidy tools mostlyclean clean-tools $(TOOLDIRS) tidymodern tidynonmodern libagbsyscall,$(MAKECMDGOALS)))
|
||||
SCAN_DEPS ?= 0
|
||||
else
|
||||
SCAN_DEPS ?= 1
|
||||
# Check if we need to scan dependencies based on the chosen rule OR user preference
|
||||
NODEP ?= 0
|
||||
# Check if we need to pre-build tools and generate assets based on the chosen rule.
|
||||
SETUP_PREREQS ?= 1
|
||||
# Disable dependency scanning for rules that don't need it.
|
||||
ifneq (,$(MAKECMDGOALS))
|
||||
ifeq (,$(filter-out $(RULES_NO_SCAN),$(MAKECMDGOALS)))
|
||||
NODEP := 1
|
||||
SETUP_PREREQS := 0
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(SCAN_DEPS),1)
|
||||
.SHELLSTATUS ?= 0
|
||||
|
||||
ifeq ($(SETUP_PREREQS),1)
|
||||
# If set on: Default target or a rule requiring a scan
|
||||
# Forcibly execute `make tools` since we need them for what we are doing.
|
||||
$(foreach line, $(shell $(MAKE) -f make_tools.mk | sed "s/ /__SPACE__/g"), $(info $(subst __SPACE__, ,$(line))))
|
||||
ifneq ($(.SHELLSTATUS),0)
|
||||
$(error Errors occurred while building tools. See error messages above for more details)
|
||||
endif
|
||||
# Oh and also generate mapjson sources before we use `SCANINC`.
|
||||
$(foreach line, $(shell $(MAKE) generated | sed "s/ /__SPACE__/g"), $(info $(subst __SPACE__, ,$(line))))
|
||||
ifneq ($(.SHELLSTATUS),0)
|
||||
$(error Errors occurred while generating map-related sources. See error messages above for more details)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Collect sources
|
||||
C_SRCS_IN := $(wildcard $(C_SUBDIR)/*.c $(C_SUBDIR)/*/*.c $(C_SUBDIR)/*/*/*.c)
|
||||
C_SRCS := $(foreach src,$(C_SRCS_IN),$(if $(findstring .inc.c,$(src)),,$(src)))
|
||||
C_OBJS := $(patsubst $(C_SUBDIR)/%.c,$(C_BUILDDIR)/%.o,$(C_SRCS))
|
||||
|
||||
GFLIB_SRCS := $(wildcard $(GFLIB_SUBDIR)/*.c)
|
||||
GFLIB_OBJS := $(patsubst $(GFLIB_SUBDIR)/%.c,$(GFLIB_BUILDDIR)/%.o,$(GFLIB_SRCS))
|
||||
|
||||
C_ASM_SRCS += $(wildcard $(C_SUBDIR)/*.s $(C_SUBDIR)/*/*.s $(C_SUBDIR)/*/*/*.s)
|
||||
C_ASM_SRCS := $(wildcard $(C_SUBDIR)/*.s $(C_SUBDIR)/*/*.s $(C_SUBDIR)/*/*/*.s)
|
||||
C_ASM_OBJS := $(patsubst $(C_SUBDIR)/%.s,$(C_BUILDDIR)/%.o,$(C_ASM_SRCS))
|
||||
|
||||
ASM_SRCS := $(wildcard $(ASM_SUBDIR)/*.s)
|
||||
@ -202,46 +217,34 @@ SONG_OBJS := $(patsubst $(SONG_SUBDIR)/%.s,$(SONG_BUILDDIR)/%.o,$(SONG_SRCS))
|
||||
MID_SRCS := $(wildcard $(MID_SUBDIR)/*.mid)
|
||||
MID_OBJS := $(patsubst $(MID_SUBDIR)/%.mid,$(MID_BUILDDIR)/%.o,$(MID_SRCS))
|
||||
|
||||
OBJS := $(C_OBJS) $(GFLIB_OBJS) $(C_ASM_OBJS) $(ASM_OBJS) $(DATA_ASM_OBJS) $(SONG_OBJS) $(MID_OBJS)
|
||||
OBJS := $(C_OBJS) $(C_ASM_OBJS) $(ASM_OBJS) $(DATA_ASM_OBJS) $(SONG_OBJS) $(MID_OBJS)
|
||||
OBJS_REL := $(patsubst $(OBJ_DIR)/%,%,$(OBJS))
|
||||
|
||||
SUBDIRS := $(sort $(dir $(OBJS)))
|
||||
$(shell mkdir -p $(SUBDIRS))
|
||||
endif
|
||||
|
||||
AUTO_GEN_TARGETS :=
|
||||
|
||||
all: rom
|
||||
|
||||
tools: $(TOOLDIRS)
|
||||
|
||||
syms: $(SYM)
|
||||
|
||||
$(TOOLDIRS):
|
||||
@$(MAKE) -C $@
|
||||
# Pretend rules that are actually flags defer to `make all`
|
||||
modern: all
|
||||
compare: all
|
||||
|
||||
# Other rules
|
||||
rom: $(ROM)
|
||||
ifeq ($(COMPARE),1)
|
||||
@$(SHA1) rom.sha1
|
||||
endif
|
||||
|
||||
# For contributors to make sure a change didn't affect the contents of the ROM.
|
||||
compare: all
|
||||
syms: $(SYM)
|
||||
|
||||
clean: mostlyclean clean-tools
|
||||
clean: tidy clean-tools clean-generated clean-assets
|
||||
@$(MAKE) clean -C libagbsyscall
|
||||
|
||||
clean-tools:
|
||||
@$(foreach tooldir,$(TOOLDIRS),$(MAKE) clean -C $(tooldir);)
|
||||
|
||||
mostlyclean: tidynonmodern tidymodern
|
||||
find sound -iname '*.bin' -exec rm {} +
|
||||
clean-assets:
|
||||
rm -f $(MID_SUBDIR)/*.s
|
||||
find . \( -iname '*.1bpp' -o -iname '*.4bpp' -o -iname '*.8bpp' -o -iname '*.gbapal' -o -iname '*.lz' -o -iname '*.rl' -o -iname '*.latfont' -o -iname '*.hwjpnfont' -o -iname '*.fwjpnfont' \) -exec rm {} +
|
||||
rm -f $(DATA_ASM_SUBDIR)/layouts/layouts.inc $(DATA_ASM_SUBDIR)/layouts/layouts_table.inc
|
||||
rm -f $(DATA_ASM_SUBDIR)/maps/connections.inc $(DATA_ASM_SUBDIR)/maps/events.inc $(DATA_ASM_SUBDIR)/maps/groups.inc $(DATA_ASM_SUBDIR)/maps/headers.inc
|
||||
find sound -iname '*.bin' -exec rm {} +
|
||||
find . \( -iname '*.1bpp' -o -iname '*.4bpp' -o -iname '*.8bpp' -o -iname '*.gbapal' -o -iname '*.lz' -o -iname '*.rl' -o -iname '*.latfont' -o -iname '*.hwjpnfont' -o -iname '*.fwjpnfont' \) -exec rm {} +
|
||||
find $(DATA_ASM_SUBDIR)/maps \( -iname 'connections.inc' -o -iname 'events.inc' -o -iname 'header.inc' \) -exec rm {} +
|
||||
rm -f $(AUTO_GEN_TARGETS)
|
||||
@$(MAKE) clean -C libagbsyscall
|
||||
|
||||
tidy: tidynonmodern tidymodern
|
||||
|
||||
@ -253,151 +256,109 @@ tidymodern:
|
||||
rm -f $(MODERN_ROM_NAME) $(MODERN_ELF_NAME) $(MODERN_MAP_NAME)
|
||||
rm -rf $(MODERN_OBJ_DIR_NAME)
|
||||
|
||||
ifneq ($(MODERN),0)
|
||||
$(C_BUILDDIR)/berry_crush.o: override CFLAGS += -Wno-address-of-packed-member
|
||||
endif
|
||||
|
||||
# Other rules
|
||||
include graphics_file_rules.mk
|
||||
include map_data_rules.mk
|
||||
include spritesheet_rules.mk
|
||||
include json_data_rules.mk
|
||||
include songs.mk
|
||||
include audio_rules.mk
|
||||
|
||||
%.s: ;
|
||||
# NOTE: Tools must have been built prior (FIXME)
|
||||
# so you can't really call this rule directly
|
||||
generated: $(AUTO_GEN_TARGETS)
|
||||
@: # Silence the "Nothing to be done for `generated'" message, which some people were confusing for an error.
|
||||
|
||||
|
||||
%.s: ;
|
||||
%.png: ;
|
||||
%.pal: ;
|
||||
%.aif: ;
|
||||
|
||||
%.1bpp: %.png ; $(GFX) $< $@
|
||||
%.4bpp: %.png ; $(GFX) $< $@
|
||||
%.8bpp: %.png ; $(GFX) $< $@
|
||||
%.gbapal: %.pal ; $(GFX) $< $@
|
||||
%.gbapal: %.png ; $(GFX) $< $@
|
||||
%.lz: % ; $(GFX) $< $@
|
||||
%.rl: % ; $(GFX) $< $@
|
||||
$(CRY_SUBDIR)/%.bin: $(CRY_SUBDIR)/%.aif ; $(AIF) $< $@ --compress
|
||||
sound/%.bin: sound/%.aif ; $(AIF) $< $@
|
||||
%.1bpp: %.png ; $(GFX) $< $@
|
||||
%.4bpp: %.png ; $(GFX) $< $@
|
||||
%.8bpp: %.png ; $(GFX) $< $@
|
||||
%.gbapal: %.pal ; $(GFX) $< $@
|
||||
%.gbapal: %.png ; $(GFX) $< $@
|
||||
%.lz: % ; $(GFX) $< $@
|
||||
%.rl: % ; $(GFX) $< $@
|
||||
|
||||
clean-generated:
|
||||
-rm -f $(AUTO_GEN_TARGETS)
|
||||
|
||||
ifeq ($(MODERN),0)
|
||||
$(C_BUILDDIR)/libc.o: CC1 := tools/agbcc/bin/old_agbcc$(EXE)
|
||||
$(C_BUILDDIR)/libc.o: CC1 := $(TOOLS_DIR)/agbcc/bin/old_agbcc$(EXE)
|
||||
$(C_BUILDDIR)/libc.o: CFLAGS := -O2
|
||||
|
||||
$(C_BUILDDIR)/siirtc.o: CFLAGS := -mthumb-interwork
|
||||
|
||||
$(C_BUILDDIR)/agb_flash.o: CFLAGS := -O -mthumb-interwork
|
||||
$(C_BUILDDIR)/agb_flash_1m.o: CFLAGS := -O -mthumb-interwork
|
||||
$(C_BUILDDIR)/agb_flash_mx.o: CFLAGS := -O -mthumb-interwork
|
||||
|
||||
$(C_BUILDDIR)/m4a.o: CC1 := tools/agbcc/bin/old_agbcc$(EXE)
|
||||
|
||||
$(C_BUILDDIR)/record_mixing.o: CFLAGS += -ffreestanding
|
||||
$(C_BUILDDIR)/librfu_intr.o: CC1 := tools/agbcc/bin/agbcc_arm$(EXE)
|
||||
$(C_BUILDDIR)/librfu_intr.o: CC1 := $(TOOLS_DIR)/agbcc/bin/agbcc_arm$(EXE)
|
||||
$(C_BUILDDIR)/librfu_intr.o: CFLAGS := -O2 -mthumb-interwork -quiet
|
||||
else
|
||||
$(C_BUILDDIR)/librfu_intr.o: CFLAGS := -mthumb-interwork -O2 -mabi=apcs-gnu -mtune=arm7tdmi -march=armv4t -fno-toplevel-reorder -Wno-pointer-to-int-cast
|
||||
$(C_BUILDDIR)/berry_crush.o: override CFLAGS += -Wno-address-of-packed-member
|
||||
endif
|
||||
|
||||
ifeq ($(DINFO),1)
|
||||
override CFLAGS += -g
|
||||
endif
|
||||
# Dependency rules (for the *.c & *.s sources to .o files)
|
||||
# Have to be explicit or else missing files won't be reported.
|
||||
|
||||
ifeq ($(DDEBUG),1)
|
||||
override ASFLAGS += --defsym DEBUG=1
|
||||
override CPPFLAGS += -D DEBUG=1
|
||||
endif
|
||||
|
||||
# The dep rules have to be explicit or else missing files won't be reported.
|
||||
# As a side effect, they're evaluated immediately instead of when the rule is invoked.
|
||||
# It doesn't look like $(shell) can be deferred so there might not be a better way.
|
||||
# It doesn't look like $(shell) can be deferred so there might not be a better way (Icedude_907: there is soon).
|
||||
|
||||
ifeq ($(SCAN_DEPS),1)
|
||||
ifeq ($(NODEP),1)
|
||||
$(C_BUILDDIR)/%.o: $(C_SUBDIR)/%.c
|
||||
ifeq (,$(KEEP_TEMPS))
|
||||
ifneq ($(KEEP_TEMPS),1)
|
||||
@echo "$(CC1) <flags> -o $@ $<"
|
||||
@$(CPP) $(CPPFLAGS) $< | $(PREPROC) $< charmap.txt -i | $(CC1) $(CFLAGS) -o - - | cat - <(echo -e ".text\n\t.align\t2, 0") | $(AS) $(ASFLAGS) -o $@ -
|
||||
@$(CPP) $(CPPFLAGS) $< | $(PREPROC) -i $< charmap.txt | $(CC1) $(CFLAGS) -o - - | cat - <(echo -e ".text\n\t.align\t2, 0") | $(AS) $(ASFLAGS) -o $@ -
|
||||
else
|
||||
@$(CPP) $(CPPFLAGS) $< -o $(C_BUILDDIR)/$*.i
|
||||
@$(PREPROC) $(C_BUILDDIR)/$*.i charmap.txt | $(CC1) $(CFLAGS) -o $(C_BUILDDIR)/$*.s
|
||||
@echo -e ".text\n\t.align\t2, 0\n" >> $(C_BUILDDIR)/$*.s
|
||||
$(AS) $(ASFLAGS) -o $@ $(C_BUILDDIR)/$*.s
|
||||
endif
|
||||
else
|
||||
define C_DEP
|
||||
$1: $2 $$(shell $(SCANINC) -I include -I tools/agbcc/include -I gflib $2)
|
||||
ifeq (,$$(KEEP_TEMPS))
|
||||
@echo "$$(CC1) <flags> -o $$@ $$<"
|
||||
@$$(CPP) $$(CPPFLAGS) $$< | $$(PREPROC) $$< charmap.txt -i | $$(CC1) $$(CFLAGS) -o - - | cat - <(echo -e ".text\n\t.align\t2, 0") | $$(AS) $$(ASFLAGS) -o $$@ -
|
||||
else
|
||||
@$$(CPP) $$(CPPFLAGS) $$< -o $$(C_BUILDDIR)/$3.i
|
||||
@$$(PREPROC) $$(C_BUILDDIR)/$3.i charmap.txt | $$(CC1) $$(CFLAGS) -o $$(C_BUILDDIR)/$3.s
|
||||
@echo -e ".text\n\t.align\t2, 0\n" >> $$(C_BUILDDIR)/$3.s
|
||||
$$(AS) $$(ASFLAGS) -o $$@ $$(C_BUILDDIR)/$3.s
|
||||
endif
|
||||
endef
|
||||
$(foreach src, $(C_SRCS), $(eval $(call C_DEP,$(patsubst $(C_SUBDIR)/%.c,$(C_BUILDDIR)/%.o,$(src)),$(src),$(patsubst $(C_SUBDIR)/%.c,%,$(src)))))
|
||||
@$(CPP) $(CPPFLAGS) $< -o $*.i
|
||||
@$(PREPROC) $*.i charmap.txt | $(CC1) $(CFLAGS) -o $*.s
|
||||
@echo -e ".text\n\t.align\t2, 0\n" >> $*.s
|
||||
$(AS) $(ASFLAGS) -o $@ $*.s
|
||||
endif
|
||||
|
||||
ifeq ($(NODEP),1)
|
||||
$(GFLIB_BUILDDIR)/%.o: $(GFLIB_SUBDIR)/%.c $$(c_dep)
|
||||
ifeq (,$(KEEP_TEMPS))
|
||||
@echo "$(CC1) <flags> -o $@ $<"
|
||||
@$(CPP) $(CPPFLAGS) $< | $(PREPROC) $< charmap.txt -i | $(CC1) $(CFLAGS) -o - - | cat - <(echo -e ".text\n\t.align\t2, 0") | $(AS) $(ASFLAGS) -o $@ -
|
||||
else
|
||||
@$(CPP) $(CPPFLAGS) $< -o $(GFLIB_BUILDDIR)/$*.i
|
||||
@$(PREPROC) $(GFLIB_BUILDDIR)/$*.i charmap.txt | $(CC1) $(CFLAGS) -o $(GFLIB_BUILDDIR)/$*.s
|
||||
@echo -e ".text\n\t.align\t2, 0\n" >> $(GFLIB_BUILDDIR)/$*.s
|
||||
$(AS) $(ASFLAGS) -o $@ $(GFLIB_BUILDDIR)/$*.s
|
||||
endif
|
||||
else
|
||||
define GFLIB_DEP
|
||||
$1: $2 $$(shell $(SCANINC) -I include -I tools/agbcc/include -I gflib $2)
|
||||
ifeq (,$$(KEEP_TEMPS))
|
||||
@echo "$$(CC1) <flags> -o $$@ $$<"
|
||||
@$$(CPP) $$(CPPFLAGS) $$< | $$(PREPROC) $$< charmap.txt -i | $$(CC1) $$(CFLAGS) -o - - | cat - <(echo -e ".text\n\t.align\t2, 0") | $$(AS) $$(ASFLAGS) -o $$@ -
|
||||
else
|
||||
@$$(CPP) $$(CPPFLAGS) $$< -o $$(GFLIB_BUILDDIR)/$3.i
|
||||
@$$(PREPROC) $$(GFLIB_BUILDDIR)/$3.i charmap.txt | $$(CC1) $$(CFLAGS) -o $$(GFLIB_BUILDDIR)/$3.s
|
||||
@echo -e ".text\n\t.align\t2, 0\n" >> $$(GFLIB_BUILDDIR)/$3.s
|
||||
$$(AS) $$(ASFLAGS) -o $$@ $$(GFLIB_BUILDDIR)/$3.s
|
||||
endif
|
||||
endef
|
||||
$(foreach src, $(GFLIB_SRCS), $(eval $(call GFLIB_DEP,$(patsubst $(GFLIB_SUBDIR)/%.c,$(GFLIB_BUILDDIR)/%.o, $(src)),$(src),$(patsubst $(GFLIB_SUBDIR)/%.c,%, $(src)))))
|
||||
$(C_BUILDDIR)/%.d: $(C_SUBDIR)/%.c
|
||||
$(SCANINC) -M $@ $(INCLUDE_SCANINC_ARGS) -I tools/agbcc/include $<
|
||||
|
||||
ifneq ($(NODEP),1)
|
||||
-include $(addprefix $(OBJ_DIR)/,$(C_SRCS:.c=.d))
|
||||
endif
|
||||
|
||||
ifeq ($(NODEP),1)
|
||||
$(C_BUILDDIR)/%.o: $(C_SUBDIR)/%.s
|
||||
$(PREPROC) $< charmap.txt | $(CPP) -I include - | $(AS) $(ASFLAGS) -o $@
|
||||
else
|
||||
define SRC_ASM_DATA_DEP
|
||||
$1: $2 $$(shell $(SCANINC) -I include -I "" $2)
|
||||
$$(PREPROC) $$< charmap.txt | $$(CPP) -I include - | $$(AS) $$(ASFLAGS) -o $$@
|
||||
endef
|
||||
$(foreach src, $(C_ASM_SRCS), $(eval $(call SRC_ASM_DATA_DEP,$(patsubst $(C_SUBDIR)/%.s,$(C_BUILDDIR)/%.o, $(src)),$(src))))
|
||||
endif
|
||||
|
||||
ifeq ($(NODEP),1)
|
||||
$(ASM_BUILDDIR)/%.o: $(ASM_SUBDIR)/%.s
|
||||
$(AS) $(ASFLAGS) -o $@ $<
|
||||
else
|
||||
define ASM_DEP
|
||||
$1: $2 $$(shell $(SCANINC) -I include -I "" $2)
|
||||
$$(AS) $$(ASFLAGS) -o $$@ $$<
|
||||
endef
|
||||
$(foreach src, $(ASM_SRCS), $(eval $(call ASM_DEP,$(patsubst $(ASM_SUBDIR)/%.s,$(ASM_BUILDDIR)/%.o, $(src)),$(src))))
|
||||
|
||||
$(ASM_BUILDDIR)/%.d: $(ASM_SUBDIR)/%.s
|
||||
$(SCANINC) -M $@ $(INCLUDE_SCANINC_ARGS) -I "" $<
|
||||
|
||||
ifneq ($(NODEP),1)
|
||||
-include $(addprefix $(OBJ_DIR)/,$(ASM_SRCS:.s=.d))
|
||||
endif
|
||||
|
||||
$(C_BUILDDIR)/%.o: $(C_SUBDIR)/%.s
|
||||
$(PREPROC) $< charmap.txt | $(CPP) $(INCLUDE_SCANINC_ARGS) - | $(PREPROC) -ie $< charmap.txt | $(AS) $(ASFLAGS) -o $@
|
||||
|
||||
$(C_BUILDDIR)/%.d: $(C_SUBDIR)/%.s
|
||||
$(SCANINC) -M $@ $(INCLUDE_SCANINC_ARGS) -I "" $<
|
||||
|
||||
ifneq ($(NODEP),1)
|
||||
-include $(addprefix $(OBJ_DIR)/,$(C_ASM_SRCS:.s=.d))
|
||||
endif
|
||||
|
||||
ifeq ($(NODEP),1)
|
||||
$(DATA_ASM_BUILDDIR)/%.o: $(DATA_ASM_SUBDIR)/%.s
|
||||
$(PREPROC) $< charmap.txt | $(CPP) -I include - | $(AS) $(ASFLAGS) -o $@
|
||||
else
|
||||
$(foreach src, $(REGULAR_DATA_ASM_SRCS), $(eval $(call SRC_ASM_DATA_DEP,$(patsubst $(DATA_ASM_SUBDIR)/%.s,$(DATA_ASM_BUILDDIR)/%.o, $(src)),$(src))))
|
||||
endif
|
||||
endif
|
||||
$(PREPROC) $< charmap.txt | $(CPP) $(INCLUDE_SCANINC_ARGS) - | $(PREPROC) -ie $< charmap.txt | $(AS) $(ASFLAGS) -o $@
|
||||
|
||||
$(SONG_BUILDDIR)/%.o: $(SONG_SUBDIR)/%.s
|
||||
$(AS) $(ASFLAGS) -I sound -o $@ $<
|
||||
$(DATA_ASM_BUILDDIR)/%.d: $(DATA_ASM_SUBDIR)/%.s
|
||||
$(SCANINC) -M $@ $(INCLUDE_SCANINC_ARGS) -I "" $<
|
||||
|
||||
ifneq ($(NODEP),1)
|
||||
-include $(addprefix $(OBJ_DIR)/,$(REGULAR_DATA_ASM_SRCS:.s=.d))
|
||||
endif
|
||||
|
||||
$(OBJ_DIR)/sym_bss.ld: sym_bss.txt
|
||||
$(RAMSCRGEN) .bss $< ENGLISH > $@
|
||||
@ -408,6 +369,7 @@ $(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 > $@
|
||||
|
||||
# Linker script
|
||||
ifeq ($(MODERN),0)
|
||||
LD_SCRIPT := ld_script.ld
|
||||
LD_SCRIPT_DEPS := $(OBJ_DIR)/sym_bss.ld $(OBJ_DIR)/sym_common.ld $(OBJ_DIR)/sym_ewram.ld
|
||||
@ -416,27 +378,23 @@ LD_SCRIPT := ld_script_modern.ld
|
||||
LD_SCRIPT_DEPS :=
|
||||
endif
|
||||
|
||||
$(OBJ_DIR)/ld_script.ld: $(LD_SCRIPT) $(LD_SCRIPT_DEPS)
|
||||
cd $(OBJ_DIR) && sed "s#tools/#../../tools/#g" ../../$(LD_SCRIPT) > ld_script.ld
|
||||
|
||||
LDFLAGS = -Map ../../$(MAP)
|
||||
$(ELF): $(OBJ_DIR)/ld_script.ld $(OBJS) libagbsyscall
|
||||
@echo "cd $(OBJ_DIR) && $(LD) $(LDFLAGS) -T ld_script.ld -o ../../$@ <objects> <lib>"
|
||||
@cd $(OBJ_DIR) && $(LD) $(LDFLAGS) -T ld_script.ld --print-memory-usage -o ../../$@ $(OBJS_REL) $(LIB) | cat
|
||||
$(FIX) $@ -t"$(TITLE)" -c$(GAME_CODE) -m$(MAKER_CODE) -r$(REVISION) --silent
|
||||
|
||||
$(ROM): $(ELF)
|
||||
$(OBJCOPY) -O binary $< $@
|
||||
$(FIX) $@ -p --silent
|
||||
|
||||
modern: all
|
||||
# Final rules
|
||||
|
||||
libagbsyscall:
|
||||
@$(MAKE) -C libagbsyscall TOOLCHAIN=$(TOOLCHAIN) MODERN=$(MODERN)
|
||||
|
||||
###################
|
||||
### Symbol file ###
|
||||
###################
|
||||
# Elf from object files
|
||||
LDFLAGS = -Map ../../$(MAP)
|
||||
$(ELF): $(LD_SCRIPT) $(LD_SCRIPT_DEPS) $(OBJS) libagbsyscall
|
||||
@cd $(OBJ_DIR) && $(LD) $(LDFLAGS) -T ../../$< --print-memory-usage -o ../../$@ $(OBJS_REL) $(LIB) | cat
|
||||
@echo "cd $(OBJ_DIR) && $(LD) $(LDFLAGS) -T ../../$< --print-memory-usage -o ../../$@ <objs> <libs> | cat"
|
||||
$(FIX) $@ -t"$(TITLE)" -c$(GAME_CODE) -m$(MAKER_CODE) -r$(REVISION) --silent
|
||||
|
||||
# Builds the rom from the elf file
|
||||
$(ROM): $(ELF)
|
||||
$(OBJCOPY) -O binary $< $@
|
||||
$(FIX) $@ -p --silent
|
||||
|
||||
# Symbol file (`make syms`)
|
||||
$(SYM): $(ELF)
|
||||
$(OBJDUMP) -t $< | sort -u | grep -E "^0[2389]" | $(PERL) -p -e 's/^(\w{8}) (\w).{6} \S+\t(\w{8}) (\S+)$$/\1 \2 \3 \4/g' > $@
|
||||
|
||||
@ -141,25 +141,25 @@
|
||||
|
||||
.macro if_points_less_than num:req, destination:req
|
||||
.byte 0x16
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_points_more_than num:req, destination:req
|
||||
.byte 0x17
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_points_eq num:req, destination:req
|
||||
.byte 0x18
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_points_not_eq num:req, destination:req
|
||||
.byte 0x19
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
@ -171,25 +171,25 @@
|
||||
|
||||
.macro if_preliminary_points_less_than num:req, destination:req
|
||||
.byte 0x1B
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_preliminary_points_more_than num:req, destination:req
|
||||
.byte 0x1C
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_preliminary_points_eq num:req, destination:req
|
||||
.byte 0x1D
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
.macro if_preliminary_points_not_eq num:req, destination:req
|
||||
.byte 0x1E
|
||||
.byte \num
|
||||
.2byte \num
|
||||
.4byte \destination
|
||||
.endm
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [[ -d "$DEVKITARM/bin/" ]]; then
|
||||
OBJDUMP_BIN="$DEVKITARM/bin/arm-none-eabi-objdump"
|
||||
|
||||
45
audio_rules.mk
Normal file
45
audio_rules.mk
Normal file
@ -0,0 +1,45 @@
|
||||
# This file contains rules for making assemblies for most music in the game.
|
||||
|
||||
CRY_SUBDIR := sound/direct_sound_samples/cries
|
||||
|
||||
MID_ASM_DIR := $(MID_SUBDIR)
|
||||
CRY_BIN_DIR := $(CRY_SUBDIR)
|
||||
SOUND_BIN_DIR := sound
|
||||
|
||||
SPECIAL_OUTDIRS := $(MID_ASM_DIR) $(CRY_BIN_DIR)
|
||||
SPECIAL_OUTDIRS += $(SOUND_BIN_DIR) $(SOUND_BIN_DIR)/direct_sound_samples/phonemes $(SOUND_BIN_DIR)/direct_sound_samples/cries
|
||||
$(shell mkdir -p $(SPECIAL_OUTDIRS) )
|
||||
|
||||
# Assembly song compilation
|
||||
$(SONG_BUILDDIR)/%.o: $(SONG_SUBDIR)/%.s
|
||||
$(AS) $(ASFLAGS) -I sound -o $@ $<
|
||||
$(MID_BUILDDIR)/%.o: $(MID_ASM_DIR)/%.s
|
||||
$(AS) $(ASFLAGS) -I sound -o $@ $<
|
||||
|
||||
# Compressed cries
|
||||
$(CRY_BIN_DIR)/%.bin: $(CRY_SUBDIR)/%.aif
|
||||
$(AIF) $< $@ --compress
|
||||
|
||||
# Uncompressed sounds
|
||||
$(SOUND_BIN_DIR)/%.bin: sound/%.aif
|
||||
$(AIF) $< $@
|
||||
|
||||
# For each line in midi.cfg, we do some trickery to convert it into a make rule for the `.mid` file described on the line
|
||||
# Data following the colon in said file corresponds to arguments passed into mid2agb
|
||||
MID_CFG_PATH := $(MID_SUBDIR)/midi.cfg
|
||||
|
||||
# $1: Source path no extension, $2 Options
|
||||
define MID_RULE
|
||||
$(MID_ASM_DIR)/$1.s: $(MID_SUBDIR)/$1.mid $(MID_CFG_PATH)
|
||||
$(MID) $$< $$@ $2
|
||||
endef
|
||||
# source path, remaining text (options)
|
||||
define MID_EXPANSION
|
||||
$(eval $(call MID_RULE,$(basename $(patsubst %:,%,$(word 1,$1))),$(wordlist 2,999,$1)))
|
||||
endef
|
||||
|
||||
$(foreach line,$(shell cat $(MID_CFG_PATH) | sed "s/ /__SPACE__/g"),$(call MID_EXPANSION,$(subst __SPACE__, ,$(line))))
|
||||
|
||||
# Warn users building without a .cfg - build will fail at link time
|
||||
$(MID_ASM_DIR)/%.s: $(MID_SUBDIR)/%.mid
|
||||
$(warning $< does not have an associated entry in midi.cfg! It cannot be built)
|
||||
@ -1 +0,0 @@
|
||||
lman
|
||||
@ -1,10 +0,0 @@
|
||||
gFlashTimeoutFlag
|
||||
PollFlashStatus
|
||||
WaitForFlashWrite
|
||||
ProgramFlashSector
|
||||
gFlash
|
||||
ProgramFlashByte
|
||||
gFlashNumRemainingBytes
|
||||
EraseFlashChip
|
||||
EraseFlashSector
|
||||
gFlashMaxTime
|
||||
@ -1,3 +0,0 @@
|
||||
gApprenticePartyMovesData
|
||||
gApprenticeQuestionData
|
||||
gApprenticeFunc
|
||||
@ -1,3 +0,0 @@
|
||||
gMonShrinkDuration
|
||||
gMonShrinkDelta
|
||||
gMonShrinkDistance
|
||||
@ -1 +0,0 @@
|
||||
gFactorySelect_CurrentOptionFunc
|
||||
@ -1,9 +0,0 @@
|
||||
gPreBattleCallback1
|
||||
gBattleMainFunc
|
||||
gBattleResults
|
||||
gLeveledUpInBattle
|
||||
gBattlerControllerFuncs
|
||||
gHealthboxSpriteIds
|
||||
gMultiUsePlayerCursor
|
||||
gNumberOfMovesToChoose
|
||||
gBattleControllerData
|
||||
@ -1 +0,0 @@
|
||||
gFrontierTempParty
|
||||
@ -1 +0,0 @@
|
||||
gInGameOpponentsNo
|
||||
@ -1 +0,0 @@
|
||||
gWindowTileAutoAllocEnabled
|
||||
@ -1 +0,0 @@
|
||||
gContestRngValue
|
||||
@ -1,4 +0,0 @@
|
||||
gContestMonPixels
|
||||
gImageProcessingContext
|
||||
gContestPaintingWinner
|
||||
gContestPaintingMonPalette
|
||||
@ -1 +0,0 @@
|
||||
gEReaderData
|
||||
@ -1 +0,0 @@
|
||||
gCB2_AfterEvolution
|
||||
@ -1,3 +0,0 @@
|
||||
sPlayerToMewDeltaX
|
||||
sPlayerToMewDeltaY
|
||||
sMewDirectionCandidates
|
||||
@ -1,3 +0,0 @@
|
||||
gFieldCamera
|
||||
gTotalCameraPixelOffsetY
|
||||
gTotalCameraPixelOffsetX
|
||||
@ -1 +0,0 @@
|
||||
gSelectedObjectEvent
|
||||
@ -1 +0,0 @@
|
||||
gScrollableMultichoice_ListMenuTemplate
|
||||
@ -1 +0,0 @@
|
||||
gBackupMapLayout
|
||||
@ -1,10 +0,0 @@
|
||||
gCanvasColumnStart
|
||||
gCanvasPixels
|
||||
gCanvasRowEnd
|
||||
gCanvasHeight
|
||||
gCanvasColumnEnd
|
||||
gCanvasRowStart
|
||||
gCanvasMonPersonality
|
||||
gCanvasWidth
|
||||
gCanvasPalette
|
||||
gCanvasPaletteStart
|
||||
@ -1,2 +0,0 @@
|
||||
gIntroFrameCounter
|
||||
gMultibootProgramStruct
|
||||
@ -1,5 +0,0 @@
|
||||
gRfuSlotStatusUNI
|
||||
gRfuSlotStatusNI
|
||||
gRfuLinkStatus
|
||||
gRfuStatic
|
||||
gRfuFixed
|
||||
@ -1 +0,0 @@
|
||||
gRfuSIO32Id
|
||||
@ -1 +0,0 @@
|
||||
gSTWIStatus
|
||||
@ -1,35 +0,0 @@
|
||||
gLinkPartnersHeldKeys
|
||||
gLinkDebugSeed
|
||||
gLocalLinkPlayerBlock
|
||||
gLinkErrorOccurred
|
||||
gLinkDebugFlags
|
||||
gLinkFiller1
|
||||
gRemoteLinkPlayersNotReceived
|
||||
gBlockReceivedStatus
|
||||
gLinkFiller2
|
||||
gLinkHeldKeys
|
||||
gRecvCmds
|
||||
gLinkStatus
|
||||
gLinkDummy1
|
||||
gLinkDummy2
|
||||
gReadyToExitStandby
|
||||
gReadyToCloseLink
|
||||
gReadyCloseLinkType
|
||||
gSuppressLinkErrorMessage
|
||||
gWirelessCommType
|
||||
gSavedLinkPlayerCount
|
||||
gSendCmd
|
||||
gSavedMultiplayerId
|
||||
gReceivedRemoteLinkPlayers
|
||||
gLinkTestBGInfo
|
||||
gLinkCallback
|
||||
gShouldAdvanceLinkState
|
||||
gLinkTestBlockChecksums
|
||||
gBlockRequestType
|
||||
gLinkFiller3
|
||||
gLinkFiller4
|
||||
gLinkFiller5
|
||||
gLastSendQueueCount
|
||||
gLink
|
||||
gLastRecvQueueCount
|
||||
gLinkSavedIme
|
||||
@ -1,2 +0,0 @@
|
||||
gRfuAPIBuffer
|
||||
gRfu
|
||||
@ -1,2 +0,0 @@
|
||||
gListMenuOverride
|
||||
gMultiuseListMenuTemplate
|
||||
@ -1,4 +0,0 @@
|
||||
gFlashMemoryPresent
|
||||
gSaveBlock1Ptr
|
||||
gSaveBlock2Ptr
|
||||
gPokemonStoragePtr
|
||||
@ -1,12 +0,0 @@
|
||||
gSoundInfo
|
||||
gPokemonCrySongs
|
||||
gPokemonCryMusicPlayers
|
||||
gMPlayInfo_BGM
|
||||
gMPlayJumpTable
|
||||
gCgbChans
|
||||
gMPlayInfo_SE1
|
||||
gMPlayInfo_SE2
|
||||
gPokemonCryTracks
|
||||
gPokemonCrySong
|
||||
gMPlayMemAccArea
|
||||
gMPlayInfo_SE3
|
||||
@ -1,9 +0,0 @@
|
||||
gKeyRepeatStartDelay
|
||||
gLinkTransferringData
|
||||
gMain
|
||||
gKeyRepeatContinueDelay
|
||||
gSoftResetDisabled
|
||||
gIntrTable
|
||||
gLinkVSyncDisabled
|
||||
IntrMain_Buffer
|
||||
gPcmDmaCounter
|
||||
@ -1 +0,0 @@
|
||||
gBardSong
|
||||
@ -1,11 +0,0 @@
|
||||
gOverworldTilemapBuffer_Bg2
|
||||
gOverworldTilemapBuffer_Bg1
|
||||
gOverworldTilemapBuffer_Bg3
|
||||
gHeldKeyCodeToSend
|
||||
gFieldCallback
|
||||
gFieldCallback2
|
||||
gLocalLinkPlayerId
|
||||
gFieldLinkPlayerCount
|
||||
gTimeOfDay
|
||||
currentTimeBlend
|
||||
gTimeUpdateCounter
|
||||
@ -1 +0,0 @@
|
||||
gItemUseCB
|
||||
@ -1,2 +0,0 @@
|
||||
gUnusedPokedexU8
|
||||
gPokedexVBlankCB
|
||||
@ -1 +0,0 @@
|
||||
gDexCryScreenState
|
||||
@ -1,2 +0,0 @@
|
||||
gRngValue
|
||||
gRng2Value
|
||||
@ -1 +0,0 @@
|
||||
gLocalTime
|
||||
@ -1,13 +0,0 @@
|
||||
gLastWrittenSector
|
||||
gLastSaveCounter
|
||||
gLastKnownGoodSector
|
||||
gDamagedSaveSectors
|
||||
gSaveCounter
|
||||
gReadWriteSector
|
||||
gIncrementalSectorId
|
||||
gSaveUnusedVar
|
||||
gSaveFileStatus
|
||||
gGameContinueCallback
|
||||
gRamSaveSectorLocations
|
||||
gSaveUnusedVar2
|
||||
gSaveAttemptStatus
|
||||
@ -1 +0,0 @@
|
||||
gDisableMusic
|
||||
@ -1,2 +0,0 @@
|
||||
gOamMatrixAllocBitmap
|
||||
gReservedSpritePaletteCount
|
||||
@ -1 +0,0 @@
|
||||
gMenuCallback
|
||||
@ -1 +0,0 @@
|
||||
gTasks
|
||||
@ -1,4 +0,0 @@
|
||||
gFonts
|
||||
gDisableTextPrinters
|
||||
gCurGlyph
|
||||
gTextFlags
|
||||
@ -1,5 +0,0 @@
|
||||
gWhichTrainerToFaceAfterBattle
|
||||
gPostBattleMovementScript
|
||||
gApproachingTrainers
|
||||
gNoOfApproachingTrainers
|
||||
gTrainerApproachedPlayer
|
||||
@ -1,4 +0,0 @@
|
||||
sCurTVShowSlot
|
||||
sTV_SecretBaseVisitMovesTemp
|
||||
sTV_DecorationsBuffer
|
||||
sTV_SecretBaseVisitMonsTemp
|
||||
@ -1,2 +0,0 @@
|
||||
gTransparentTileNumber
|
||||
gWindowBgTilemapBuffers
|
||||
@ -1613,6 +1613,8 @@ AI_CV_Disable2:
|
||||
AI_CV_Disable_End:
|
||||
end
|
||||
|
||||
@ BUG: The original script would score up Counter when the target's types were not physical
|
||||
@ This is incorrect since Counter only deals double the damage received if hit by a physical attack
|
||||
AI_CV_Counter:
|
||||
if_status AI_TARGET, STATUS1_SLEEP, AI_CV_Counter_ScoreDown1
|
||||
if_status2 AI_TARGET, STATUS2_INFATUATION, AI_CV_Counter_ScoreDown1
|
||||
@ -1625,7 +1627,7 @@ AI_CV_Counter2:
|
||||
if_random_less_than 100, AI_CV_Counter3
|
||||
score -1
|
||||
AI_CV_Counter3:
|
||||
if_has_move AI_USER, MOVE_MIRROR_COAT, AI_CV_Counter7
|
||||
if_has_move AI_USER, MOVE_MIRROR_COAT, AI_CV_Counter8
|
||||
get_last_used_bank_move AI_TARGET
|
||||
get_move_power_from_result
|
||||
if_equal 0, AI_CV_Counter5
|
||||
@ -1645,15 +1647,24 @@ AI_CV_Counter5:
|
||||
if_random_less_than 100, AI_CV_Counter6
|
||||
score +1
|
||||
AI_CV_Counter6:
|
||||
#ifdef BUGFIX
|
||||
get_target_type1
|
||||
if_in_bytes AI_CV_Counter_PhysicalTypeList, AI_CV_Counter7
|
||||
get_target_type2
|
||||
if_in_bytes AI_CV_Counter_PhysicalTypeList, AI_CV_Counter7
|
||||
goto AI_CV_Counter_End
|
||||
#else
|
||||
get_target_type1
|
||||
if_in_bytes AI_CV_Counter_PhysicalTypeList, AI_CV_Counter_End
|
||||
get_target_type2
|
||||
if_in_bytes AI_CV_Counter_PhysicalTypeList, AI_CV_Counter_End
|
||||
if_random_less_than 50, AI_CV_Counter_End
|
||||
#endif
|
||||
AI_CV_Counter7:
|
||||
if_random_less_than 100, AI_CV_Counter8
|
||||
score +4
|
||||
if_random_less_than 50, AI_CV_Counter_End
|
||||
AI_CV_Counter8:
|
||||
if_random_less_than 100, AI_CV_Counter9
|
||||
score +4
|
||||
AI_CV_Counter9:
|
||||
end
|
||||
|
||||
AI_CV_Counter_ScoreDown1:
|
||||
@ -2100,6 +2111,8 @@ AI_CV_PsychUp_ScoreDown2:
|
||||
AI_CV_PsychUp_End:
|
||||
end
|
||||
|
||||
@ BUG: The original script would score up Mirror Coat when the target's types were not special
|
||||
@ This is incorrect since Mirror Coat only deals double the damage received if hit by a special attack
|
||||
AI_CV_MirrorCoat:
|
||||
if_status AI_TARGET, STATUS1_SLEEP, AI_CV_MirrorCoat_ScoreDown1
|
||||
if_status2 AI_TARGET, STATUS2_INFATUATION, AI_CV_MirrorCoat_ScoreDown1
|
||||
@ -2132,10 +2145,19 @@ AI_CV_MirrorCoat5:
|
||||
if_random_less_than 100, AI_CV_MirrorCoat6
|
||||
score +1
|
||||
AI_CV_MirrorCoat6:
|
||||
#ifdef BUGFIX
|
||||
get_target_type1
|
||||
if_in_bytes AI_CV_MirrorCoat_SpecialTypeList, AI_CV_MirrorCoat7
|
||||
get_target_type2
|
||||
if_in_bytes AI_CV_MirrorCoat_SpecialTypeList, AI_CV_MirrorCoat7
|
||||
goto AI_CV_MirrorCoat_End
|
||||
#else
|
||||
get_target_type1
|
||||
if_in_bytes AI_CV_MirrorCoat_SpecialTypeList, AI_CV_MirrorCoat_End
|
||||
get_target_type2
|
||||
if_in_bytes AI_CV_MirrorCoat_SpecialTypeList, AI_CV_MirrorCoat_End
|
||||
#endif
|
||||
AI_CV_MirrorCoat7:
|
||||
if_random_less_than 50, AI_CV_MirrorCoat_End
|
||||
AI_CV_MirrorCoat_ScoreUp4:
|
||||
if_random_less_than 100, AI_CV_MirrorCoat_ScoreUp4_End
|
||||
|
||||
@ -60,6 +60,7 @@
|
||||
|
||||
.section script_data, "aw", %progbits
|
||||
|
||||
.set ALLOCATE_SCRIPT_CMD_TABLE, 1
|
||||
.include "data/script_cmd_table.inc"
|
||||
|
||||
gSpecialVars::
|
||||
@ -563,8 +564,8 @@ gStdScripts_End::
|
||||
.include "data/maps/Route110_TrickHousePuzzle6/scripts.inc"
|
||||
.include "data/maps/Route110_TrickHousePuzzle7/scripts.inc"
|
||||
.include "data/maps/Route110_TrickHousePuzzle8/scripts.inc"
|
||||
.include "data/maps/Route110_SeasideCyclingRoadNorthEntrance/scripts.inc"
|
||||
.include "data/maps/Route110_SeasideCyclingRoadSouthEntrance/scripts.inc"
|
||||
.include "data/maps/Route110_SeasideCyclingRoadNorthEntrance/scripts.inc"
|
||||
.include "data/maps/Route113_GlassWorkshop/scripts.inc"
|
||||
.include "data/maps/Route123_BerryMastersHouse/scripts.inc"
|
||||
.include "data/maps/Route119_WeatherInstitute_1F/scripts.inc"
|
||||
|
||||
@ -28,9 +28,7 @@ BattleFrontier_Mart_Pokemart:
|
||||
.2byte ITEM_ZINC
|
||||
.2byte ITEM_CARBOS
|
||||
.2byte ITEM_HP_UP
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
BattleFrontier_Mart_EventScript_OldMan::
|
||||
msgbox BattleFrontier_Mart_Text_ChaperonGrandson, MSGBOX_NPC
|
||||
|
||||
@ -45,9 +45,7 @@ EverGrandeCity_PokemonLeague_1F_Pokemart:
|
||||
.2byte ITEM_FULL_HEAL
|
||||
.2byte ITEM_REVIVE
|
||||
.2byte ITEM_MAX_REPEL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
@ The door guards only check for FLAG_BADGE06_GET because Winonas badge is the only one that can be skipped
|
||||
@ Its assumed the player has the remaining badges
|
||||
|
||||
@ -25,9 +25,7 @@ FallarborTown_Mart_Pokemart:
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_DIRE_HIT
|
||||
.2byte ITEM_GUARD_SPEC
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
FallarborTown_Mart_EventScript_Woman::
|
||||
msgbox FallarborTown_Mart_Text_DecidingSkittyEvolve, MSGBOX_NPC
|
||||
|
||||
@ -64,7 +64,7 @@
|
||||
"trainer_type": "TRAINER_TYPE_NONE",
|
||||
"trainer_sight_or_berry_tree_id": "0",
|
||||
"script": "FallarborTown_PokemonCenter_1F_EventScript_Lanette",
|
||||
"flag": "FLAG_HIDE_FALLORBOR_POKEMON_CENTER_LANETTE"
|
||||
"flag": "FLAG_HIDE_FALLARBOR_POKEMON_CENTER_LANETTE"
|
||||
}
|
||||
],
|
||||
"warp_events": [
|
||||
|
||||
@ -29,9 +29,7 @@ FortreeCity_DecorationShop_PokemartDecor_Desks:
|
||||
.2byte DECOR_BRICK_DESK
|
||||
.2byte DECOR_CAMP_DESK
|
||||
.2byte DECOR_HARD_DESK
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
FortreeCity_DecorationShop_EventScript_ClerkChairs::
|
||||
lock
|
||||
@ -53,9 +51,7 @@ FortreeCity_DecorationShop_PokemartDecor_Chairs:
|
||||
.2byte DECOR_BRICK_CHAIR
|
||||
.2byte DECOR_CAMP_CHAIR
|
||||
.2byte DECOR_HARD_CHAIR
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
FortreeCity_DecorationShop_Text_MerchandiseSentToPC:
|
||||
.string "Merchandise you buy here is sent to\n"
|
||||
|
||||
@ -23,9 +23,7 @@ FortreeCity_Mart_Pokemart:
|
||||
.2byte ITEM_REVIVE
|
||||
.2byte ITEM_SUPER_REPEL
|
||||
.2byte ITEM_WOOD_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
FortreeCity_Mart_EventScript_Woman::
|
||||
msgbox FortreeCity_Mart_Text_SuperRepelBetter, MSGBOX_NPC
|
||||
|
||||
@ -17,9 +17,7 @@ LavaridgeTown_HerbShop_Pokemart:
|
||||
.2byte ITEM_ENERGY_ROOT
|
||||
.2byte ITEM_HEAL_POWDER
|
||||
.2byte ITEM_REVIVAL_HERB
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LavaridgeTown_HerbShop_EventScript_ExpertM::
|
||||
msgbox LavaridgeTown_HerbShop_Text_HerbalMedicineWorksButMonWillDislike, MSGBOX_NPC
|
||||
|
||||
@ -22,9 +22,7 @@ LavaridgeTown_Mart_Pokemart:
|
||||
.2byte ITEM_REVIVE
|
||||
.2byte ITEM_SUPER_REPEL
|
||||
.2byte ITEM_X_SPEED
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LavaridgeTown_Mart_EventScript_ExpertM::
|
||||
msgbox LavaridgeTown_Mart_Text_XSpeedFirstStrike, MSGBOX_NPC
|
||||
|
||||
@ -36,9 +36,7 @@ LilycoveCity_DepartmentStore_2F_Pokemart1:
|
||||
.2byte ITEM_ICE_HEAL
|
||||
.2byte ITEM_AWAKENING
|
||||
.2byte ITEM_FLUFFY_TAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_2F_EventScript_ClerkRight::
|
||||
lock
|
||||
@ -62,9 +60,7 @@ LilycoveCity_DepartmentStore_2F_Pokemart2:
|
||||
.2byte ITEM_MAX_REPEL
|
||||
.2byte ITEM_WAVE_MAIL
|
||||
.2byte ITEM_MECH_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_2F_Text_LearnToUseItemsProperly:
|
||||
.string "Learn to use items properly.\n"
|
||||
|
||||
@ -19,9 +19,7 @@ LilycoveCity_DepartmentStore_3F_Pokemart_Vitamins:
|
||||
.2byte ITEM_ZINC
|
||||
.2byte ITEM_CARBOS
|
||||
.2byte ITEM_HP_UP
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_3F_EventScript_ClerkRight::
|
||||
lock
|
||||
@ -42,9 +40,7 @@ LilycoveCity_DepartmentStore_3F_Pokemart_StatBoosters:
|
||||
.2byte ITEM_DIRE_HIT
|
||||
.2byte ITEM_GUARD_SPEC
|
||||
.2byte ITEM_X_ACCURACY
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_3F_EventScript_TriathleteM::
|
||||
msgbox LilycoveCity_DepartmentStore_3F_Text_ItemsBestForTougheningPokemon, MSGBOX_NPC
|
||||
|
||||
@ -29,9 +29,7 @@ LilycoveCity_DepartmentStore_4F_Pokemart_AttackTMs:
|
||||
.2byte ITEM_TM_THUNDER
|
||||
.2byte ITEM_TM_BLIZZARD
|
||||
.2byte ITEM_TM_HYPER_BEAM
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_4F_EventScript_ClerkRight::
|
||||
lock
|
||||
@ -49,9 +47,7 @@ LilycoveCity_DepartmentStore_4F_Pokemart_DefenseTMs:
|
||||
.2byte ITEM_TM_SAFEGUARD
|
||||
.2byte ITEM_TM_REFLECT
|
||||
.2byte ITEM_TM_LIGHT_SCREEN
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_4F_Text_AttackOrDefenseTM:
|
||||
.string "Hmm…\p"
|
||||
|
||||
@ -41,9 +41,7 @@ LilycoveCity_DepartmentStore_5F_Pokemart_Dolls:
|
||||
.2byte DECOR_SKITTY_DOLL
|
||||
.2byte DECOR_SWABLU_DOLL
|
||||
.2byte DECOR_GULPIN_DOLL
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_5F_EventScript_ClerkMidLeft::
|
||||
lock
|
||||
@ -66,9 +64,7 @@ LilycoveCity_DepartmentStore_5F_Pokemart_Cushions:
|
||||
.2byte DECOR_GRASS_CUSHION
|
||||
.2byte DECOR_FIRE_CUSHION
|
||||
.2byte DECOR_WATER_CUSHION
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_5F_EventScript_ClerkMidRight::
|
||||
lock
|
||||
@ -91,9 +87,7 @@ LilycoveCity_DepartmentStore_5F_Pokemart_Posters:
|
||||
.2byte DECOR_LONG_POSTER
|
||||
.2byte DECOR_SEA_POSTER
|
||||
.2byte DECOR_SKY_POSTER
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_5F_EventScript_ClerkFarRight::
|
||||
lock
|
||||
@ -117,9 +111,7 @@ LilycoveCity_DepartmentStore_5F_Pokemart_Mats:
|
||||
.2byte DECOR_GLITTER_MAT
|
||||
.2byte DECOR_JUMP_MAT
|
||||
.2byte DECOR_SPIN_MAT
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
LilycoveCity_DepartmentStore_5F_EventScript_PokefanF::
|
||||
msgbox LilycoveCity_DepartmentStore_5F_Text_PlaceFullOfCuteDolls, MSGBOX_NPC
|
||||
|
||||
@ -25,9 +25,7 @@ MauvilleCity_Mart_Pokemart:
|
||||
.2byte ITEM_GUARD_SPEC
|
||||
.2byte ITEM_DIRE_HIT
|
||||
.2byte ITEM_X_ACCURACY
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
MauvilleCity_Mart_EventScript_ExpertM::
|
||||
msgbox MauvilleCity_Mart_Text_ItemsToTemporarilyElevateStats, MSGBOX_NPC
|
||||
|
||||
@ -22,9 +22,7 @@ MossdeepCity_Mart_Pokemart:
|
||||
.2byte ITEM_MAX_REPEL
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
MossdeepCity_Mart_EventScript_Woman::
|
||||
msgbox MossdeepCity_Mart_Text_ReviveIsFantastic, MSGBOX_NPC
|
||||
|
||||
@ -320,6 +320,9 @@ MossdeepCity_SpaceCenter_2F_EventScript_DefeatedMaxieTabitha::
|
||||
setobjectmovementtype LOCALID_SCIENTIST, MOVEMENT_TYPE_WANDER_AROUND
|
||||
addobject LOCALID_SCIENTIST
|
||||
fadescreen FADE_FROM_BLACK
|
||||
#ifdef BUGFIX
|
||||
releaseall
|
||||
#endif
|
||||
end
|
||||
|
||||
MossdeepCity_SpaceCenter_2F_EventScript_StevenFacePlayer::
|
||||
|
||||
@ -18,9 +18,7 @@ OldaleTown_Mart_Pokemart_Basic:
|
||||
.2byte ITEM_ANTIDOTE
|
||||
.2byte ITEM_PARALYZE_HEAL
|
||||
.2byte ITEM_AWAKENING
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
OldaleTown_Mart_ExpandedItems::
|
||||
pokemart OldaleTown_Mart_Pokemart_Expanded
|
||||
@ -35,9 +33,7 @@ OldaleTown_Mart_Pokemart_Expanded:
|
||||
.2byte ITEM_ANTIDOTE
|
||||
.2byte ITEM_PARALYZE_HEAL
|
||||
.2byte ITEM_AWAKENING
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
OldaleTown_Mart_EventScript_Woman::
|
||||
lock
|
||||
|
||||
@ -25,9 +25,7 @@ PetalburgCity_Mart_Pokemart_Basic:
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_ORANGE_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
PetalburgCity_Mart_EventScript_ExpandedItems::
|
||||
pokemart PetalburgCity_Mart_Pokemart_Expanded
|
||||
@ -50,9 +48,7 @@ PetalburgCity_Mart_Pokemart_Expanded:
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_ORANGE_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
PetalburgCity_Mart_EventScript_Woman::
|
||||
msgbox PetalburgCity_Mart_Text_WeakWillGrowStronger, MSGBOX_NPC
|
||||
|
||||
@ -59,9 +59,7 @@ Route104_PrettyPetalFlowerShop_Pokemart_Plants:
|
||||
.2byte DECOR_COLORFUL_PLANT
|
||||
.2byte DECOR_BIG_PLANT
|
||||
.2byte DECOR_GORGEOUS_PLANT
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
Route104_PrettyPetalFlowerShop_EventScript_WailmerPailGirl::
|
||||
lock
|
||||
|
||||
@ -518,28 +518,28 @@
|
||||
"x": 15,
|
||||
"y": 16,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_SOUTH_ENTRANCE",
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_NORTH_ENTRANCE",
|
||||
"dest_warp_id": "0"
|
||||
},
|
||||
{
|
||||
"x": 18,
|
||||
"y": 16,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_SOUTH_ENTRANCE",
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_NORTH_ENTRANCE",
|
||||
"dest_warp_id": "2"
|
||||
},
|
||||
{
|
||||
"x": 16,
|
||||
"y": 88,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_NORTH_ENTRANCE",
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_SOUTH_ENTRANCE",
|
||||
"dest_warp_id": "0"
|
||||
},
|
||||
{
|
||||
"x": 19,
|
||||
"y": 88,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_NORTH_ENTRANCE",
|
||||
"dest_map": "MAP_ROUTE110_SEASIDE_CYCLING_ROAD_SOUTH_ENTRANCE",
|
||||
"dest_warp_id": "2"
|
||||
}
|
||||
],
|
||||
|
||||
@ -34,28 +34,28 @@
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "4"
|
||||
"dest_warp_id": "2"
|
||||
},
|
||||
{
|
||||
"x": 2,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "4"
|
||||
"dest_warp_id": "2"
|
||||
},
|
||||
{
|
||||
"x": 12,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "5"
|
||||
"dest_warp_id": "3"
|
||||
},
|
||||
{
|
||||
"x": 13,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "5"
|
||||
"dest_warp_id": "3"
|
||||
}
|
||||
],
|
||||
"coord_events": [
|
||||
|
||||
@ -1,6 +1,16 @@
|
||||
Route110_SeasideCyclingRoadNorthEntrance_MapScripts::
|
||||
map_script MAP_SCRIPT_ON_TRANSITION, Route110_SeasideCyclingRoadNorthEntrance_OnTransition
|
||||
.byte 0
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_OnTransition:
|
||||
call_if_eq VAR_CYCLING_CHALLENGE_STATE, 3, Route110_SeasideCyclingRoadNorthEntrance_EventScript_RestartChallenge
|
||||
call_if_eq VAR_CYCLING_CHALLENGE_STATE, 2, Route110_SeasideCyclingRoadNorthEntrance_EventScript_RestartChallenge
|
||||
end
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_RestartChallenge::
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 1
|
||||
return
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_Clerk::
|
||||
lock
|
||||
faceplayer
|
||||
@ -11,12 +21,17 @@ Route110_SeasideCyclingRoadNorthEntrance_EventScript_Clerk::
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_BikeCheck::
|
||||
lockall
|
||||
specialvar VAR_RESULT, GetPlayerAvatarBike
|
||||
call_if_eq VAR_RESULT, 2, Route110_SeasideCyclingRoadNorthEntrance_EventScript_OnMachBike
|
||||
goto_if_eq VAR_RESULT, 0, Route110_SeasideCyclingRoadNorthEntrance_EventScript_NoBike
|
||||
setflag FLAG_SYS_CYCLING_ROAD
|
||||
setvar VAR_TEMP_1, 1
|
||||
releaseall
|
||||
end
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_OnMachBike::
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 1
|
||||
return
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_NoBike::
|
||||
msgbox Route110_SeasideCyclingRoadNorthEntrance_Text_TooDangerousToWalk, MSGBOX_DEFAULT
|
||||
closemessage
|
||||
@ -31,6 +46,7 @@ Route110_SeasideCyclingRoadNorthEntrance_Movement_PushPlayerBackFromCounter:
|
||||
|
||||
Route110_SeasideCyclingRoadNorthEntrance_EventScript_ClearCyclingRoad::
|
||||
lockall
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 0
|
||||
clearflag FLAG_SYS_CYCLING_ROAD
|
||||
setvar VAR_TEMP_1, 0
|
||||
releaseall
|
||||
|
||||
@ -34,28 +34,28 @@
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "2"
|
||||
"dest_warp_id": "4"
|
||||
},
|
||||
{
|
||||
"x": 2,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "2"
|
||||
"dest_warp_id": "4"
|
||||
},
|
||||
{
|
||||
"x": 12,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "3"
|
||||
"dest_warp_id": "5"
|
||||
},
|
||||
{
|
||||
"x": 13,
|
||||
"y": 5,
|
||||
"elevation": 0,
|
||||
"dest_map": "MAP_ROUTE110",
|
||||
"dest_warp_id": "3"
|
||||
"dest_warp_id": "5"
|
||||
}
|
||||
],
|
||||
"coord_events": [
|
||||
|
||||
@ -1,16 +1,6 @@
|
||||
Route110_SeasideCyclingRoadSouthEntrance_MapScripts::
|
||||
map_script MAP_SCRIPT_ON_TRANSITION, Route110_SeasideCyclingRoadSouthEntrance_OnTransition
|
||||
.byte 0
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_OnTransition:
|
||||
call_if_eq VAR_CYCLING_CHALLENGE_STATE, 3, Route110_SeasideCyclingRoadSouthEntrance_EventScript_RestartChallenge
|
||||
call_if_eq VAR_CYCLING_CHALLENGE_STATE, 2, Route110_SeasideCyclingRoadSouthEntrance_EventScript_RestartChallenge
|
||||
end
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_RestartChallenge::
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 1
|
||||
return
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_Clerk::
|
||||
lock
|
||||
faceplayer
|
||||
@ -21,17 +11,12 @@ Route110_SeasideCyclingRoadSouthEntrance_EventScript_Clerk::
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_BikeCheck::
|
||||
lockall
|
||||
specialvar VAR_RESULT, GetPlayerAvatarBike
|
||||
call_if_eq VAR_RESULT, 2, Route110_SeasideCyclingRoadSouthEntrance_EventScript_OnMachBike
|
||||
goto_if_eq VAR_RESULT, 0, Route110_SeasideCyclingRoadSouthEntrance_EventScript_NoBike
|
||||
setflag FLAG_SYS_CYCLING_ROAD
|
||||
setvar VAR_TEMP_1, 1
|
||||
releaseall
|
||||
end
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_OnMachBike::
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 1
|
||||
return
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_NoBike::
|
||||
msgbox Route110_SeasideCyclingRoadSouthEntrance_Text_TooDangerousToWalk, MSGBOX_DEFAULT
|
||||
closemessage
|
||||
@ -46,7 +31,6 @@ Route110_SeasideCyclingRoadSouthEntrance_Movement_PushPlayerBackFromCounter:
|
||||
|
||||
Route110_SeasideCyclingRoadSouthEntrance_EventScript_ClearCyclingRoad::
|
||||
lockall
|
||||
setvar VAR_CYCLING_CHALLENGE_STATE, 0
|
||||
clearflag FLAG_SYS_CYCLING_ROAD
|
||||
setvar VAR_TEMP_1, 0
|
||||
releaseall
|
||||
|
||||
@ -28,9 +28,7 @@ RustboroCity_Mart_Pokemart_Basic:
|
||||
.2byte ITEM_X_SPEED
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
RustboroCity_Mart_EventScript_PokemartExpanded::
|
||||
pokemart RustboroCity_Mart_Pokemart_Expanded
|
||||
@ -52,9 +50,7 @@ RustboroCity_Mart_Pokemart_Expanded:
|
||||
.2byte ITEM_X_SPEED
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
RustboroCity_Mart_EventScript_PokefanF::
|
||||
msgbox RustboroCity_Mart_Text_BuyingHealsInCaseOfShroomish, MSGBOX_NPC
|
||||
|
||||
@ -154,9 +154,7 @@ SlateportCity_Pokemart_EnergyGuru:
|
||||
.2byte ITEM_ZINC
|
||||
.2byte ITEM_CALCIUM
|
||||
.2byte ITEM_HP_UP
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
SlateportCity_EventScript_EffortRibbonWoman::
|
||||
lock
|
||||
@ -514,9 +512,7 @@ SlateportCity_PokemartDecor_Dolls:
|
||||
.2byte DECOR_AZURILL_DOLL
|
||||
.2byte DECOR_MARILL_DOLL
|
||||
.2byte DECOR_SKITTY_DOLL
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
SlateportCity_EventScript_ComeBackWithSecretPower::
|
||||
msgbox gText_ComeBackWithSecretPower, MSGBOX_DEFAULT
|
||||
@ -550,9 +546,7 @@ SlateportCity_PokemartDecor:
|
||||
.2byte DECOR_A_NOTE_MAT
|
||||
.2byte DECOR_B_NOTE_MAT
|
||||
.2byte DECOR_C_HIGH_NOTE_MAT
|
||||
.2byte DECOR_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
SlateportCity_EventScript_PowerTMClerk::
|
||||
lock
|
||||
@ -568,9 +562,7 @@ SlateportCity_EventScript_PowerTMClerk::
|
||||
SlateportCity_Pokemart_PowerTMs:
|
||||
.2byte ITEM_TM_HIDDEN_POWER
|
||||
.2byte ITEM_TM_SECRET_POWER
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
@ Scene with Capt Sterns interview and Team Aqua announcing plans to steal Submarine
|
||||
SlateportCity_EventScript_CaptStern::
|
||||
|
||||
@ -22,9 +22,7 @@ SlateportCity_Mart_Pokemart:
|
||||
.2byte ITEM_ESCAPE_ROPE
|
||||
.2byte ITEM_REPEL
|
||||
.2byte ITEM_HARBOR_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
SlateportCity_Mart_EventScript_BlackBelt::
|
||||
msgbox SlateportCity_Mart_Text_SomeItemsOnlyAtMart, MSGBOX_NPC
|
||||
|
||||
@ -22,9 +22,7 @@ SootopolisCity_Mart_Pokemart:
|
||||
.2byte ITEM_X_ATTACK
|
||||
.2byte ITEM_X_DEFEND
|
||||
.2byte ITEM_SHADOW_MAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
SootopolisCity_Mart_EventScript_FatMan::
|
||||
lock
|
||||
|
||||
@ -267,9 +267,7 @@ TrainerHill_Entrance_Pokemart_Basic:
|
||||
.2byte ITEM_DIRE_HIT
|
||||
.2byte ITEM_GUARD_SPEC
|
||||
.2byte ITEM_X_ACCURACY
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
TrainerHill_Entrance_EventScript_ExpandedPokemart::
|
||||
pokemart TrainerHill_Entrance_Pokemart_Expanded
|
||||
@ -291,9 +289,7 @@ TrainerHill_Entrance_Pokemart_Expanded:
|
||||
.2byte ITEM_DIRE_HIT
|
||||
.2byte ITEM_GUARD_SPEC
|
||||
.2byte ITEM_X_ACCURACY
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
TrainerHill_Entrance_Text_StillGettingReady:
|
||||
.string "This is the TRAINER HILL where\n"
|
||||
|
||||
@ -24,9 +24,7 @@ VerdanturfTown_Mart_Pokemart:
|
||||
.2byte ITEM_REPEL
|
||||
.2byte ITEM_X_SPECIAL
|
||||
.2byte ITEM_FLUFFY_TAIL
|
||||
.2byte ITEM_NONE
|
||||
release
|
||||
end
|
||||
pokemartlistend
|
||||
|
||||
VerdanturfTown_Mart_EventScript_Boy::
|
||||
msgbox VerdanturfTown_Mart_Text_XSpecialIsCrucial, MSGBOX_NPC
|
||||
|
||||
@ -605,8 +605,8 @@
|
||||
"Route110_TrickHousePuzzle6",
|
||||
"Route110_TrickHousePuzzle7",
|
||||
"Route110_TrickHousePuzzle8",
|
||||
"Route110_SeasideCyclingRoadNorthEntrance",
|
||||
"Route110_SeasideCyclingRoadSouthEntrance"
|
||||
"Route110_SeasideCyclingRoadSouthEntrance",
|
||||
"Route110_SeasideCyclingRoadNorthEntrance"
|
||||
],
|
||||
"gMapGroup_IndoorRoute113": [
|
||||
"Route113_GlassWorkshop"
|
||||
|
||||
@ -1,233 +1,250 @@
|
||||
.ifndef SCRIPT_CMD_TABLE_ENTRY_MACRO
|
||||
.set SCRIPT_CMD_TABLE_ENTRY_MACRO, 1
|
||||
.macro script_cmd_table_entry constant:req value:req
|
||||
.if ALLOCATE_SCRIPT_CMD_TABLE
|
||||
.4byte \value
|
||||
.else
|
||||
enum \constant
|
||||
.endif
|
||||
.endm
|
||||
.endif
|
||||
|
||||
|
||||
enum_start
|
||||
.if ALLOCATE_SCRIPT_CMD_TABLE
|
||||
.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_givemon @ 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_setmonmodernfatefulencounter @ 0xcd
|
||||
.4byte ScrCmd_checkmonmodernfatefulencounter @ 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_callfunc @ 0xe3
|
||||
.endif
|
||||
script_cmd_table_entry SCR_OP_NOP ScrCmd_nop @ 0x00
|
||||
script_cmd_table_entry SCR_OP_NOP1 ScrCmd_nop1 @ 0x01
|
||||
script_cmd_table_entry SCR_OP_END ScrCmd_end @ 0x02
|
||||
script_cmd_table_entry SCR_OP_RETURN ScrCmd_return @ 0x03
|
||||
script_cmd_table_entry SCR_OP_CALL ScrCmd_call @ 0x04
|
||||
script_cmd_table_entry SCR_OP_GOTO ScrCmd_goto @ 0x05
|
||||
script_cmd_table_entry SCR_OP_GOTO_IF ScrCmd_goto_if @ 0x06
|
||||
script_cmd_table_entry SCR_OP_CALL_IF ScrCmd_call_if @ 0x07
|
||||
script_cmd_table_entry SCR_OP_GOTO_STD ScrCmd_gotostd @ 0x08
|
||||
script_cmd_table_entry SCR_OP_CALL_STD ScrCmd_callstd @ 0x09
|
||||
script_cmd_table_entry SCR_OP_GOTO_STD_IF ScrCmd_gotostd_if @ 0x0a
|
||||
script_cmd_table_entry SCR_OP_CALL_STD_IF ScrCmd_callstd_if @ 0x0b
|
||||
script_cmd_table_entry SCR_OP_RETURNRAM ScrCmd_returnram @ 0x0c
|
||||
script_cmd_table_entry SCR_OP_ENDRAM ScrCmd_endram @ 0x0d
|
||||
script_cmd_table_entry SCR_OP_SETMYSTERYEVENTSTATUS ScrCmd_setmysteryeventstatus @ 0x0e
|
||||
script_cmd_table_entry SCR_OP_LOAD_WORD ScrCmd_loadword @ 0x0f
|
||||
script_cmd_table_entry SCR_OP_LOAD_BYTE ScrCmd_loadbyte @ 0x10
|
||||
script_cmd_table_entry SCR_OP_SETPTR ScrCmd_setptr @ 0x11
|
||||
script_cmd_table_entry SCR_OP_LOADBYTEFROMPTR ScrCmd_loadbytefromptr @ 0x12
|
||||
script_cmd_table_entry SCR_OP_SETPTRBYTE ScrCmd_setptrbyte @ 0x13
|
||||
script_cmd_table_entry SCR_OP_COPYLOCAL ScrCmd_copylocal @ 0x14
|
||||
script_cmd_table_entry SCR_OP_COPYBYTE ScrCmd_copybyte @ 0x15
|
||||
script_cmd_table_entry SCR_OP_SETVAR ScrCmd_setvar @ 0x16
|
||||
script_cmd_table_entry SCR_OP_ADDVAR ScrCmd_addvar @ 0x17
|
||||
script_cmd_table_entry SCR_OP_SUBVAR ScrCmd_subvar @ 0x18
|
||||
script_cmd_table_entry SCR_OP_COPYVAR ScrCmd_copyvar @ 0x19
|
||||
script_cmd_table_entry SCR_OP_SETORCOPYVAR ScrCmd_setorcopyvar @ 0x1a
|
||||
script_cmd_table_entry SCR_OP_COMPARE_LOCAL_TO_LOCAL ScrCmd_compare_local_to_local @ 0x1b
|
||||
script_cmd_table_entry SCR_OP_COMPARE_LOCAL_TO_VALUE ScrCmd_compare_local_to_value @ 0x1c
|
||||
script_cmd_table_entry SCR_OP_COMPARE_LOCAL_TO_PTR ScrCmd_compare_local_to_ptr @ 0x1d
|
||||
script_cmd_table_entry SCR_OP_COMPARE_PTR_TO_LOCAL ScrCmd_compare_ptr_to_local @ 0x1e
|
||||
script_cmd_table_entry SCR_OP_COMPARE_PTR_TO_VALUE ScrCmd_compare_ptr_to_value @ 0x1f
|
||||
script_cmd_table_entry SCR_OP_COMPARE_PTR_TO_PTR ScrCmd_compare_ptr_to_ptr @ 0x20
|
||||
script_cmd_table_entry SCR_OP_COMPARE_VAR_TO_VALUE ScrCmd_compare_var_to_value @ 0x21
|
||||
script_cmd_table_entry SCR_OP_COMPARE_VAR_TO_VAR ScrCmd_compare_var_to_var @ 0x22
|
||||
script_cmd_table_entry SCR_OP_CALLNATIVE ScrCmd_callnative @ 0x23
|
||||
script_cmd_table_entry SCR_OP_GOTONATIVE ScrCmd_gotonative @ 0x24
|
||||
script_cmd_table_entry SCR_OP_SPECIAL ScrCmd_special @ 0x25
|
||||
script_cmd_table_entry SCR_OP_SPECIALVAR ScrCmd_specialvar @ 0x26
|
||||
script_cmd_table_entry SCR_OP_WAITSTATE ScrCmd_waitstate @ 0x27
|
||||
script_cmd_table_entry SCR_OP_DELAY ScrCmd_delay @ 0x28
|
||||
script_cmd_table_entry SCR_OP_SETFLAG ScrCmd_setflag @ 0x29
|
||||
script_cmd_table_entry SCR_OP_CLEARFLAG ScrCmd_clearflag @ 0x2a
|
||||
script_cmd_table_entry SCR_OP_CHECKFLAG ScrCmd_checkflag @ 0x2b
|
||||
script_cmd_table_entry SCR_OP_INITCLOCK ScrCmd_initclock @ 0x2c
|
||||
script_cmd_table_entry SCR_OP_DOTIMEBASEDEVENTS ScrCmd_dotimebasedevents @ 0x2d
|
||||
script_cmd_table_entry SCR_OP_GETTIME ScrCmd_gettime @ 0x2e
|
||||
script_cmd_table_entry SCR_OP_PLAYSE ScrCmd_playse @ 0x2f
|
||||
script_cmd_table_entry SCR_OP_WAITSE ScrCmd_waitse @ 0x30
|
||||
script_cmd_table_entry SCR_OP_PLAYFANFARE ScrCmd_playfanfare @ 0x31
|
||||
script_cmd_table_entry SCR_OP_WAITFANFARE ScrCmd_waitfanfare @ 0x32
|
||||
script_cmd_table_entry SCR_OP_PLAYBGM ScrCmd_playbgm @ 0x33
|
||||
script_cmd_table_entry SCR_OP_SAVEBGM ScrCmd_savebgm @ 0x34
|
||||
script_cmd_table_entry SCR_OP_FADEDEFAULTBGM ScrCmd_fadedefaultbgm @ 0x35
|
||||
script_cmd_table_entry SCR_OP_FADENEWBGM ScrCmd_fadenewbgm @ 0x36
|
||||
script_cmd_table_entry SCR_OP_FADEOUTBGM ScrCmd_fadeoutbgm @ 0x37
|
||||
script_cmd_table_entry SCR_OP_FADEINBGM ScrCmd_fadeinbgm @ 0x38
|
||||
script_cmd_table_entry SCR_OP_WARP ScrCmd_warp @ 0x39
|
||||
script_cmd_table_entry SCR_OP_WARPSILENT ScrCmd_warpsilent @ 0x3a
|
||||
script_cmd_table_entry SCR_OP_WARPDOOR ScrCmd_warpdoor @ 0x3b
|
||||
script_cmd_table_entry SCR_OP_WARPHOLE ScrCmd_warphole @ 0x3c
|
||||
script_cmd_table_entry SCR_OP_WARPTELEPORT ScrCmd_warpteleport @ 0x3d
|
||||
script_cmd_table_entry SCR_OP_SETWARP ScrCmd_setwarp @ 0x3e
|
||||
script_cmd_table_entry SCR_OP_SETDYNAMICWARP ScrCmd_setdynamicwarp @ 0x3f
|
||||
script_cmd_table_entry SCR_OP_SETDIVEWARP ScrCmd_setdivewarp @ 0x40
|
||||
script_cmd_table_entry SCR_OP_SETHOLEWARP ScrCmd_setholewarp @ 0x41
|
||||
script_cmd_table_entry SCR_OP_GETPLAYERXY ScrCmd_getplayerxy @ 0x42
|
||||
script_cmd_table_entry SCR_OP_GETPARTYSIZE ScrCmd_getpartysize @ 0x43
|
||||
script_cmd_table_entry SCR_OP_ADDITEM ScrCmd_additem @ 0x44
|
||||
script_cmd_table_entry SCR_OP_REMOVEITEM ScrCmd_removeitem @ 0x45
|
||||
script_cmd_table_entry SCR_OP_CHECKITEMSPACE ScrCmd_checkitemspace @ 0x46
|
||||
script_cmd_table_entry SCR_OP_CHECKITEM ScrCmd_checkitem @ 0x47
|
||||
script_cmd_table_entry SCR_OP_CHECKITEMTYPE ScrCmd_checkitemtype @ 0x48
|
||||
script_cmd_table_entry SCR_OP_ADDPCITEM ScrCmd_addpcitem @ 0x49
|
||||
script_cmd_table_entry SCR_OP_CHECKPCITEM ScrCmd_checkpcitem @ 0x4a
|
||||
script_cmd_table_entry SCR_OP_ADDDECORATION ScrCmd_adddecoration @ 0x4b
|
||||
script_cmd_table_entry SCR_OP_REMOVEDECORATION ScrCmd_removedecoration @ 0x4c
|
||||
script_cmd_table_entry SCR_OP_CHECKDECOR ScrCmd_checkdecor @ 0x4d
|
||||
script_cmd_table_entry SCR_OP_CHECKDECORSPACE ScrCmd_checkdecorspace @ 0x4e
|
||||
script_cmd_table_entry SCR_OP_APPLYMOVEMENT ScrCmd_applymovement @ 0x4f
|
||||
script_cmd_table_entry SCR_OP_APPLYMOVEMENTAT ScrCmd_applymovementat @ 0x50
|
||||
script_cmd_table_entry SCR_OP_WAITMOVEMENT ScrCmd_waitmovement @ 0x51
|
||||
script_cmd_table_entry SCR_OP_WAITMOVEMENTAT ScrCmd_waitmovementat @ 0x52
|
||||
script_cmd_table_entry SCR_OP_REMOVEOBJECT ScrCmd_removeobject @ 0x53
|
||||
script_cmd_table_entry SCR_OP_REMOVEOBJECTAT ScrCmd_removeobjectat @ 0x54
|
||||
script_cmd_table_entry SCR_OP_ADDOBJECT ScrCmd_addobject @ 0x55
|
||||
script_cmd_table_entry SCR_OP_ADDOBJECTAT ScrCmd_addobjectat @ 0x56
|
||||
script_cmd_table_entry SCR_OP_SETOBJECTXY ScrCmd_setobjectxy @ 0x57
|
||||
script_cmd_table_entry SCR_OP_SHOWOBJECTAT ScrCmd_showobjectat @ 0x58
|
||||
script_cmd_table_entry SCR_OP_HIDEOBJECTAT ScrCmd_hideobjectat @ 0x59
|
||||
script_cmd_table_entry SCR_OP_FACEPLAYER ScrCmd_faceplayer @ 0x5a
|
||||
script_cmd_table_entry SCR_OP_TURNOBJECT ScrCmd_turnobject @ 0x5b
|
||||
script_cmd_table_entry SCR_OP_TRAINERBATTLE ScrCmd_trainerbattle @ 0x5c
|
||||
script_cmd_table_entry SCR_OP_DOTRAINERBATTLE ScrCmd_dotrainerbattle @ 0x5d
|
||||
script_cmd_table_entry SCR_OP_GOTOPOSTBATTLESCRIPT ScrCmd_gotopostbattlescript @ 0x5e
|
||||
script_cmd_table_entry SCR_OP_GOTOBEATENSCRIPT ScrCmd_gotobeatenscript @ 0x5f
|
||||
script_cmd_table_entry SCR_OP_CHECKTRAINERFLAG ScrCmd_checktrainerflag @ 0x60
|
||||
script_cmd_table_entry SCR_OP_SETTRAINERFLAG ScrCmd_settrainerflag @ 0x61
|
||||
script_cmd_table_entry SCR_OP_CLEARTRAINERFLAG ScrCmd_cleartrainerflag @ 0x62
|
||||
script_cmd_table_entry SCR_OP_SETOBJECTXYPERM ScrCmd_setobjectxyperm @ 0x63
|
||||
script_cmd_table_entry SCR_OP_COPYOBJECTXYTOPERM ScrCmd_copyobjectxytoperm @ 0x64
|
||||
script_cmd_table_entry SCR_OP_SETOBJECTMOVEMENTTYPE ScrCmd_setobjectmovementtype @ 0x65
|
||||
script_cmd_table_entry SCR_OP_WAITMESSAGE ScrCmd_waitmessage @ 0x66
|
||||
script_cmd_table_entry SCR_OP_MESSAGE ScrCmd_message @ 0x67
|
||||
script_cmd_table_entry SCR_OP_CLOSEMESSAGE ScrCmd_closemessage @ 0x68
|
||||
script_cmd_table_entry SCR_OP_LOCKALL ScrCmd_lockall @ 0x69
|
||||
script_cmd_table_entry SCR_OP_LOCK ScrCmd_lock @ 0x6a
|
||||
script_cmd_table_entry SCR_OP_RELEASEALL ScrCmd_releaseall @ 0x6b
|
||||
script_cmd_table_entry SCR_OP_RELEASE ScrCmd_release @ 0x6c
|
||||
script_cmd_table_entry SCR_OP_WAITBUTTONPRESS ScrCmd_waitbuttonpress @ 0x6d
|
||||
script_cmd_table_entry SCR_OP_YESNOBOX ScrCmd_yesnobox @ 0x6e
|
||||
script_cmd_table_entry SCR_OP_MULTICHOICE ScrCmd_multichoice @ 0x6f
|
||||
script_cmd_table_entry SCR_OP_MULTICHOICEDEFAULT ScrCmd_multichoicedefault @ 0x70
|
||||
script_cmd_table_entry SCR_OP_MULTICHOICEGRID ScrCmd_multichoicegrid @ 0x71
|
||||
script_cmd_table_entry SCR_OP_DRAWBOX ScrCmd_drawbox @ 0x72
|
||||
script_cmd_table_entry SCR_OP_ERASEBOX ScrCmd_erasebox @ 0x73
|
||||
script_cmd_table_entry SCR_OP_DRAWBOXTEXT ScrCmd_drawboxtext @ 0x74
|
||||
script_cmd_table_entry SCR_OP_SHOWMONPIC ScrCmd_showmonpic @ 0x75
|
||||
script_cmd_table_entry SCR_OP_HIDEMONPIC ScrCmd_hidemonpic @ 0x76
|
||||
script_cmd_table_entry SCR_OP_SHOWCONTESTPAINTING ScrCmd_showcontestpainting @ 0x77
|
||||
script_cmd_table_entry SCR_OP_BRAILLEMESSAGE ScrCmd_braillemessage @ 0x78
|
||||
script_cmd_table_entry SCR_OP_GIVEMON ScrCmd_givemon @ 0x79
|
||||
script_cmd_table_entry SCR_OP_GIVEEGG ScrCmd_giveegg @ 0x7a
|
||||
script_cmd_table_entry SCR_OP_SETMONMOVE ScrCmd_setmonmove @ 0x7b
|
||||
script_cmd_table_entry SCR_OP_CHECKPARTYMOVE ScrCmd_checkpartymove @ 0x7c
|
||||
script_cmd_table_entry SCR_OP_BUFFERSPECIESNAME ScrCmd_bufferspeciesname @ 0x7d
|
||||
script_cmd_table_entry SCR_OP_BUFFERLEADMONSPECIESNAME ScrCmd_bufferleadmonspeciesname @ 0x7e
|
||||
script_cmd_table_entry SCR_OP_BUFFERPARTYMONNICK ScrCmd_bufferpartymonnick @ 0x7f
|
||||
script_cmd_table_entry SCR_OP_BUFFERITEMNAME ScrCmd_bufferitemname @ 0x80
|
||||
script_cmd_table_entry SCR_OP_BUFFERDECORATIONNAME ScrCmd_bufferdecorationname @ 0x81
|
||||
script_cmd_table_entry SCR_OP_BUFFERMOVENAME ScrCmd_buffermovename @ 0x82
|
||||
script_cmd_table_entry SCR_OP_BUFFERNUMBERSTRING ScrCmd_buffernumberstring @ 0x83
|
||||
script_cmd_table_entry SCR_OP_BUFFERSTDSTRING ScrCmd_bufferstdstring @ 0x84
|
||||
script_cmd_table_entry SCR_OP_BUFFERSTRING ScrCmd_bufferstring @ 0x85
|
||||
script_cmd_table_entry SCR_OP_POKEMART ScrCmd_pokemart @ 0x86
|
||||
script_cmd_table_entry SCR_OP_POKEMARTDECORATION ScrCmd_pokemartdecoration @ 0x87
|
||||
script_cmd_table_entry SCR_OP_POKEMARTDECORATION2 ScrCmd_pokemartdecoration2 @ 0x88
|
||||
script_cmd_table_entry SCR_OP_PLAYSLOTMACHINE ScrCmd_playslotmachine @ 0x89
|
||||
script_cmd_table_entry SCR_OP_SETBERRYTREE ScrCmd_setberrytree @ 0x8a
|
||||
script_cmd_table_entry SCR_OP_CHOOSECONTESTMON ScrCmd_choosecontestmon @ 0x8b
|
||||
script_cmd_table_entry SCR_OP_STARTCONTEST ScrCmd_startcontest @ 0x8c
|
||||
script_cmd_table_entry SCR_OP_SHOWCONTESTRESULTS ScrCmd_showcontestresults @ 0x8d
|
||||
script_cmd_table_entry SCR_OP_CONTESTLINKTRANSFER ScrCmd_contestlinktransfer @ 0x8e
|
||||
script_cmd_table_entry SCR_OP_RANDOM ScrCmd_random @ 0x8f
|
||||
script_cmd_table_entry SCR_OP_ADDMONEY ScrCmd_addmoney @ 0x90
|
||||
script_cmd_table_entry SCR_OP_REMOVEMONEY ScrCmd_removemoney @ 0x91
|
||||
script_cmd_table_entry SCR_OP_CHECKMONEY ScrCmd_checkmoney @ 0x92
|
||||
script_cmd_table_entry SCR_OP_SHOWMONEYBOX ScrCmd_showmoneybox @ 0x93
|
||||
script_cmd_table_entry SCR_OP_HIDEMONEYBOX ScrCmd_hidemoneybox @ 0x94
|
||||
script_cmd_table_entry SCR_OP_UPDATEMONEYBOX ScrCmd_updatemoneybox @ 0x95
|
||||
script_cmd_table_entry SCR_OP_GETPOKENEWSACTIVE ScrCmd_getpokenewsactive @ 0x96
|
||||
script_cmd_table_entry SCR_OP_FADESCREEN ScrCmd_fadescreen @ 0x97
|
||||
script_cmd_table_entry SCR_OP_FADESCREENSPEED ScrCmd_fadescreenspeed @ 0x98
|
||||
script_cmd_table_entry SCR_OP_SETFLASHLEVEL ScrCmd_setflashlevel @ 0x99
|
||||
script_cmd_table_entry SCR_OP_ANIMATEFLASH ScrCmd_animateflash @ 0x9a
|
||||
script_cmd_table_entry SCR_OP_MESSAGEAUTOSCROLL ScrCmd_messageautoscroll @ 0x9b
|
||||
script_cmd_table_entry SCR_OP_DOFIELDEFFECT ScrCmd_dofieldeffect @ 0x9c
|
||||
script_cmd_table_entry SCR_OP_SETFIELDEFFECTARGUMENT ScrCmd_setfieldeffectargument @ 0x9d
|
||||
script_cmd_table_entry SCR_OP_WAITFIELDEFFECT ScrCmd_waitfieldeffect @ 0x9e
|
||||
script_cmd_table_entry SCR_OP_SETRESPAWN ScrCmd_setrespawn @ 0x9f
|
||||
script_cmd_table_entry SCR_OP_CHECKPLAYERGENDER ScrCmd_checkplayergender @ 0xa0
|
||||
script_cmd_table_entry SCR_OP_PLAYMONCRY ScrCmd_playmoncry @ 0xa1
|
||||
script_cmd_table_entry SCR_OP_SETMETATILE ScrCmd_setmetatile @ 0xa2
|
||||
script_cmd_table_entry SCR_OP_RESETWEATHER ScrCmd_resetweather @ 0xa3
|
||||
script_cmd_table_entry SCR_OP_SETWEATHER ScrCmd_setweather @ 0xa4
|
||||
script_cmd_table_entry SCR_OP_DOWEATHER ScrCmd_doweather @ 0xa5
|
||||
script_cmd_table_entry SCR_OP_SETSTEPCALLBACK ScrCmd_setstepcallback @ 0xa6
|
||||
script_cmd_table_entry SCR_OP_SETMAPLAYOUTINDEX ScrCmd_setmaplayoutindex @ 0xa7
|
||||
script_cmd_table_entry SCR_OP_SETOBJECTSUBPRIORITY ScrCmd_setobjectsubpriority @ 0xa8
|
||||
script_cmd_table_entry SCR_OP_RESETOBJECTSUBPRIORITY ScrCmd_resetobjectsubpriority @ 0xa9
|
||||
script_cmd_table_entry SCR_OP_CREATEVOBJECT ScrCmd_createvobject @ 0xaa
|
||||
script_cmd_table_entry SCR_OP_TURNVOBJECT ScrCmd_turnvobject @ 0xab
|
||||
script_cmd_table_entry SCR_OP_OPENDOOR ScrCmd_opendoor @ 0xac
|
||||
script_cmd_table_entry SCR_OP_CLOSEDOOR ScrCmd_closedoor @ 0xad
|
||||
script_cmd_table_entry SCR_OP_WAITDOORANIM ScrCmd_waitdooranim @ 0xae
|
||||
script_cmd_table_entry SCR_OP_SETDOOROPEN ScrCmd_setdooropen @ 0xaf
|
||||
script_cmd_table_entry SCR_OP_SETDOORCLOSED ScrCmd_setdoorclosed @ 0xb0
|
||||
script_cmd_table_entry SCR_OP_ADDELEVMENUITEM ScrCmd_addelevmenuitem @ 0xb1
|
||||
script_cmd_table_entry SCR_OP_SHOWELEVMENU ScrCmd_showelevmenu @ 0xb2
|
||||
script_cmd_table_entry SCR_OP_CHECKCOINS ScrCmd_checkcoins @ 0xb3
|
||||
script_cmd_table_entry SCR_OP_ADDCOINS ScrCmd_addcoins @ 0xb4
|
||||
script_cmd_table_entry SCR_OP_REMOVECOINS ScrCmd_removecoins @ 0xb5
|
||||
script_cmd_table_entry SCR_OP_SETWILDBATTLE ScrCmd_setwildbattle @ 0xb6
|
||||
script_cmd_table_entry SCR_OP_DOWILDBATTLE ScrCmd_dowildbattle @ 0xb7
|
||||
script_cmd_table_entry SCR_OP_SETVADDRESS ScrCmd_setvaddress @ 0xb8
|
||||
script_cmd_table_entry SCR_OP_VGOTO ScrCmd_vgoto @ 0xb9
|
||||
script_cmd_table_entry SCR_OP_VCALL ScrCmd_vcall @ 0xba
|
||||
script_cmd_table_entry SCR_OP_VGOTO_IF ScrCmd_vgoto_if @ 0xbb
|
||||
script_cmd_table_entry SCR_OP_VCALL_IF ScrCmd_vcall_if @ 0xbc
|
||||
script_cmd_table_entry SCR_OP_VMESSAGE ScrCmd_vmessage @ 0xbd
|
||||
script_cmd_table_entry SCR_OP_VBUFFERMESSAGE ScrCmd_vbuffermessage @ 0xbe
|
||||
script_cmd_table_entry SCR_OP_VBUFFERSTRING ScrCmd_vbufferstring @ 0xbf
|
||||
script_cmd_table_entry SCR_OP_SHOWCOINSBOX ScrCmd_showcoinsbox @ 0xc0
|
||||
script_cmd_table_entry SCR_OP_HIDECOINSBOX ScrCmd_hidecoinsbox @ 0xc1
|
||||
script_cmd_table_entry SCR_OP_UPDATECOINSBOX ScrCmd_updatecoinsbox @ 0xc2
|
||||
script_cmd_table_entry SCR_OP_INCREMENTGAMESTAT ScrCmd_incrementgamestat @ 0xc3
|
||||
script_cmd_table_entry SCR_OP_SETESCAPEWARP ScrCmd_setescapewarp @ 0xc4
|
||||
script_cmd_table_entry SCR_OP_WAITMONCRY ScrCmd_waitmoncry @ 0xc5
|
||||
script_cmd_table_entry SCR_OP_BUFFERBOXNAME ScrCmd_bufferboxname @ 0xc6
|
||||
script_cmd_table_entry SCR_OP_TEXTCOLOR ScrCmd_nop1 @ 0xc7
|
||||
script_cmd_table_entry SCR_OP_LOADHELP ScrCmd_nop1 @ 0xc8
|
||||
script_cmd_table_entry SCR_OP_UNLOADHELP ScrCmd_nop1 @ 0xc9
|
||||
script_cmd_table_entry SCR_OP_SIGNMSG ScrCmd_nop1 @ 0xca
|
||||
script_cmd_table_entry SCR_OP_NORMALMSG ScrCmd_nop1 @ 0xcb
|
||||
script_cmd_table_entry SCR_OP_COMPAREHIDDENVAR ScrCmd_nop1 @ 0xcc
|
||||
script_cmd_table_entry SCR_OP_SETMODERNFATEFULENCOUNTER ScrCmd_setmodernfatefulencounter @ 0xcd
|
||||
script_cmd_table_entry SCR_OP_CHECKMODERNFATEFULENCOUNTER ScrCmd_checkmodernfatefulencounter @ 0xce
|
||||
script_cmd_table_entry SCR_OP_TRYWONDERCARDSCRIPT ScrCmd_trywondercardscript @ 0xcf
|
||||
script_cmd_table_entry SCR_OP_SETWORLDMAPFLAG ScrCmd_nop1 @ 0xd0
|
||||
script_cmd_table_entry SCR_OP_WARPSPINENTER ScrCmd_warpspinenter @ 0xd1
|
||||
script_cmd_table_entry SCR_OP_SETMONMETLOCATION ScrCmd_setmonmetlocation @ 0xd2
|
||||
script_cmd_table_entry SCR_OP_MOVEROTATINGTILEOBJECTS ScrCmd_moverotatingtileobjects @ 0xd3
|
||||
script_cmd_table_entry SCR_OP_TURNROTATINGTILEOBJECTS ScrCmd_turnrotatingtileobjects @ 0xd4
|
||||
script_cmd_table_entry SCR_OP_INITROTATINGTILEPUZZLE ScrCmd_initrotatingtilepuzzle @ 0xd5
|
||||
script_cmd_table_entry SCR_OP_FREEROTATINGTILEPUZZLE ScrCmd_freerotatingtilepuzzle @ 0xd6
|
||||
script_cmd_table_entry SCR_OP_WARPMOSSDEEPGYM ScrCmd_warpmossdeepgym @ 0xd7
|
||||
script_cmd_table_entry SCR_OP_SELECTAPPROACHINGTRAINER ScrCmd_selectapproachingtrainer @ 0xd8
|
||||
script_cmd_table_entry SCR_OP_LOCKFORTRAINER ScrCmd_lockfortrainer @ 0xd9
|
||||
script_cmd_table_entry SCR_OP_CLOSEBRAILLEMESSAGE ScrCmd_closebraillemessage @ 0xda
|
||||
script_cmd_table_entry SCR_OP_MESSAGEINSTANT ScrCmd_messageinstant @ 0xdb
|
||||
script_cmd_table_entry SCR_OP_FADESCREENSWAPBUFFERS ScrCmd_fadescreenswapbuffers @ 0xdc
|
||||
script_cmd_table_entry SCR_OP_BUFFERTRAINERCLASSNAME ScrCmd_buffertrainerclassname @ 0xdd
|
||||
script_cmd_table_entry SCR_OP_BUFFERTRAINERNAME ScrCmd_buffertrainername @ 0xde
|
||||
script_cmd_table_entry SCR_OP_POKENAVCALL ScrCmd_pokenavcall @ 0xdf
|
||||
script_cmd_table_entry SCR_OP_WARPWHITEFADE ScrCmd_warpwhitefade @ 0xe0
|
||||
script_cmd_table_entry SCR_OP_BUFFERCONTESTNAME ScrCmd_buffercontestname @ 0xe1
|
||||
script_cmd_table_entry SCR_OP_BUFFERITEMNAMEPLURAL ScrCmd_bufferitemnameplural @ 0xe2
|
||||
script_cmd_table_entry SCR_OP_CALLFUNC ScrCmd_callfunc @ 0xe3
|
||||
|
||||
.if ALLOCATE_SCRIPT_CMD_TABLE
|
||||
gScriptCmdTableEnd::
|
||||
.4byte ScrCmd_nop
|
||||
.endif
|
||||
|
||||
@ -18,7 +18,7 @@ MauvilleCity_PokemonCenter_1F_EventScript_Bard::
|
||||
end
|
||||
|
||||
MauvilleCity_PokemonCenter_1F_EventScript_PlaySong::
|
||||
setvar VAR_0x8004, 0
|
||||
setvar VAR_0x8004, FALSE @ Play his current song
|
||||
special PlayBardSong
|
||||
delay 60
|
||||
special HasBardSongBeenChanged
|
||||
@ -45,7 +45,7 @@ MauvilleCity_PokemonCenter_1F_EventScript_WriteLyrics::
|
||||
faceplayer
|
||||
goto_if_eq VAR_RESULT, 0, MauvilleCity_PokemonCenter_1F_EventScript_DeclineWritingLyrics
|
||||
msgbox MauvilleCity_PokemonCenter_1F_Text_LetMeSingItForYou, MSGBOX_DEFAULT
|
||||
setvar VAR_0x8004, 1
|
||||
setvar VAR_0x8004, TRUE @ Play the new song
|
||||
special PlayBardSong
|
||||
delay 60
|
||||
msgbox MauvilleCity_PokemonCenter_1F_Text_ThatHowYouWantedSongToGo, MSGBOX_YESNO
|
||||
|
||||
@ -53,6 +53,9 @@ SafariZone_EventScript_ChoosePokeblock::
|
||||
special OpenPokeblockCaseOnFeeder
|
||||
waitstate
|
||||
goto_if_ne VAR_RESULT, 0xFFFF, SafariZone_EventScript_PokeblockPlaced
|
||||
#ifdef BUGFIX
|
||||
releaseall @ Only gets called from EventScript_PokeBlockFeeder which uses lockall.
|
||||
#endif
|
||||
end
|
||||
|
||||
SafariZone_EventScript_PokeblockPlaced::
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
8
|
||||
16
|
||||
255 255 164
|
||||
255 255 106
|
||||
222 222 90
|
||||
@ -9,3 +9,11 @@ JASC-PAL
|
||||
123 123 49
|
||||
90 90 32
|
||||
57 57 16
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
0 0 0
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
8
|
||||
16
|
||||
148 197 172
|
||||
16 16 16
|
||||
32 32 32
|
||||
@ -9,3 +9,11 @@ JASC-PAL
|
||||
82 82 82
|
||||
98 98 98
|
||||
115 115 115
|
||||
131 131 131
|
||||
148 148 148
|
||||
164 164 164
|
||||
180 180 180
|
||||
197 197 197
|
||||
213 213 213
|
||||
230 230 230
|
||||
255 255 255
|
||||
|
||||
@ -1,11 +0,0 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
8
|
||||
131 131 131
|
||||
148 148 148
|
||||
164 164 164
|
||||
180 180 180
|
||||
197 197 197
|
||||
213 213 213
|
||||
230 230 230
|
||||
255 255 255
|
||||
@ -1,6 +1,6 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
48
|
||||
96
|
||||
123 131 0
|
||||
255 255 255
|
||||
222 222 222
|
||||
@ -49,3 +49,51 @@ JASC-PAL
|
||||
49 139 255
|
||||
189 156 90
|
||||
0 0 0
|
||||
123 131 0
|
||||
255 255 255
|
||||
255 238 0
|
||||
255 189 0
|
||||
255 115 0
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
255 0 189
|
||||
49 213 74
|
||||
24 131 32
|
||||
189 156 90
|
||||
0 0 0
|
||||
123 131 0
|
||||
255 255 255
|
||||
197 32 32
|
||||
189 189 189
|
||||
164 164 164
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
189 0 0
|
||||
74 148 180
|
||||
8 90 131
|
||||
189 156 90
|
||||
0 0 0
|
||||
123 131 0
|
||||
255 255 255
|
||||
197 32 32
|
||||
189 189 189
|
||||
164 164 164
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
255 0 189
|
||||
180 205 246
|
||||
49 139 255
|
||||
189 156 90
|
||||
0 0 0
|
||||
|
||||
@ -1,51 +0,0 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
48
|
||||
123 131 0
|
||||
255 255 255
|
||||
255 238 0
|
||||
255 189 0
|
||||
255 115 0
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
255 0 189
|
||||
49 213 74
|
||||
24 131 32
|
||||
189 156 90
|
||||
0 0 0
|
||||
123 131 0
|
||||
255 255 255
|
||||
197 32 32
|
||||
189 189 189
|
||||
164 164 164
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
189 0 0
|
||||
74 148 180
|
||||
8 90 131
|
||||
189 156 90
|
||||
0 0 0
|
||||
123 131 0
|
||||
255 255 255
|
||||
197 32 32
|
||||
189 189 189
|
||||
164 164 164
|
||||
98 98 115
|
||||
41 57 65
|
||||
41 57 106
|
||||
0 0 41
|
||||
255 255 255
|
||||
238 246 57
|
||||
255 0 189
|
||||
180 205 246
|
||||
49 139 255
|
||||
189 156 90
|
||||
0 0 0
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
@ -22,6 +22,7 @@ POKEDEXGFXDIR := graphics/pokedex
|
||||
STARTERGFXDIR := graphics/starter_choose
|
||||
NAMINGGFXDIR := graphics/naming_screen
|
||||
SPINDAGFXDIR := graphics/pokemon/spinda/spots
|
||||
TITLESCREENGFXDIR := graphics/title_screen
|
||||
|
||||
types := normal fight flying poison ground rock bug ghost steel mystery fire water grass electric psychic ice dragon dark
|
||||
contest_types := cool beauty cute smart tough
|
||||
@ -298,9 +299,13 @@ $(FONTGFXDIR)/frlg_female.fwjpnfont: $(FONTGFXDIR)/japanese_frlg_female.png
|
||||
|
||||
|
||||
### Miscellaneous ###
|
||||
graphics/title_screen/pokemon_logo.gbapal: %.gbapal: %.pal
|
||||
|
||||
$(TITLESCREENGFXDIR)/pokemon_logo.gbapal: %.gbapal: %.pal
|
||||
$(GFX) $< $@ -num_colors 224
|
||||
|
||||
$(TITLESCREENGFXDIR)/emerald_version.8bpp: %.8bpp: %.png
|
||||
$(GFX) $< $@ -mwidth 8 -mheight 4
|
||||
|
||||
graphics/pokemon_jump/bg.4bpp: %.4bpp: %.png
|
||||
$(GFX) $< $@ -num_tiles 63 -Wnum_tiles
|
||||
|
||||
|
||||
@ -1,39 +1,49 @@
|
||||
#ifndef GUARD_BARD_MUSIC_H
|
||||
#define GUARD_BARD_MUSIC_H
|
||||
|
||||
struct BardSound
|
||||
// The maximum number of BardSoundTemplates/BardSounds there can be for each easy chat word.
|
||||
#define MAX_BARD_SOUNDS_PER_WORD 6
|
||||
|
||||
// The number of pitch tables there are for each pitch table size (see sPitchTables).
|
||||
#define NUM_BARD_PITCH_TABLES_PER_SIZE 5
|
||||
|
||||
// This struct describes which phoneme song to play for the sound, and whether to
|
||||
// make any adjustments to its length or volume. Very few sounds make any adjustments.
|
||||
struct BardSoundTemplate
|
||||
{
|
||||
/*0x00*/ u8 songLengthId;
|
||||
/*0x01*/ s8 songLengthOffset;
|
||||
/*0x02*/ u16 unused;
|
||||
/*0x04*/ s16 volume;
|
||||
/*0x06*/ u16 unused2;
|
||||
u8 songId;
|
||||
s8 lengthAdjustment;
|
||||
u16 unused; // Only set on EC_WORD_WAAAH, and never read.
|
||||
s16 volume;
|
||||
};
|
||||
|
||||
struct BardPhoneme
|
||||
// This is the length and pitch to play the phoneme song at.
|
||||
// These will be calculated in 'CalcWordSounds'.
|
||||
struct BardSound
|
||||
{
|
||||
/*0x00*/ u16 length;
|
||||
/*0x02*/ u16 pitch;
|
||||
u16 length;
|
||||
u16 pitch;
|
||||
};
|
||||
|
||||
struct BardSong
|
||||
{
|
||||
/*0x00*/ u8 currWord;
|
||||
/*0x01*/ u8 currPhoneme;
|
||||
/*0x02*/ u8 phonemeTimer;
|
||||
/*0x03*/ u8 state;
|
||||
/*0x04*/ s16 length;
|
||||
/*0x06*/ u16 volume;
|
||||
/*0x08*/ s16 pitch;
|
||||
/*0x0A*/ s16 voiceInflection;
|
||||
/*0x0C*/ u16 lyrics[6];
|
||||
/*0x18*/ struct BardPhoneme phonemes[6];
|
||||
/*0x30*/ const struct BardSound *sound;
|
||||
u8 lyricsIndex;
|
||||
u8 soundIndex;
|
||||
u8 timer;
|
||||
u8 state;
|
||||
s16 length; // Length of the sound for the word currently being sung (i.e. the sum of 'length' in all the current word's phonemes).
|
||||
u16 volume;
|
||||
s16 pitch;
|
||||
s16 voiceInflection;
|
||||
u16 lyrics[NUM_BARD_SONG_WORDS];
|
||||
struct BardSound sounds[MAX_BARD_SOUNDS_PER_WORD];
|
||||
const struct BardSoundTemplate *soundTemplates;
|
||||
};
|
||||
|
||||
extern const u16 gNumBardWords_Species;
|
||||
extern const u16 gNumBardWords_Moves;
|
||||
const struct BardSound *GetWordSounds(u16 word);
|
||||
void GetWordPhonemes(struct BardSong *song, u16 word);
|
||||
|
||||
const struct BardSoundTemplate *GetWordSoundTemplates(u16 easyChatWord);
|
||||
void CalcWordSounds(struct BardSong *song, u16 pitchTableIndex);
|
||||
|
||||
#endif //GUARD_BARD_MUSIC_H
|
||||
|
||||
@ -460,26 +460,26 @@ STATIC_ASSERT(sizeof(((struct BattleStruct *)0)->palaceFlags) * 8 >= MAX_BATTLER
|
||||
typeArg = gBattleMoves[move].type; \
|
||||
}
|
||||
|
||||
#define IS_TYPE_PHYSICAL(moveType)(moveType < TYPE_MYSTERY)
|
||||
#define IS_TYPE_SPECIAL(moveType)(moveType > TYPE_MYSTERY)
|
||||
#define IS_TYPE_PHYSICAL(moveType) (moveType < TYPE_MYSTERY)
|
||||
#define IS_TYPE_SPECIAL(moveType) (moveType > TYPE_MYSTERY)
|
||||
|
||||
#define TARGET_TURN_DAMAGED ((gSpecialStatuses[gBattlerTarget].physicalDmg != 0 || gSpecialStatuses[gBattlerTarget].specialDmg != 0))
|
||||
|
||||
#define IS_BATTLER_OF_TYPE(battlerId, type)((gBattleMons[battlerId].type1 == type || gBattleMons[battlerId].type2 == type))
|
||||
#define IS_BATTLER_OF_TYPE(battlerId, type) ((gBattleMons[battlerId].types[0] == type || gBattleMons[battlerId].types[1] == type))
|
||||
#define SET_BATTLER_TYPE(battlerId, type) \
|
||||
{ \
|
||||
gBattleMons[battlerId].type1 = type; \
|
||||
gBattleMons[battlerId].type2 = type; \
|
||||
gBattleMons[battlerId].types[0] = type; \
|
||||
gBattleMons[battlerId].types[1] = type; \
|
||||
}
|
||||
|
||||
#define GET_STAT_BUFF_ID(n)((n & 0xF)) // first four bits 0x1, 0x2, 0x4, 0x8
|
||||
#define GET_STAT_BUFF_VALUE2(n)((n & 0xF0))
|
||||
#define GET_STAT_BUFF_VALUE(n)(((n >> 4) & 7)) // 0x10, 0x20, 0x40
|
||||
#define GET_STAT_BUFF_ID(n) ((n & 0xF)) // first four bits 0x1, 0x2, 0x4, 0x8
|
||||
#define GET_STAT_BUFF_VALUE2(n) ((n & 0xF0))
|
||||
#define GET_STAT_BUFF_VALUE(n) (((n >> 4) & 7)) // 0x10, 0x20, 0x40
|
||||
#define STAT_BUFF_NEGATIVE 0x80 // 0x80, the sign bit
|
||||
|
||||
#define SET_STAT_BUFF_VALUE(n)((((n) << 4) & 0xF0))
|
||||
#define SET_STAT_BUFF_VALUE(n) ((((n) << 4) & 0xF0))
|
||||
|
||||
#define SET_STATCHANGER(statId, stage, goesDown)(gBattleScripting.statChanger = (statId) + (stage << 4) + (goesDown << 7))
|
||||
#define SET_STATCHANGER(statId, stage, goesDown) (gBattleScripting.statChanger = (statId) + (stage << 4) + (goesDown << 7))
|
||||
|
||||
// NOTE: The members of this struct have hard-coded offsets
|
||||
// in include/constants/battle_script_commands.h
|
||||
|
||||
@ -124,8 +124,7 @@ struct ChooseMoveStruct
|
||||
u8 currentPp[MAX_MON_MOVES];
|
||||
u8 maxPp[MAX_MON_MOVES];
|
||||
u16 species;
|
||||
u8 monType1;
|
||||
u8 monType2;
|
||||
u8 monTypes[2];
|
||||
};
|
||||
|
||||
enum
|
||||
|
||||
@ -23,9 +23,9 @@ struct MultiPartnerMenuPokemon
|
||||
};
|
||||
|
||||
// defines for the u8 array gTypeEffectiveness
|
||||
#define TYPE_EFFECT_ATK_TYPE(i)((gTypeEffectiveness[i + 0]))
|
||||
#define TYPE_EFFECT_DEF_TYPE(i)((gTypeEffectiveness[i + 1]))
|
||||
#define TYPE_EFFECT_MULTIPLIER(i)((gTypeEffectiveness[i + 2]))
|
||||
#define TYPE_EFFECT_ATK_TYPE(i) ((gTypeEffectiveness[i + 0]))
|
||||
#define TYPE_EFFECT_DEF_TYPE(i) ((gTypeEffectiveness[i + 1]))
|
||||
#define TYPE_EFFECT_MULTIPLIER(i) ((gTypeEffectiveness[i + 2]))
|
||||
|
||||
// defines for the gTypeEffectiveness multipliers
|
||||
#define TYPE_MUL_NO_EFFECT 0
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user