Merge remote-tracking branch 'upstream/master' into move-tutor
# Conflicts: # include/pokenav.h # src/battle_script_commands.c
@ -1,5 +1,7 @@
|
||||
#!/usr/bin/perl
|
||||
|
||||
use IPC::Cmd qw[ run ];
|
||||
|
||||
(@ARGV == 1)
|
||||
or die "ERROR: no map file specified.\n";
|
||||
open(my $file, $ARGV[0])
|
||||
@ -7,7 +9,6 @@ open(my $file, $ARGV[0])
|
||||
|
||||
my $src = 0;
|
||||
my $asm = 0;
|
||||
my $undocumented = 0;
|
||||
while (my $line = <$file>)
|
||||
{
|
||||
if ($line =~ /^ \.(\w+)\s+0x[0-9a-f]+\s+(0x[0-9a-f]+) (\w+)\/.+\.o/)
|
||||
@ -28,19 +29,92 @@ while (my $line = <$file>)
|
||||
}
|
||||
}
|
||||
}
|
||||
if($line =~ /^\s+0x([0-9A-f]+)\s+[A-z_]+([0-9A-f]+)/) {
|
||||
my $thing1 = sprintf("%08X", hex($1));
|
||||
my $thing2 = sprintf("%08X", hex($2));
|
||||
if($thing1 eq $thing2) {
|
||||
$undocumented += 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Note that the grep filters out all branch labels. It also requires a minimum
|
||||
# line length of 5, to filter out a ton of generated symbols (like AcCn). No
|
||||
# settings to nm seem to remove these symbols. Finally, nm prints out a separate
|
||||
# entry for whenever a name appears in a file, not just where it's defined. uniq
|
||||
# removes all the duplicate entries.
|
||||
#
|
||||
#
|
||||
# You'd expect this to take a while, because of uniq. It runs in under a second,
|
||||
# though. Uniq is pretty fast!
|
||||
my $base_cmd = "nm pokeemerald.elf | awk '{print \$3}' | grep '^[^_].\\{4\\}' | uniq";
|
||||
|
||||
# This looks for Unknown_, Unknown_, or sub_, followed by just numbers. Note that
|
||||
# it matches even if stuff precedes the unknown, like sUnknown/gUnknown.
|
||||
my $undoc_cmd = "grep '[Uu]nknown_[0-9a-fA-F]*\\|sub_[0-9a-fA-F]*'";
|
||||
|
||||
# This looks for every symbol with an address at the end of it. Some things are
|
||||
# given a name based on their type / location, but still have an unknown purpose.
|
||||
# For example, FooMap_EventScript_FFFFFFF.
|
||||
my $partial_doc_cmd = "grep '[0-9a-fA-F]\\{6,7\\}'";
|
||||
|
||||
my $count_cmd = "wc -l";
|
||||
|
||||
# It sucks that we have to run this three times, but I can't figure out how to get
|
||||
# stdin working for subcommands in perl while still having a timeout. It's decently
|
||||
# fast anyway.
|
||||
my $total_syms_as_string;
|
||||
(run (
|
||||
command => "$base_cmd | $count_cmd",
|
||||
buffer => \$total_syms_as_string,
|
||||
timeout => 60
|
||||
))
|
||||
or die "ERROR: Error while getting all symbols: $?";
|
||||
|
||||
my $undocumented_as_string;
|
||||
(run (
|
||||
command => "$base_cmd | $undoc_cmd | $count_cmd",
|
||||
buffer => \$undocumented_as_string,
|
||||
timeout => 60
|
||||
))
|
||||
or die "ERROR: Error while filtering for undocumented symbols: $?";
|
||||
|
||||
my $partial_documented_as_string;
|
||||
(run (
|
||||
command => "$base_cmd | $partial_doc_cmd | $count_cmd",
|
||||
buffer => \$partial_documented_as_string,
|
||||
timeout => 60
|
||||
))
|
||||
or die "ERROR: Error while filtering for partial symbols: $?";
|
||||
|
||||
# Performing addition on a string converts it to a number. Any string that fails
|
||||
# to convert to a number becomes 0. So if our converted number is 0, but our string
|
||||
# is nonzero, then the conversion was an error.
|
||||
my $undocumented = $undocumented_as_string + 0;
|
||||
(($undocumented != 0) and ($undocumented_as_string ne "0"))
|
||||
or die "ERROR: Cannot convert string to num: '$undocumented_as_string'";
|
||||
|
||||
my $partial_documented = $partial_documented_as_string + 0;
|
||||
(($partial_documented != 0) and ($partial_documented_as_string ne "0"))
|
||||
or die "ERROR: Cannot convert string to num: '$partial_documented_as_string'";
|
||||
|
||||
my $total_syms = $total_syms_as_string + 0;
|
||||
(($total_syms != 0) and ($total_syms_as_string ne "0"))
|
||||
or die "ERROR: Cannot convert string to num: '$total_syms_as_string'";
|
||||
|
||||
($total_syms != 0)
|
||||
or die "ERROR: No symbols found.";
|
||||
|
||||
my $total = $src + $asm;
|
||||
my $srcPct = sprintf("%.4f", 100 * $src / $total);
|
||||
my $asmPct = sprintf("%.4f", 100 * $asm / $total);
|
||||
|
||||
# partial_documented is double-counting the unknown_* and sub_* symbols.
|
||||
$partial_documented = $partial_documented - $undocumented;
|
||||
|
||||
my $documented = $total_syms - ($undocumented + $partial_documented);
|
||||
my $docPct = sprintf("%.4f", 100 * $documented / $total_syms);
|
||||
my $partialPct = sprintf("%.4f", 100 * $partial_documented / $total_syms);
|
||||
my $undocPct = sprintf("%.4f", 100 * $undocumented / $total_syms);
|
||||
|
||||
print "$total total bytes of code\n";
|
||||
print "$src bytes of code in src ($srcPct%)\n";
|
||||
print "$asm bytes of code in asm ($asmPct%)\n";
|
||||
print "$undocumented global symbols undocumented\n";
|
||||
print "\n";
|
||||
print "$total_syms total symbols\n";
|
||||
print "$documented symbols documented ($docPct%)\n";
|
||||
print "$partial_documented symbols partially documented ($partialPct%)\n";
|
||||
print "$undocumented symbols undocumented ($undocPct%)\n";
|
||||
|
@ -66,6 +66,14 @@ cd ../pokeemerald
|
||||
|
||||
And build the ROM with `make`.
|
||||
|
||||
If the step `./build.sh` in the above list of commands fails with the error `Makefile:1: /opt/devkitpro/devkitARM/base_tools: No such file or directory`, then try installing the pacman package `devkitarm-rules` by executing the command
|
||||
|
||||
```
|
||||
sudo dkp-pacman -S devkitarm-rules
|
||||
```
|
||||
|
||||
Executing `./build.sh` again should now succeed.
|
||||
|
||||
# Faster builds
|
||||
|
||||
After the first build, subsequent builds are faster. You can further speed up the build:
|
||||
|
114
asmdiff.ps1
Normal file
@ -0,0 +1,114 @@
|
||||
Param
|
||||
(
|
||||
[Parameter(Position = 0)]
|
||||
[string]$Start,
|
||||
|
||||
[Parameter(Position = 1)]
|
||||
[string]$Offset,
|
||||
|
||||
[Parameter()]
|
||||
[string[]]$DiffTool
|
||||
)
|
||||
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
$offset_default_value = "0x100"
|
||||
$diff_tool_default_value = "diff"
|
||||
|
||||
$help = "
|
||||
$($args[0]) [OPTIONS] Start [Offset]
|
||||
|
||||
Performs a diff on the assembly of a function in a rom. 'Start' is the start
|
||||
location of the function, and 'Offset' is the number of bytes to disassemble.
|
||||
The assembly is saved to *.dump files.
|
||||
|
||||
'Offset' is optional, and defaults to $offset_default_value. If this value is
|
||||
very large (0x10000+), objdump may hang / freeze.
|
||||
|
||||
Requirements:
|
||||
- A clean copy of the rom named 'baserom.gba'.
|
||||
- $$ENV:DEVKITARM to point to the installation of devkitpro. By default, it is
|
||||
installed to 'C:\devkitpro\devkitARM'.
|
||||
|
||||
Options:
|
||||
-DiffTool <tool> The tool to use for diffing. Defaults to '$diff_tool_default_value'. For VSCode,
|
||||
you can use -DiffTool 'code --diff'. (Quotes are necessary around 'code --diff')
|
||||
"
|
||||
|
||||
if ((-not (Test-Path variable:Start)) -or [string]::IsNullOrWhiteSpace($Start))
|
||||
{
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
if (-not (Test-Path variable:DiffTool) -or [string]::IsNullOrWhiteSpace($DiffTool))
|
||||
{
|
||||
$DiffTool = $diff_tool_default_value
|
||||
}
|
||||
|
||||
if (-not (Test-Path variable:Offset) -or [string]::IsNullOrWhiteSpace($Offset))
|
||||
{
|
||||
$Offset = $offset_default_value
|
||||
}
|
||||
|
||||
if (-Not (Test-Path env:DEVKITARM))
|
||||
{
|
||||
Write-Host "ENV:DEVKITARM variable not set."
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
if (-Not (Test-Path $env:DEVKITARM))
|
||||
{
|
||||
Write-Host "DEVKITARM path '$env:DEVKITARM' does not exist."
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
if (-Not (Test-Path ".\pokeemerald.gba"))
|
||||
{
|
||||
Write-Host "File 'pokeemerald.gba' not found."
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
if (-Not (Test-Path ".\baserom.gba"))
|
||||
{
|
||||
Write-Host "File 'baserom.gba' not found."
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
$start_num = [System.Convert]::ToUInt64($Start, 16)
|
||||
}
|
||||
catch
|
||||
{
|
||||
Write-Host "Error parsing '$start_num' as a hex number."
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
$offset_num = [System.Convert]::ToUInt64($Offset, 16)
|
||||
}
|
||||
catch
|
||||
{
|
||||
Write-Host "Error parsing '$offset_num' as a hex number."
|
||||
Write-Host $help
|
||||
exit
|
||||
}
|
||||
|
||||
if ($start_num -gt 0x1000000)
|
||||
{
|
||||
Write-Host "Warning: Start address is larger than the ROM file. Hint: ignore the leading number in the address."
|
||||
}
|
||||
|
||||
$end_str = [System.Convert]::ToString($start_num + $offset_num, 16)
|
||||
$end_str = "0x$end_str"
|
||||
|
||||
Write-Host "$Start - $end_str"
|
||||
$objdump = Join-Path -Path $env:DEVKITARM -ChildPath "arm-none-eabi\bin\objdump.exe"
|
||||
&$objdump -D -bbinary -marmv4t -Mforce-thumb --start-address="$Start" --stop-address="$end_str" .\baserom.gba > .\baserom.dump
|
||||
&$objdump -D -bbinary -marmv4t -Mforce-thumb --start-address="$Start" --stop-address="$end_str" .\pokeemerald.gba > .\pokeemerald.dump
|
||||
Invoke-Expression "$DiffTool .\baserom.dump .\pokeemerald.dump"
|
@ -3161,7 +3161,7 @@ Route118_EventScript_273D13:: @ 8273D13
|
||||
Route125_EventScript_273D13:: @ 8273D13
|
||||
Route127_EventScript_273D13:: @ 8273D13
|
||||
Route129_EventScript_273D13:: @ 8273D13
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
UnusualWeather_StartKyogreWeather:: @ 8273D17
|
||||
@ -3188,7 +3188,7 @@ UnusualWeather_EventScript_EndEventAndCleanup_2:: @ 8273D31
|
||||
special DrawWholeMapView
|
||||
setvar VAR_UNUSUAL_WEATHER_LOCATION, UNUSUAL_WEATHER_NONE
|
||||
setvar VAR_SHOULD_END_UNUSUAL_WEATHER, 0
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
fadescreenswapbuffers 0
|
||||
releaseall
|
||||
end
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_FRONTIER_BATTLE_PYRAMID_EMPTY_SQUARE",
|
||||
"name": "BattleFrontier_BattlePyramidEmptySquare",
|
||||
"layout": "LAYOUT_BATTLE_FRONTIER_BATTLE_PYRAMID_EMPTY_SQUARE",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_BATTLE_FRONTIER",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_FRONTIER_BATTLE_PYRAMID_TOP",
|
||||
"name": "BattleFrontier_BattlePyramidTop",
|
||||
"layout": "LAYOUT_BATTLE_FRONTIER_BATTLE_PYRAMID_TOP",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_BATTLE_FRONTIER",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE01",
|
||||
"name": "BattlePyramidSquare01",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE01",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE02",
|
||||
"name": "BattlePyramidSquare02",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE02",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE03",
|
||||
"name": "BattlePyramidSquare03",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE03",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE04",
|
||||
"name": "BattlePyramidSquare04",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE04",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE05",
|
||||
"name": "BattlePyramidSquare05",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE05",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE06",
|
||||
"name": "BattlePyramidSquare06",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE06",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE07",
|
||||
"name": "BattlePyramidSquare07",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE07",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE08",
|
||||
"name": "BattlePyramidSquare08",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE08",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE09",
|
||||
"name": "BattlePyramidSquare09",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE09",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE10",
|
||||
"name": "BattlePyramidSquare10",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE10",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE11",
|
||||
"name": "BattlePyramidSquare11",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE11",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE12",
|
||||
"name": "BattlePyramidSquare12",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE12",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE13",
|
||||
"name": "BattlePyramidSquare13",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE13",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE14",
|
||||
"name": "BattlePyramidSquare14",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE14",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE15",
|
||||
"name": "BattlePyramidSquare15",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE15",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BATTLE_PYRAMID_SQUARE16",
|
||||
"name": "BattlePyramidSquare16",
|
||||
"layout": "LAYOUT_BATTLE_PYRAMID_SQUARE16",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_DYNAMIC",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BIRTH_ISLAND_EXTERIOR",
|
||||
"name": "BirthIsland_Exterior",
|
||||
"layout": "LAYOUT_BIRTH_ISLAND_EXTERIOR",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_BIRTH_ISLAND_2",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_BIRTH_ISLAND_HARBOR",
|
||||
"name": "BirthIsland_Harbor",
|
||||
"layout": "LAYOUT_ISLAND_HARBOR",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_BIRTH_ISLAND_2",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_CAVE_OF_ORIGIN_B1F",
|
||||
"name": "CaveOfOrigin_B1F",
|
||||
"layout": "LAYOUT_CAVE_OF_ORIGIN_B1F",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_CAVE_OF_ORIGIN",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_FOG_1",
|
||||
|
@ -2,7 +2,7 @@
|
||||
"id": "MAP_INSIDE_OF_TRUCK",
|
||||
"name": "InsideOfTruck",
|
||||
"layout": "LAYOUT_INSIDE_OF_TRUCK",
|
||||
"music": "65535",
|
||||
"music": "MUS_NONE",
|
||||
"region_map_section": "MAPSEC_INSIDE_OF_TRUCK",
|
||||
"requires_flash": false,
|
||||
"weather": "WEATHER_NONE",
|
||||
|
@ -15,7 +15,7 @@ InsideOfTruck_MapScript1_23BF01: @ 823BF01
|
||||
|
||||
InsideOfTruck_EventScript_23BF04:: @ 823BF04
|
||||
lockall
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
checkplayergender
|
||||
compare VAR_RESULT, MALE
|
||||
goto_if_eq InsideOfTruck_EventScript_23BF20
|
||||
|
@ -37,7 +37,7 @@ LavaridgeTown_EventScript_1EA53F:: @ 81EA53F
|
||||
return
|
||||
|
||||
LavaridgeTown_EventScript_1EA543:: @ 81EA543
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
LavaridgeTown_MapScript2_1EA547: @ 81EA547
|
||||
@ -95,7 +95,7 @@ LavaridgeTown_EventScript_1EA5FF:: @ 81EA5FF
|
||||
call_if_ne LavaridgeTown_EventScript_1EA6C9
|
||||
removeobject 7
|
||||
setvar VAR_LAVARIDGE_RIVAL_STATE, 2
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
savebgm MUS_DUMMY
|
||||
fadedefaultbgm
|
||||
releaseall
|
||||
|
@ -31,7 +31,7 @@ LittlerootTown_EventScript_1E7E45:: @ 81E7E45
|
||||
return
|
||||
|
||||
LittlerootTown_EventScript_1E7E4B:: @ 81E7E4B
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
LittlerootTown_EventScript_1E7E4F:: @ 81E7E4F
|
||||
@ -141,7 +141,7 @@ LittlerootTown_EventScript_1E7F17:: @ 81E7F17
|
||||
closedoor VAR_0x8004, VAR_0x8005
|
||||
waitdooranim
|
||||
clearflag FLAG_HIDE_LITTLEROOT_TOWN_FAT_MAN
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
LittlerootTown_Movement_1E7F98: @ 81E7F98
|
||||
@ -194,7 +194,7 @@ LittlerootTown_EventScript_1E7FB1:: @ 81E7FB1
|
||||
clearflag FLAG_HIDE_LITTLEROOT_TOWN_RIVAL
|
||||
clearflag FLAG_HIDE_LITTLEROOT_TOWN_BIRCH
|
||||
delay 20
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
warp MAP_LITTLEROOT_TOWN_PROFESSOR_BIRCHS_LAB, 255, 6, 5
|
||||
waitstate
|
||||
releaseall
|
||||
|
@ -20,7 +20,7 @@ PetalburgCity_EventScript_1DC307:: @ 81DC307
|
||||
return
|
||||
|
||||
PetalburgCity_EventScript_1DC30F:: @ 81DC30F
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
savebgm MUS_TSURETEK
|
||||
return
|
||||
|
||||
@ -48,7 +48,7 @@ PetalburgCity_EventScript_1DC32E:: @ 81DC32E
|
||||
waitmovement 2, MAP_PETALBURG_CITY
|
||||
msgbox PetalburgCity_Text_1EC297, MSGBOX_DEFAULT
|
||||
closemessage
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
setvar VAR_PETALBURG_STATE, 3
|
||||
fadedefaultbgm
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4001
|
||||
@ -61,7 +61,7 @@ PetalburgCity_EventScript_1DC32E:: @ 81DC32E
|
||||
|
||||
PetalburgCity_EventScript_1DC390:: @ 81DC390
|
||||
lockall
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
applymovement 5, PetalburgCity_Movement_1DC41B
|
||||
applymovement EVENT_OBJ_ID_PLAYER, PetalburgCity_Movement_1DC406
|
||||
waitmovement 0
|
||||
@ -76,7 +76,7 @@ PetalburgCity_EventScript_1DC390:: @ 81DC390
|
||||
hideobjectat EVENT_OBJ_ID_PLAYER, MAP_PETALBURG_CITY
|
||||
closedoor VAR_0x8004, VAR_0x8005
|
||||
waitdooranim
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
fadedefaultbgm
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4001
|
||||
warp MAP_PETALBURG_CITY_WALLYS_HOUSE, 255, 2, 4
|
||||
|
@ -12,7 +12,7 @@ Route101_MapScript2_1EBCCB: @ 81EBCCB
|
||||
.2byte 0
|
||||
|
||||
Route101_EventScript_1EBCD5:: @ 81EBCD5
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
setvar VAR_ROUTE101_STATE, 1
|
||||
end
|
||||
|
||||
@ -236,7 +236,7 @@ Route101_EventScript_1EBE16:: @ 81EBE16
|
||||
setflag FLAG_HIDE_ROUTE_101_BIRCH_STARTERS_BAG
|
||||
setvar VAR_BIRCH_LAB_STATE, 2
|
||||
setvar VAR_ROUTE101_STATE, 3
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
checkplayergender
|
||||
compare VAR_RESULT, MALE
|
||||
call_if_eq Route101_EventScript_1EBE85
|
||||
|
@ -73,7 +73,7 @@ Route128_EventScript_1F6B57:: @ 81F6B57
|
||||
delay 15
|
||||
removeobject 3
|
||||
waitfieldeffect 30
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
setvar VAR_ROUTE128_STATE, 2
|
||||
releaseall
|
||||
end
|
||||
|
@ -24,7 +24,7 @@ RustboroCity_EventScript_1E06FF:: @ 81E06FF
|
||||
end
|
||||
|
||||
RustboroCity_EventScript_1E0707:: @ 81E0707
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
RustboroCity_MapScript2_1E070B: @ 81E070B
|
||||
@ -100,7 +100,7 @@ RustboroCity_EventScript_1E07BD:: @ 81E07BD
|
||||
removeobject 15
|
||||
setflag FLAG_HIDE_RUSTBORO_CITY_SCIENTIST
|
||||
setvar VAR_RUSTBORO_STATE, 7
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
releaseall
|
||||
end
|
||||
|
||||
|
@ -140,7 +140,7 @@ SeafloorCavern_Room9_EventScript_234DC9:: @ 8234DC9
|
||||
setflag FLAG_HIDE_SEAFLOOR_CAVERN_ROOM_9_MAGMA_GRUNTS
|
||||
setflag FLAG_HIDE_SEAFLOOR_CAVERN_ROOM_9_KYOGRE_1
|
||||
setflag FLAG_HIDE_SEAFLOOR_CAVERN_AQUA_GRUNTS
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
warp MAP_ROUTE128, 255, 38, 22
|
||||
waitstate
|
||||
releaseall
|
||||
|
@ -12,7 +12,7 @@ SkyPillar_Outside_MapScript1_2392B8: @ 82392B8
|
||||
end
|
||||
|
||||
SkyPillar_Outside_EventScript_2392CF:: @ 82392CF
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
SkyPillar_Outside_EventScript_2392D3:: @ 82392D3
|
||||
@ -81,7 +81,7 @@ SkyPillar_Outside_EventScript_239304:: @ 8239304
|
||||
closemessage
|
||||
playse SE_KAIDAN
|
||||
fadescreenswapbuffers 1
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
setvar VAR_RAYQUAZA_STATE, 4
|
||||
removeobject 1
|
||||
clearflag FLAG_HIDE_SOOTOPOLIS_CITY_WALLACE
|
||||
|
@ -36,7 +36,7 @@ SlateportCity_EventScript_1DCC99:: @ 81DCC99
|
||||
return
|
||||
|
||||
SlateportCity_EventScript_1DCCE7:: @ 81DCCE7
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
getplayerxy VAR_0x8004, VAR_0x8005
|
||||
compare VAR_0x8004, 30
|
||||
goto_if_eq SlateportCity_EventScript_1DCD06
|
||||
@ -83,7 +83,7 @@ SlateportCity_EventScript_1DCD1C:: @ 81DCD1C
|
||||
removeobject 35
|
||||
setobjectxyperm 35, 10, 12
|
||||
setobjectmovementtype 35, MOVEMENT_TYPE_FACE_DOWN
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
setvar VAR_SLATEPORT_OUTSIDE_MUSEUM_STATE, 2
|
||||
addvar VAR_SCOTT_STATE, 1
|
||||
releaseall
|
||||
|
@ -62,7 +62,7 @@ SootopolisCity_MapScript1_1E56EF: @ 81E56EF
|
||||
end
|
||||
|
||||
SootopolisCity_EventScript_1E5781:: @ 81E5781
|
||||
setflag FLAG_SPECIAL_FLAG_0x4000
|
||||
setflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
return
|
||||
|
||||
SootopolisCity_EventScript_1E5785:: @ 81E5785
|
||||
@ -272,7 +272,7 @@ SootopolisCity_EventScript_1E5946:: @ 81E5946
|
||||
waitmovement 0
|
||||
special RemoveCameraObject
|
||||
setvar VAR_RAYQUAZA_STATE, 2
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
releaseall
|
||||
end
|
||||
|
||||
@ -372,7 +372,7 @@ SootopolisCity_EventScript_1E5A82:: @ 81E5A82
|
||||
waitmovement 0
|
||||
special RemoveCameraObject
|
||||
setvar VAR_RAYQUAZA_STATE, 2
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
releaseall
|
||||
end
|
||||
|
||||
@ -544,7 +544,7 @@ SootopolisCity_EventScript_1E5C1E:: @ 81E5C1E
|
||||
clearflag FLAG_LEGENDARIES_IN_SOOTOPOLIS
|
||||
fadenewbgm MUS_RUNECITY
|
||||
delay 120
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
warp8 MAP_SOOTOPOLIS_CITY, 255, 43, 32
|
||||
waitstate
|
||||
end
|
||||
@ -597,7 +597,7 @@ SootopolisCity_EventScript_1E5CCE:: @ 81E5CCE
|
||||
clearflag FLAG_LEGENDARIES_IN_SOOTOPOLIS
|
||||
fadenewbgm MUS_NAMINORI
|
||||
delay 120
|
||||
clearflag FLAG_SPECIAL_FLAG_0x4000
|
||||
clearflag FLAG_HIDE_MAP_NAME_POPUP
|
||||
warp8 MAP_SOOTOPOLIS_CITY, 255, 29, 53
|
||||
waitstate
|
||||
end
|
||||
|
Before Width: | Height: | Size: 698 B After Width: | Height: | Size: 698 B |
Before Width: | Height: | Size: 616 B After Width: | Height: | Size: 616 B |
Before Width: | Height: | Size: 94 B After Width: | Height: | Size: 94 B |
Before Width: | Height: | Size: 585 B After Width: | Height: | Size: 585 B |
Before Width: | Height: | Size: 327 B After Width: | Height: | Size: 327 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 673 B After Width: | Height: | Size: 673 B |
Before Width: | Height: | Size: 102 B After Width: | Height: | Size: 102 B |
Before Width: | Height: | Size: 890 B After Width: | Height: | Size: 890 B |
Before Width: | Height: | Size: 371 B After Width: | Height: | Size: 371 B |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 602 B After Width: | Height: | Size: 602 B |
Before Width: | Height: | Size: 92 B After Width: | Height: | Size: 92 B |
Before Width: | Height: | Size: 923 B After Width: | Height: | Size: 923 B |
Before Width: | Height: | Size: 369 B After Width: | Height: | Size: 369 B |
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 860 B After Width: | Height: | Size: 860 B |
Before Width: | Height: | Size: 102 B After Width: | Height: | Size: 102 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 367 B After Width: | Height: | Size: 367 B |
Before Width: | Height: | Size: 924 B After Width: | Height: | Size: 924 B |
Before Width: | Height: | Size: 592 B After Width: | Height: | Size: 592 B |
Before Width: | Height: | Size: 86 B After Width: | Height: | Size: 86 B |
Before Width: | Height: | Size: 639 B After Width: | Height: | Size: 639 B |
Before Width: | Height: | Size: 399 B After Width: | Height: | Size: 399 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 864 B After Width: | Height: | Size: 864 B |
Before Width: | Height: | Size: 95 B After Width: | Height: | Size: 95 B |
Before Width: | Height: | Size: 839 B After Width: | Height: | Size: 839 B |
Before Width: | Height: | Size: 401 B After Width: | Height: | Size: 401 B |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 685 B After Width: | Height: | Size: 685 B |
Before Width: | Height: | Size: 100 B After Width: | Height: | Size: 100 B |
Before Width: | Height: | Size: 825 B After Width: | Height: | Size: 825 B |
Before Width: | Height: | Size: 419 B After Width: | Height: | Size: 419 B |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 714 B After Width: | Height: | Size: 714 B |
Before Width: | Height: | Size: 90 B After Width: | Height: | Size: 90 B |
Before Width: | Height: | Size: 721 B After Width: | Height: | Size: 721 B |
Before Width: | Height: | Size: 430 B After Width: | Height: | Size: 430 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 445 B After Width: | Height: | Size: 445 B |
Before Width: | Height: | Size: 71 B After Width: | Height: | Size: 71 B |
Before Width: | Height: | Size: 691 B After Width: | Height: | Size: 691 B |
Before Width: | Height: | Size: 377 B After Width: | Height: | Size: 377 B |