Browse Source

Start from Scratch

ipatix 8 years ago
commit
19f45282cf
100 changed files with 63890 additions and 0 deletions
  1. 14
    0
      .gitignore
  2. 3
    0
      .gitmodules
  3. 1
    0
      README.md
  4. 57
    0
      assets.makefile
  5. BIN
      assets/meteor/BG0.PNG
  6. BIN
      assets/meteor/BG1.PNG
  7. BIN
      assets/meteor/BG1_red.PNG
  8. BIN
      assets/meteor/BG2.PNG
  9. BIN
      assets/meteor/BG2_red.PNG
  10. BIN
      assets/meteor/OAM.PNG
  11. BIN
      assets/meteor/clouds.PNG
  12. 95
    0
      bpre.sym
  13. 631
    0
      data/animation_table.S
  14. 220
    0
      data/effect_table.S
  15. 1207
    0
      data/pkmn_tables/icon_sprites.S
  16. 1206
    0
      data/pkmn_tables/icons_paletten.S
  17. BIN
      data/pkmn_tables/pkmn_enemy_altitude_table_dump.bin
  18. BIN
      data/pkmn_tables/pkmn_enemy_y_table_dump.bin
  19. 1
    0
      data/pkmn_tables/pkmn_names_dump.bin
  20. BIN
      data/pkmn_tables/pkmn_player_y_table_dump.bin
  21. 4337
    0
      data/pkmn_tables/pokedex_daten.S
  22. 1205
    0
      data/pkmn_tables/pokedex_order.S
  23. 2901
    0
      data/pkmn_tables/pokedex_texte.S
  24. 1205
    0
      data/pkmn_tables/pokemon_back_sprites.S
  25. 4253
    0
      data/pkmn_tables/pokemon_egg_moves.S
  26. 7
    0
      data/pkmn_tables/pokemon_enemy_altitude_table.s
  27. 7
    0
      data/pkmn_tables/pokemon_enemy_y_table.s
  28. 1205
    0
      data/pkmn_tables/pokemon_evolution.s
  29. 2012
    0
      data/pkmn_tables/pokemon_footprints.s
  30. 1205
    0
      data/pkmn_tables/pokemon_front_sprites.S
  31. 1203
    0
      data/pkmn_tables/pokemon_move_tutor.s
  32. 27794
    0
      data/pkmn_tables/pokemon_moveset_table.S
  33. 7
    0
      data/pkmn_tables/pokemon_names.S
  34. 1205
    0
      data/pkmn_tables/pokemon_normal_pal.S
  35. 7
    0
      data/pkmn_tables/pokemon_player_y_table.s
  36. 1205
    0
      data/pkmn_tables/pokemon_shiny_pal.S
  37. 4804
    0
      data/pkmn_tables/pokemon_stats.S
  38. 24
    0
      icons.makefile
  39. 29
    0
      linker.ld
  40. 32
    0
      main.asm
  41. 115
    0
      makefile
  42. 43
    0
      patches/disable_cry_table_blocks.s
  43. 250
    0
      patches/dynamic_overworld_hooks.asm
  44. 217
    0
      patches/hooks.asm
  45. 20
    0
      patches/moves.asm
  46. 14
    0
      patches/music.asm
  47. 12
    0
      patches/pokemon_data/altitude_table.asm
  48. 48
    0
      patches/pokemon_data/enemy_y_table.asm
  49. 34
    0
      patches/pokemon_data/limits.asm
  50. 18
    0
      patches/pokemon_data/moveset_table.asm
  51. 24
    0
      patches/pokemon_data/player_y_table.asm
  52. 48
    0
      patches/pokemon_data/pokedex.asm
  53. 23
    0
      patches/pokemon_data/pokedex_entries.asm
  54. 17
    0
      patches/pokemon_data/pokedex_order.asm
  55. 30
    0
      patches/pokemon_data/pokemon_back_sprites.asm
  56. 8
    0
      patches/pokemon_data/pokemon_egg_moves.asm
  57. 84
    0
      patches/pokemon_data/pokemon_front_sprites.asm
  58. 41
    0
      patches/pokemon_data/pokemon_icons.asm
  59. 120
    0
      patches/pokemon_data/pokemon_names.asm
  60. 15
    0
      patches/pokemon_data/pokemon_normal_pal.asm
  61. 9
    0
      patches/pokemon_data/pokemon_shiny_pal.asm
  62. 174
    0
      patches/pokemon_data/pokemon_stats.asm
  63. 46
    0
      patches/save_table/save_table.S
  64. 2
    0
      patches/special.asm
  65. 843
    0
      patches/split_physical_special.asm
  66. 1
    0
      sots-private
  67. 129
    0
      sprites.makefile
  68. 45
    0
      src/assets/meteor/met_background.c
  69. 33
    0
      src/assets/meteor/met_background.h
  70. 64
    0
      src/assets/meteor/met_clouds.c
  71. 32
    0
      src/assets/meteor/met_clouds.h
  72. 148
    0
      src/assets/meteor/met_foreground.c
  73. 32
    0
      src/assets/meteor/met_foreground.h
  74. 68
    0
      src/assets/meteor/met_meteor.c
  75. 28
    0
      src/assets/meteor/met_meteor.h
  76. 55
    0
      src/assets/meteor/met_sky.c
  77. 32
    0
      src/assets/meteor/met_sky.h
  78. 49
    0
      src/battle_bg/battle_bg_hook.S
  79. 61
    0
      src/encode/crc32.c
  80. 621
    0
      src/include/attack_names.h
  81. 1246
    0
      src/include/battle_script.h
  82. 35
    0
      src/include/bpre.h
  83. 36
    0
      src/include/callback.h
  84. 149
    0
      src/include/config.h
  85. 21
    0
      src/include/fade.h
  86. 44
    0
      src/include/lcd.h
  87. 76
    0
      src/include/objects.h
  88. 24
    0
      src/include/pkmn_types.h
  89. 21
    0
      src/include/sound.h
  90. 19
    0
      src/include/types.h
  91. 167
    0
      src/interface/lcd_io_test.S
  92. 131
    0
      src/interface/textbox_mugshots.c
  93. 26
    0
      src/interface/textbox_setup.S
  94. 37
    0
      src/interface/trans_mug_close_fix.S
  95. 10
    0
      src/moves/battle_engine/bs_table.S
  96. 1
    0
      src/moves/battle_engine/bs_table_d.bin
  97. 29
    0
      src/moves/battle_engine/cmd_callasm.S
  98. 32
    0
      src/moves/battle_engine/cmd_setword.S
  99. 51
    0
      src/moves/battle_engine/custom_print_string.S
  100. 0
    0
      src/moves/battle_engine/new_move_first.S

+ 14
- 0
.gitignore View File

@@ -0,0 +1,14 @@
1
+*.gba
2
+base/*.gba
3
+build
4
+gfx_build
5
+object
6
+temp
7
+assets/pkmn_sprites/*.png
8
+assets/pkmn_sprites/castform/*.png
9
+assets/pkmn_icons/*.png
10
+*.ogg
11
+*.wav
12
+*.mid
13
+*.o
14
+*.a

+ 3
- 0
.gitmodules View File

@@ -0,0 +1,3 @@
1
+[submodule "sots-private"]
2
+	path = sots-private
3
+	url = ssh://sotshost:/home/sots/sots-private.git

+ 1
- 0
README.md View File

@@ -0,0 +1 @@
1
+Source Code von Pokémon Sovereign of the skies, ohne Anspruch auf Vollständigkeit oder Funktionsfähigkeit. Diese Repository soll lediglich dazu dienen einen Einblick in die Denkweise hinter Pokémon Sovereign of the Skies bieten.

+ 57
- 0
assets.makefile View File

@@ -0,0 +1,57 @@
1
+GRIT := grit
2
+CC   := arm-none-eabi-gcc
3
+AR   := arm-none-eabi-ar
4
+
5
+CFLAGS := -mthumb -mno-thumb-interwork -mcpu=arm7tdmi -mlong-calls -march=armv4t -O3 -std=c99
6
+
7
+PNG_MET_BG     := assets/meteor/bg0.png
8
+PNG_MET_SKY    := assets/meteor/bg1.png
9
+PNG_MET_FG     := assets/meteor/bg2.png
10
+PNG_MET_CLOUDS := assets/meteor/clouds.png
11
+PNG_MET_METEOR := assets/meteor/oam.png
12
+
13
+C_MET_BG     := src/assets/meteor/met_background.c
14
+C_MET_SKY    := src/assets/meteor/met_sky.c
15
+C_MET_FG     := src/assets/meteor/met_foreground.c
16
+C_MET_CLOUDS := src/assets/meteor/met_clouds.c
17
+C_MET_METEOR := src/assets/meteor/met_meteor.c
18
+
19
+.PHONY: all
20
+all: $(C_MET_BG) $(C_MET_SKY) $(C_MET_FG) $(C_MET_CLOUDS) $(C_MET_METEOR)
21
+
22
+
23
+
24
+# generate object files
25
+#$(O_MET_BG): $(C_MET_BG)
26
+#	$(CC) $(CFLAGS) -c -o $@ $<
27
+#
28
+#$(O_MET_SKY): $(C_MET_SKY)
29
+#	$(CC) $(CFLAGS) -c -o $@ $<
30
+#
31
+#$(O_MET_FG): $(C_MET_FG)
32
+#	$(CC) $(CFLAGS) -c -o $@ $<
33
+#
34
+#$(O_MET_CLOUDS): $(C_MET_CLOUDS)
35
+#	$(CC) $(CFLAGS) -c -o $@ $<
36
+#
37
+#$(O_MET_METEOR): $(C_MET_METEOR)
38
+#	$(CC) $(CFLAGS) -c -o $@ $<
39
+
40
+# generate C files
41
+$(C_MET_BG): $(PNG_MET_BG)
42
+	$(GRIT) $< -gu32 -gT00FF00 -gzl -gB 4 -gt -m -mu16 -mzl -mp0 -mRtpf -p -pu16 -pzl -ftc -o $@
43
+
44
+$(C_MET_SKY): $(PNG_MET_SKY)
45
+	$(GRIT) $< -gu32 -gzl -gB 4 -gt -m -mu16 -mzl -mp1 -mRtpf -p -pu16 -pzl -ftc -o $@
46
+
47
+$(C_MET_RG): $(PNG_MET_RG)
48
+	$(GRIT) $< -gu32 -gzl -gB 4 -gt -m -mu16 -mzl -mp3 -mRtpf -p -pu16 -pzl -ftc -o $@
49
+
50
+$(C_MET_CLOUDS): $(PNG_MET_CLOUDS)
51
+	$(GRIT) $< -gu32 -gzl -gB 4 -gt -m -mu16 -mzl -mp2 -mRtpf -p -pu16 -pzl -ftc -o $@
52
+
53
+$(C_MET_METEOR): $(PNG_MET_METEOR)
54
+	$(GRIT) $< -gu32 -gzl -gB 4 -gt -p -pu16 -pz! -ftc -o $@
55
+
56
+
57
+	

BIN
assets/meteor/BG0.PNG View File


BIN
assets/meteor/BG1.PNG View File


BIN
assets/meteor/BG1_red.PNG View File


BIN
assets/meteor/BG2.PNG View File


BIN
assets/meteor/BG2_red.PNG View File


BIN
assets/meteor/OAM.PNG View File


BIN
assets/meteor/clouds.PNG View File


+ 95
- 0
bpre.sym View File

@@ -0,0 +1,95 @@
1
+set_callback2 = 0x08000545;
2
+vblank_handler_set = 0x080006F5;
3
+malloc = 0x08002BB1;
4
+free = 0x08002BC4|1;
5
+memset = 0x081E5ED8|1;
6
+template_instanciate_forward_search = 0x08006F8D;
7
+gpu_copy_to_vram_by_bgid = 0x08001298|1;
8
+bg_set_tilemap = 0x08001FA0|1;
9
+bg_nullify_tilemap = 0x08001FD4|1;
10
+bg_get_tilemap = 0x08002008|1;
11
+bg_send_tilemap = 0x080020BC|1;
12
+gpu_init_bgs = 0x08001028|1;
13
+gpu_tile_bg_drop_all_sets = 0x08001618|1;
14
+bg_vram_setup = 0x08001658|1;
15
+gpu_bg_show = 0x08001320|1;
16
+gpu_bg_hide = 0x0800139C|1;
17
+gpu_sync_bg_visibility_and_mode = 0x080013D0|1;
18
+gpu_pal_upload = 0x08070474|1;
19
+gpu_sprites_upload = 0x08007320|1;
20
+obj_delete_all = 0x8007770|1;
21
+camera_move_and_redraw = 0x0805ACB4|1;
22
+calc_circle = 0x0807EE2C|1;
23
+
24
+pal_decompress_slice_to_faded_and_unfaded = 0x080703A8|1;
25
+gpu_tile_obj_decompress_alloc_tag_and_upload = 0x0800F035;
26
+gpu_pal_obj_alloc_tag_and_apply = 0x08008929;
27
+gpu_tile_obj_free_by_tag = 0x0800874D;
28
+gpu_pal_free_by_tag = 0x08008A31;
29
+obj_delete_and_free_tiles = 0x08007281;
30
+box_zero_flag = 0x0203709C;
31
+task_add_func = 0x0807741D;
32
+lcd_io_set_func = 0x08000A39;
33
+lcd_io_get = 0x08000AC4|1;
34
+flag_decrypt_func = 0x0806E6D1;
35
+var_access = 0x0806E455;
36
+flag_check = 0x0806E6D1;
37
+get_bs_elem_env_index = 0x0800FC2D;
38
+load_battle_screen_elements_1 = 0x0800F261;
39
+npc_states = 0x02036E38;
40
+battlescript_counter = 0x02023D74;
41
+item_table = 0x0876DD80;
42
+execute_battle_script = 0x0801BC24;
43
+dp_01_prepare_buffer = 0x0800D8B1;
44
+wram_decompress = 0x081E3B70|1;
45
+
46
+fade_screen = 0x08070589;
47
+fade_update = 0x080704D1;
48
+
49
+callback_overworld = 0x080568C5;
50
+task_exec = 0x08077579;
51
+objc_exec = 0x08006B5D;
52
+obj_sync = 0x08006BA9;
53
+
54
+clear_flag = 0x0806E6A9;
55
+
56
+
57
+divide = 0x081E4018;
58
+
59
+decompression_buffer = 0x0201C000;
60
+superstate = 0x030030F0;
61
+
62
+fade_controller = 0x02037AB8;
63
+
64
+weather_turns = 0x02023F48;
65
+battle_type_flags = 0x02022B4C;
66
+battle_active_side = 0x02023BC4;
67
+battle_num_active_sides = 0x02023BCC;
68
+battle_mode = 0x02023BE3;
69
+battle_data	= 0x02023BE4;
70
+battle_data_ability = 0x02023C04;
71
+battle_data_current_hp = 0x02023C0C;
72
+battle_executed_move = 0x02023D4A;
73
+battle_attacker_bank = 0x02023D6B;
74
+battle_defender_bank = 0x02023D6C;
75
+battle_attacker_p_bank = 0x02023D6D;
76
+battle_defender_p_bank = 0x02023D6E;
77
+battle_attack_effectivity = 0x02023DCC;
78
+battle_weather = 0x02023F1C;
79
+battle_damage_store = 0x02023D50;
80
+battle_string_message_table = 0x083FDF3C;
81
+battle_crit_loc = 0x02023D71;
82
+battle_base_power = 0x02024020;
83
+battle_side_unknown = 0x02023FDB;
84
+
85
+battle_status3_bits_pbs = 0x02023DFC;
86
+
87
+mugshots = 0x097007E0;
88
+battle_bg_table = 0x0824ee34;
89
+
90
+
91
+mplay_table = 0x084A329C;
92
+
93
+m4aSongNumStart = 0x081DD0F5;
94
+MPlayStart_rev01 = 0x081DD859;
95
+MPlayContinue = 0x081DCFF9;

+ 631
- 0
data/animation_table.S View File

@@ -0,0 +1,631 @@
1
+.align 2
2
+.text
3
+
4
+.global m_animation_table
5
+m_animation_table:
6
+
7
+.word 0x081C6F34 @0
8
+.word 0x081C6F34 @1
9
+.word 0x081CFCEA @2
10
+.word 0x081C6F65 @3
11
+.word 0x081C7E63 @4
12
+.word 0x081C7CED @5
13
+.word 0x081C9455 @6
14
+.word 0x081D08B5 @7
15
+.word 0x081CD2E0 @8
16
+.word 0x081CD6CA @9
17
+.word 0x081CD97A @10
18
+.word 0x081C9381 @11
19
+.word 0x081C93C9 @12
20
+.word 0x081D15B9 @13
21
+.word 0x081C8644 @14
22
+.word 0x081C832A @15
23
+.word 0x081CF648 @16
24
+.word 0x081CF699 @17
25
+.word 0x081C9989 @18
26
+.word 0x081CFC1D @19
27
+.word 0x081D0D00 @20
28
+.word 0x081C8AA9 @21
29
+.word 0x081C8B31 @22
30
+.word 0x081C82CA @23
31
+.word 0x081CFE98 @24
32
+.word 0x081C7DC7 @25
33
+.word 0x081CFDA5 @26
34
+.word 0x081CA1DA @27
35
+.word 0x081CDF22 @28
36
+.word 0x081CA25D @29
37
+.word 0x081CA2BA @30
38
+.word 0x081CA327 @31
39
+.word 0x081CA3A4 @32
40
+.word 0x081C7492 @33
41
+.word 0x081C74D0 @34
42
+.word 0x081D0D3A @35
43
+.word 0x081C7886 @36
44
+.word 0x081CA521 @37
45
+.word 0x081C791A @38
46
+.word 0x081C8311 @39
47
+.word 0x081C7A2D @40
48
+.word 0x081C7A82 @41
49
+.word 0x081C76FC @42
50
+.word 0x081D09C8 @43
51
+.word 0x081CE190 @44
52
+.word 0x081CDB57 @45
53
+.word 0x081CDAC0 @46
54
+.word 0x081CA5A0 @47
55
+.word 0x081C755D @48
56
+.word 0x081C7EDB @49
57
+.word 0x081D169F @50
58
+.word 0x081CF308 @51
59
+.word 0x081C7C79 @52
60
+.word 0x081CFA15 @53
61
+.word 0x081D0821 @54
62
+.word 0x081CF87A @55
63
+.word 0x081CE9EE @56
64
+.word 0x081CFA01 @57
65
+.word 0x081CE2FB @58
66
+.word 0x081CE768 @59
67
+.word 0x081D0D50 @60
68
+.word 0x081C9D13 @61
69
+.word 0x081CE43F @62
70
+.word 0x081D29A7 @63
71
+.word 0x081CF736 @64
72
+.word 0x081C8B68 @65
73
+.word 0x081D029C @66
74
+.word 0x081CA674 @67
75
+.word 0x081D005A @68
76
+.word 0x081D472C @69
77
+.word 0x081C73FE @70
78
+.word 0x081CEBD5 @71
79
+.word 0x081CECED @72
80
+.word 0x081C7C23 @73
81
+.word 0x081C9953 @74
82
+.word 0x081D058C @75
83
+.word 0x081CE513 @76
84
+.word 0x081C6FB8 @77
85
+.word 0x081C70E9 @78
86
+.word 0x081C7217 @79
87
+.word 0x081D0454 @80
88
+.word 0x081D1446 @81
89
+.word 0x081CE068 @82
90
+.word 0x081C8836 @83
91
+.word 0x081C7F3C @84
92
+.word 0x081C7FAA @85
93
+.word 0x081C8160 @86
94
+.word 0x081CD570 @87
95
+.word 0x081C9AFF @88
96
+.word 0x081CA6D1 @89
97
+.word 0x081CA71E @90
98
+.word 0x081CA841 @91
99
+.word 0x081CF131 @92
100
+.word 0x081CD40B @93
101
+.word 0x081CD46C @94
102
+.word 0x081D0DEA @95
103
+.word 0x081CA95D @96
104
+.word 0x081CA97A @97
105
+.word 0x081CA9C4 @98
106
+.word 0x081CAA1C @99
107
+.word 0x081CAA92 @100
108
+.word 0x081D11BB @101
109
+.word 0x081D1777 @102
110
+.word 0x081C75B5 @103
111
+.word 0x081CAAAB @104
112
+.word 0x081D16CD @105
113
+.word 0x081CD0AB @106
114
+.word 0x081CAAF2 @107
115
+.word 0x081C9EB0 @108
116
+.word 0x081C9A31 @109
117
+.word 0x081CE432 @110
118
+.word 0x081C8F1C @111
119
+.word 0x081CDD2D @112
120
+.word 0x081CDC28 @113
121
+.word 0x081D0882 @114
122
+.word 0x081CDCDA @115
123
+.word 0x081D1307 @116
124
+.word 0x081D1347 @117
125
+.word 0x081CAB05 @118
126
+.word 0x081C6F34 @119
127
+.word 0x081C89B9 @120
128
+.word 0x081D1203 @121
129
+.word 0x081D12E0 @122
130
+.word 0x081CDE20 @123
131
+.word 0x081CF1A0 @124
132
+.word 0x081CF456 @125
133
+.word 0x081C7AF5 @126
134
+.word 0x081C8BC1 @127
135
+.word 0x081CE29E @128
136
+.word 0x081C7345 @129
137
+.word 0x081CAB2F @130
138
+.word 0x081C8591 @131
139
+.word 0x081D17C1 @132
140
+.word 0x081CABF5 @133
141
+.word 0x081CAC19 @134
142
+.word 0x081D18E9 @135
143
+.word 0x081CFE02 @136
144
+.word 0x081CAC6A @137
145
+.word 0x081D0A1F @138
146
+.word 0x081D0C22 @139
147
+.word 0x081CACD3 @140
148
+.word 0x081CF085 @141
149
+.word 0x081D1C6C @142
150
+.word 0x081CAD1B @143
151
+.word 0x081D2811 @144
152
+.word 0x081CDD4A @145
153
+.word 0x081C86FC @146
154
+.word 0x081D03EF @147
155
+.word 0x081CAEB3 @148
156
+.word 0x081D0E4A @149
157
+.word 0x081CAEC0 @150
158
+.word 0x081CAED5 @151
159
+.word 0x081CF907 @152
160
+.word 0x081C8E15 @153
161
+.word 0x081D1CB3 @154
162
+.word 0x081CF402 @155
163
+.word 0x081CD3CB @156
164
+.word 0x081C9B8B @157
165
+.word 0x081D2165 @158
166
+.word 0x081CAEEE @159
167
+.word 0x081C9FA9 @160
168
+.word 0x081D21CC @161
169
+.word 0x081CAEFA @162
170
+.word 0x081CAF7B @163
171
+.word 0x081D3433 @164
172
+.word 0x081CAFB5 @165
173
+.word 0x081CB01B @166
174
+.word 0x081CFECB @167
175
+.word 0x081C9CCC @168
176
+.word 0x081D1518 @169
177
+.word 0x081CD1A8 @170
178
+.word 0x081CB043 @171
179
+.word 0x081C7602 @172
180
+.word 0x081CDB98 @173
181
+.word 0x081D1829 @174
182
+.word 0x081CB099 @175
183
+.word 0x081CA0BE @176
184
+.word 0x081CF75D @177
185
+.word 0x081D0395 @178
186
+.word 0x081C8445 @179
187
+.word 0x081CB0D6 @180
188
+.word 0x081CE8F4 @181
189
+.word 0x081C8F55 @182
190
+.word 0x081CB105 @183
191
+.word 0x081D1BA0 @184
192
+.word 0x081CDE9B @185
193
+.word 0x081D1C03 @186
194
+.word 0x081CD0C0 @187
195
+.word 0x081CF1E2 @188
196
+.word 0x081CDFCA @189
197
+.word 0x081D07BB @190
198
+.word 0x081CF503 @191
199
+.word 0x081D0ED0 @192
200
+.word 0x081CB18D @193
201
+.word 0x081CB1CC @194
202
+.word 0x081D1F41 @195
203
+.word 0x081C9DF0 @196
204
+.word 0x081C8F72 @197
205
+.word 0x081CF4B8 @198
206
+.word 0x081C9A84 @199
207
+.word 0x081C94A8 @200
208
+.word 0x081CFAB2 @201
209
+.word 0x081CEE7D @202
210
+.word 0x081CB227 @203
211
+.word 0x081CB2BB @204
212
+.word 0x081CB2FE @205
213
+.word 0x081CB33F @206
214
+.word 0x081CB3C6 @207
215
+.word 0x081CB40E @208
216
+.word 0x081C9643 @209
217
+.word 0x081C88EA @210
218
+.word 0x081D0FB5 @211
219
+.word 0x081C9ABA @212
220
+.word 0x081C985A @213
221
+.word 0x081D20AA @214
222
+.word 0x081D196B @215
223
+.word 0x081D36FA @216
224
+.word 0x081D1DC8 @217
225
+.word 0x081C8FD0 @218
226
+.word 0x081C9297 @219
227
+.word 0x081C92D9 @220
228
+.word 0x081CD793 @221
229
+.word 0x081CB450 @222
230
+.word 0x081CFF92 @223
231
+.word 0x081CF55A @224
232
+.word 0x081CD9AC @225
233
+.word 0x081D1F1F @226
234
+.word 0x081D23FE @227
235
+.word 0x081C8520 @228
236
+.word 0x081CB4E1 @229
237
+.word 0x081D28BD @230
238
+.word 0x081D1064 @231
239
+.word 0x081D1128 @232
240
+.word 0x081D0129 @233
241
+.word 0x081D2829 @234
242
+.word 0x081CF107 @235
243
+.word 0x081CB54E @236
244
+.word 0x081C835C @237
245
+.word 0x081CFD3C @238
246
+.word 0x081D4D0E @239
247
+.word 0x081CE145 @240
248
+.word 0x081D033F @241
249
+.word 0x081CE1EE @242
250
+.word 0x081CDCB4 @243
251
+.word 0x081C868A @244
252
+.word 0x081CB5DE @245
253
+.word 0x081D0693 @246
254
+.word 0x081D129D @247
255
+.word 0x081CD4CF @248
256
+.word 0x081D01A4 @249
257
+.word 0x081CFB3A @250
258
+.word 0x081C81CF @251
259
+.word 0x081D1B65 @252
260
+.word 0x081CB69C @253
261
+.word 0x081D256B @254
262
+.word 0x081D2622 @255
263
+.word 0x081D2765 @256
264
+.word 0x081CB766 @257
265
+.word 0x081CB816 @258
266
+.word 0x081CB84E @259
267
+.word 0x081D2AE9 @260
268
+.word 0x081D2340 @261
269
+.word 0x081CB892 @262
270
+.word 0x081CB8D6 @263
271
+.word 0x081D3633 @264
272
+.word 0x081CB8F6 @265
273
+.word 0x081CB951 @266
274
+.word 0x081D0693 @267
275
+.word 0x081CB970 @268
276
+.word 0x081CBA0B @269
277
+.word 0x081CBA5F @270
278
+.word 0x081D24A5 @271
279
+.word 0x081D2BE5 @272
280
+.word 0x081D2523 @273
281
+.word 0x081CBAD2 @274
282
+.word 0x081D1D17 @275
283
+.word 0x081CBB43 @276
284
+.word 0x081D4889 @277
285
+.word 0x081CBBFE @278
286
+.word 0x081D335D @279
287
+.word 0x081CBC32 @280
288
+.word 0x081CBE37 @281
289
+.word 0x081D4A0F @282
290
+.word 0x081CBE7A @283
291
+.word 0x081CBEEF @284
292
+.word 0x081CBFBC @285
293
+.word 0x081CC007 @286
294
+.word 0x081D2C42 @287
295
+.word 0x081CC04A @288
296
+.word 0x081D414F @289
297
+.word 0x081D4CBA @290
298
+.word 0x081D4169 @291
299
+.word 0x081D2E93 @292
300
+.word 0x081CC072 @293
301
+.word 0x081CC0B8 @294
302
+.word 0x081CC0FB @295
303
+.word 0x081CC212 @296
304
+.word 0x081CC2A1 @297
305
+.word 0x081CC371 @298
306
+.word 0x081D2C85 @299
307
+.word 0x081CC3DC @300
308
+.word 0x081D4F8E @301
309
+.word 0x081CC513 @302
310
+.word 0x081CC6C3 @303
311
+.word 0x081D2D0D @304
312
+.word 0x081D33F4 @305
313
+.word 0x081CC6DB @306
314
+.word 0x081D3C0E @307
315
+.word 0x081D45B2 @308
316
+.word 0x081D32D6 @309
317
+.word 0x081D46E4 @310
318
+.word 0x081D515D @311
319
+.word 0x081CC74B @312
320
+.word 0x081CC8AD @313
321
+.word 0x081CC93D @314
322
+.word 0x081D42C0 @315
323
+.word 0x081CC99F @316
324
+.word 0x081D3E50 @317
325
+.word 0x081D3F37 @318
326
+.word 0x081D35E3 @319
327
+.word 0x081CC9E9 @320
328
+.word 0x081CCADC @321
329
+.word 0x081D3B89 @322
330
+.word 0x081CCB48 @323
331
+.word 0x081CEAED @324
332
+.word 0x081CCB76 @325
333
+.word 0x081CCBD1 @326
334
+.word 0x081D4BC1 @327
335
+.word 0x081D2D96 @328
336
+.word 0x081D2E6E @329
337
+.word 0x081D2F28 @330
338
+.word 0x081D2F3A @331
339
+.word 0x081CCC39 @332
340
+.word 0x081C77C1 @333
341
+.word 0x081CCCA3 @334
342
+.word 0x081CCCCD @335
343
+.word 0x081CCCDC @336
344
+.word 0x081D2FD0 @337
345
+.word 0x081D343F @338
346
+.word 0x081CCCFE @339
347
+.word 0x081CFC87 @340
348
+.word 0x081D3239 @341
349
+.word 0x081D10C2 @342
350
+.word 0x081CCD1C @343
351
+.word 0x081CCD79 @344
352
+.word 0x081D4E6D @345
353
+.word 0x081CCE71 @346
354
+.word 0x081CCE97 @347
355
+.word 0x081CCF17 @348
356
+.word 0x081CCF9A @349
357
+.word 0x081D4223 @350
358
+.word 0x081CD009 @351
359
+.word 0x081D48A6 @352
360
+.word 0x081D4A9F @353
361
+.word 0x081D499B @354
362
+.word 0x081C6F34 @355
363
+.word 0x081C6F34 @356
364
+.word 0x081C6F34 @357
365
+.word 0x081C6F34 @358
366
+.word 0x081C6F34 @359
367
+.word 0x081C6F34 @360
368
+.word 0x081C6F34 @361
369
+.word 0x081C6F34 @362
370
+.word 0x081C6F34 @363
371
+.word 0x081C6F34 @364
372
+.word 0x081C6F34 @365
373
+.word 0x081C6F34 @366
374
+.word 0x081C6F34 @367
375
+.word 0x081C6F34 @368
376
+.word 0x081C6F34 @369
377
+.word 0x081C6F34 @370
378
+.word 0x081C6F34 @371
379
+.word 0x081C6F34 @372
380
+.word 0x081C6F34 @373
381
+.word 0x081C6F34 @374
382
+.word 0x081C6F34 @375
383
+.word 0x081C6F34 @376
384
+.word 0x081C6F34 @377
385
+.word 0x081C6F34 @378
386
+.word 0x081C6F34 @379
387
+.word 0x081C6F34 @380
388
+.word 0x081C6F34 @381
389
+.word 0x081C6F34 @382
390
+.word 0x081C6F34 @383
391
+.word 0x081C6F34 @384
392
+.word 0x081C6F34 @385
393
+.word 0x081C6F34 @386
394
+.word 0x081C6F34 @387
395
+.word 0x081C6F34 @388
396
+.word 0x081C6F34 @389
397
+.word 0x081C6F34 @390
398
+.word 0x081C6F34 @391
399
+.word 0x081C6F34 @392
400
+.word 0x081C6F34 @393
401
+.word 0x081C6F34 @394
402
+.word 0x081C6F34 @395
403
+.word 0x081C6F34 @396
404
+.word 0x081C6F34 @397
405
+.word 0x081C6F34 @398
406
+.word 0x081C6F34 @399
407
+.word 0x081C6F34 @400
408
+.word 0x081C6F34 @401
409
+.word 0x081C6F34 @402
410
+.word 0x081C6F34 @403
411
+.word 0x081C6F34 @404
412
+.word 0x081C6F34 @405
413
+.word 0x081C6F34 @406
414
+.word 0x081C6F34 @407
415
+.word 0x081C6F34 @408
416
+.word 0x081C6F34 @409
417
+.word 0x081C6F34 @410
418
+.word 0x081C6F34 @411
419
+.word 0x081C6F34 @412
420
+.word 0x081C6F34 @413
421
+.word 0x081C6F34 @414
422
+.word 0x081C6F34 @415
423
+.word 0x081C6F34 @416
424
+.word 0x081C6F34 @417
425
+.word 0x081C6F34 @418
426
+.word 0x081C6F34 @419
427
+.word 0x081C6F34 @420
428
+.word 0x081C6F34 @421
429
+.word anim_thunder_fang @422
430
+.word anim_ice_fang @423
431
+.word anim_fire_fang @424
432
+.word 0x081C6F34 @425
433
+.word 0x081C6F34 @426
434
+.word 0x081C6F34 @427
435
+.word 0x081C6F34 @428
436
+.word 0x081C6F34 @429
437
+.word 0x081C6F34 @430
438
+.word 0x081C6F34 @431
439
+.word 0x081C6F34 @432
440
+.word 0x081C6F34 @433
441
+.word 0x081C6F34 @434
442
+.word 0x081C6F34 @435
443
+.word 0x081C6F34 @436
444
+.word 0x081C6F34 @437
445
+.word 0x081C6F34 @438
446
+.word 0x081C6F34 @439
447
+.word 0x081C6F34 @440
448
+.word 0x081C6F34 @441
449
+.word 0x081C6F34 @442
450
+.word 0x081C6F34 @443
451
+.word 0x081C6F34 @444
452
+.word 0x081C6F34 @445
453
+.word 0x081C6F34 @446
454
+.word 0x081C6F34 @447
455
+.word 0x081C6F34 @448
456
+.word 0x081C6F34 @449
457
+.word 0x081C6F34 @450
458
+.word 0x081C6F34 @451
459
+.word 0x081C6F34 @452
460
+.word 0x081C6F34 @453
461
+.word 0x081C6F34 @454
462
+.word 0x081C6F34 @455
463
+.word 0x081C6F34 @456
464
+.word 0x081C6F34 @457
465
+.word 0x081C6F34 @458
466
+.word 0x081C6F34 @459
467
+.word 0x081C6F34 @460
468
+.word 0x081C6F34 @461
469
+.word 0x081C6F34 @462
470
+.word 0x081C6F34 @463
471
+.word 0x081C6F34 @464
472
+.word 0x081C6F34 @465
473
+.word 0x081C6F34 @466
474
+.word 0x081C6F34 @467
475
+.word 0x081C6F34 @468
476
+.word 0x081C6F34 @469
477
+.word 0x081C6F34 @470
478
+.word 0x081C6F34 @471
479
+.word 0x081C6F34 @472
480
+.word 0x081C6F34 @473
481
+.word 0x081C6F34 @474
482
+.word 0x081C6F34 @475
483
+.word 0x081C6F34 @476
484
+.word 0x081C6F34 @477
485
+.word 0x081C6F34 @478
486
+.word 0x081C6F34 @479
487
+.word 0x081C6F34 @480
488
+.word 0x081C6F34 @481
489
+.word 0x081C6F34 @482
490
+.word 0x081C6F34 @483
491
+.word 0x081C6F34 @484
492
+.word 0x081C6F34 @485
493
+.word 0x081C6F34 @486
494
+.word 0x081C6F34 @487
495
+.word 0x081C6F34 @488
496
+.word 0x081C6F34 @489
497
+.word 0x081C6F34 @490
498
+.word 0x081C6F34 @491
499
+.word 0x081C6F34 @492
500
+.word 0x081C6F34 @493
501
+.word 0x081C6F34 @494
502
+.word 0x081C6F34 @495
503
+.word 0x081C6F34 @496
504
+.word 0x081C6F34 @497
505
+.word 0x081C6F34 @498
506
+.word 0x081C6F34 @499
507
+.word 0x081C6F34 @500
508
+.word 0x081C6F34 @501
509
+.word 0x081C6F34 @502
510
+.word 0x081C6F34 @503
511
+.word 0x081C6F34 @504
512
+.word 0x081C6F34 @505
513
+.word 0x081C6F34 @506
514
+.word 0x081C6F34 @507
515
+.word 0x081C6F34 @508
516
+.word 0x081C6F34 @509
517
+.word 0x081C6F34 @510
518
+.word 0x081C6F34 @511
519
+.word 0x081C6F34 @512
520
+.word 0x081C6F34 @513
521
+.word 0x081C6F34 @514
522
+.word 0x081C6F34 @515
523
+.word 0x081C6F34 @516
524
+.word 0x081C6F34 @517
525
+.word 0x081C6F34 @518
526
+.word 0x081C6F34 @519
527
+.word 0x081C6F34 @520
528
+.word 0x081C6F34 @521
529
+.word 0x081C6F34 @522
530
+.word 0x081C6F34 @523
531
+.word 0x081C6F34 @524
532
+.word 0x081C6F34 @525
533
+.word 0x081C6F34 @526
534
+.word 0x081C6F34 @527
535
+.word 0x081C6F34 @528
536
+.word 0x081C6F34 @529
537
+.word 0x081C6F34 @530
538
+.word 0x081C6F34 @531
539
+.word 0x081C6F34 @532
540
+.word 0x081C6F34 @533
541
+.word 0x081C6F34 @534
542
+.word 0x081C6F34 @535
543
+.word 0x081C6F34 @536
544
+.word 0x081C6F34 @537
545
+.word 0x081C6F34 @538
546
+.word 0x081C6F34 @539
547
+.word 0x081C6F34 @540
548
+.word 0x081C6F34 @541
549
+.word 0x081C6F34 @542
550
+.word 0x081C6F34 @543
551
+.word 0x081C6F34 @544
552
+.word 0x081C6F34 @545
553
+.word 0x081C6F34 @546
554
+.word 0x081C6F34 @547
555
+.word 0x081C6F34 @548
556
+.word 0x081C6F34 @549
557
+.word 0x081C6F34 @550
558
+.word 0x081C6F34 @551
559
+.word 0x081C6F34 @552
560
+.word 0x081C6F34 @553
561
+.word 0x081C6F34 @554
562
+.word 0x081C6F34 @555
563
+.word 0x081C6F34 @556
564
+.word 0x081C6F34 @557
565
+.word 0x081C6F34 @558
566
+.word 0x081C6F34 @559
567
+.word 0x081C6F34 @560
568
+.word 0x081C6F34 @561
569
+.word 0x081C6F34 @562
570
+.word 0x081C6F34 @563
571
+.word 0x081C6F34 @564
572
+.word 0x081C6F34 @565
573
+.word 0x081C6F34 @566
574
+.word 0x081C6F34 @567
575
+.word 0x081C6F34 @568
576
+.word 0x081C6F34 @569
577
+.word 0x081C6F34 @570
578
+.word 0x081C6F34 @571
579
+.word 0x081C6F34 @572
580
+.word 0x081C6F34 @573
581
+.word 0x081C6F34 @574
582
+.word 0x081C6F34 @575
583
+.word 0x081C6F34 @576
584
+.word 0x081C6F34 @577
585
+.word 0x081C6F34 @578
586
+.word 0x081C6F34 @579
587
+.word 0x081C6F34 @580
588
+.word 0x081C6F34 @581
589
+.word 0x081C6F34 @582
590
+.word 0x081C6F34 @583
591
+.word 0x081C6F34 @584
592
+.word 0x081C6F34 @585
593
+.word 0x081C6F34 @586
594
+.word 0x081C6F34 @587
595
+.word 0x081C6F34 @588
596
+.word 0x081C6F34 @589
597
+.word 0x081C6F34 @590
598
+.word 0x081C6F34 @591
599
+.word 0x081C6F34 @592
600
+.word 0x081C6F34 @593
601
+.word 0x081C6F34 @594
602
+.word 0x081C6F34 @595
603
+.word 0x081C6F34 @596
604
+.word 0x081C6F34 @597
605
+.word 0x081C6F34 @598
606
+.word 0x081C6F34 @599
607
+.word 0x081C6F34 @600
608
+.word 0x081C6F34 @601
609
+.word 0x081C6F34 @602
610
+.word 0x081C6F34 @603
611
+.word 0x081C6F34 @604
612
+.word 0x081C6F34 @605
613
+.word 0x081C6F34 @606
614
+.word 0x081C6F34 @607
615
+.word 0x081C6F34 @608
616
+.word 0x081C6F34 @609
617
+.word 0x081C6F34 @610
618
+.word 0x081C6F34 @611
619
+.word 0x081C6F34 @612
620
+.word 0x081C6F34 @613
621
+.word 0x081C6F34 @614
622
+.word 0x081C6F34 @615
623
+.word 0x081C6F34 @616
624
+.word 0x081C6F34 @617
625
+.word 0x081C6F34 @618
626
+.word 0x081C6F34 @619
627
+.word 0x081C6F34 @620
628
+.word 0x081C6F34 @621
629
+.word 0x081C6F34 @622
630
+.word 0x081C6F34 @623
631
+.word 0x081C6F34 @624

+ 220
- 0
data/effect_table.S View File

@@ -0,0 +1,220 @@
1
+.align 2
2
+.text
3
+.thumb
4
+
5
+.global m_effect_table
6
+m_effect_table:
7
+	.word 0x081D6900 @0
8
+	.word 0x081D696D @1
9
+	.word 0x081D69DC @2
10
+	.word 0x081D69E7 @3
11
+	.word 0x081D6A55 @4
12
+	.word 0x081D6A60 @5
13
+	.word 0x081D6A6B @6
14
+	.word 0x081D6A76 @7
15
+	.word 0x081D6AF6 @8
16
+	.word 0x081D6B5F @9
17
+	.word 0x081D6B77 @10
18
+	.word 0x081D6B82 @11
19
+	.word 0x081D6900 @12
20
+	.word 0x081D6B8D @13
21
+	.word 0x081D6900 @14
22
+	.word 0x081D6900 @15
23
+	.word 0x081D6B98 @16
24
+	.word 0x081D6900 @17
25
+	.word 0x081D6BE1 @18
26
+	.word 0x081D6BEC @19
27
+	.word 0x081D6BF7 @20
28
+	.word 0x081D6900 @21
29
+	.word 0x081D6900 @22
30
+	.word 0x081D6C02 @23
31
+	.word 0x081D6C0D @24
32
+	.word 0x081D6C72 @25
33
+	.word 0x081D6C83 @26
34
+	.word 0x081D6C97 @27
35
+	.word 0x081D6CB1 @28
36
+	.word 0x081D6CD9 @29
37
+	.word 0x081D6D9D @30
38
+	.word script_fang_flinch @31 (FLINCH + FIRE/ICE/THUNDER FANG FANG)
39
+	.word 0x081D6DBD @32
40
+	.word 0x081D6DE0 @33
41
+	.word 0x081D6E69 @34
42
+	.word 0x081D6E74 @35
43
+	.word 0x081D6E7D @36
44
+	.word 0x081D6E88 @37
45
+	.word 0x081D6ED0 @38
46
+	.word 0x081D6F01 @39
47
+	.word 0x081D6F82 @40
48
+	.word 0x081D6F99 @41
49
+	.word 0x081D6FC8 @42
50
+	.word 0x081D6900 @43
51
+	.word 0x081D6FF9 @44
52
+	.word 0x081D7011 @45
53
+	.word 0x081D7062 @46
54
+	.word 0x081D7075 @47
55
+	.word 0x081D7092 @48
56
+	.word 0x081D70AB @49
57
+	.word 0x081D70F8 @50
58
+	.word 0x081D7103 @51
59
+	.word 0x081D710E @52
60
+	.word 0x081D7119 @53
61
+	.word 0x081D7124 @54
62
+	.word 0x081D6900 @55
63
+	.word 0x081D6900 @56
64
+	.word 0x081D712F @57
65
+	.word 0x081D7142 @58
66
+	.word 0x081D714D @59
67
+	.word 0x081D7158 @60
68
+	.word 0x081D6900 @61
69
+	.word 0x081D7163 @62
70
+	.word 0x081D6900 @63
71
+	.word 0x081D6900 @64
72
+	.word 0x081D716E @65
73
+	.word 0x081D7181 @66
74
+	.word 0x081D71E2 @67
75
+	.word 0x081D725F @68
76
+	.word 0x081D726A @69
77
+	.word 0x081D7275 @70
78
+	.word 0x081D7280 @71
79
+	.word 0x081D728B @72
80
+	.word 0x081D7296 @73
81
+	.word 0x081D6900 @74
82
+	.word 0x081D72A1 @75
83
+	.word 0x081D72C9 @76
84
+	.word 0x081D72D4 @77
85
+	.word 0x081D6900 @78
86
+	.word 0x081D72EC @79
87
+	.word 0x081D732F @80
88
+	.word 0x081D734D @81
89
+	.word 0x081D7374 @82
90
+	.word 0x081D739A @83
91
+	.word 0x081D73AE @84
92
+	.word 0x081D73D5 @85
93
+	.word 0x081D73E7 @86
94
+	.word 0x081D7403 @87
95
+	.word 0x081D741B @88
96
+	.word 0x081D7433 @89
97
+	.word 0x081D7449 @90
98
+	.word 0x081D7465 @91
99
+	.word 0x081D749C @92
100
+	.word 0x081D74D6 @93
101
+	.word 0x081D74EB @94
102
+	.word 0x081D750D @95
103
+	.word 0x081D6900 @96
104
+	.word 0x081D752C @97
105
+	.word 0x081D756E @98
106
+	.word 0x081D757F @99
107
+	.word 0x081D7585 @100
108
+	.word 0x081D6900 @101
109
+	.word 0x081D75A1 @102
110
+	.word 0x081D6900 @103
111
+	.word 0x081D75E6 @104
112
+	.word 0x081D76C9 @105
113
+	.word 0x081D76D4 @106
114
+	.word 0x081D7706 @107
115
+	.word 0x081D7740 @108
116
+	.word 0x081D774D @109
117
+	.word 0x081D6900 @110
118
+	.word 0x081D7816 @111
119
+	.word 0x081D7829 @112
120
+	.word 0x081D783E @113
121
+	.word 0x081D7856 @114
122
+	.word 0x081D7897 @115
123
+	.word 0x081D7816 @116
124
+	.word 0x081D78A0 @117
125
+	.word 0x081D78BB @118
126
+	.word 0x081D7919 @119
127
+	.word 0x081D7938 @120
128
+	.word 0x081D7954 @121
129
+	.word 0x081D7962 @122
130
+	.word 0x081D7954 @123
131
+	.word 0x081D796E @124
132
+	.word 0x081D7977 @125
133
+	.word 0x081D7982 @126
134
+	.word 0x081D7995 @127
135
+	.word 0x081D6900 @128
136
+	.word 0x081D79C2 @129
137
+	.word 0x081D79CD @130
138
+	.word 0x081D6900 @131
139
+	.word 0x081D79FC @132
140
+	.word 0x081D79FC @133
141
+	.word 0x081D79FC @134
142
+	.word 0x081D7A09 @135
143
+	.word 0x081D7A10 @136
144
+	.word 0x081D7A28 @137
145
+	.word 0x081D7A31 @138
146
+	.word 0x081D7A3C @139
147
+	.word 0x081D7A47 @140
148
+	.word 0x081D6900 @141
149
+	.word 0x081D7A52 @142
150
+	.word 0x081D7A74 @143
151
+	.word 0x081D7A89 @144
152
+	.word 0x081D7A9F @145
153
+	.word 0x081D7AEE @146
154
+	.word 0x081D7B13 @147
155
+	.word 0x081D7B97 @148
156
+	.word 0x081D7BAE @149
157
+	.word 0x081D7BCD @150
158
+	.word 0x081D7BE3 @151
159
+	.word 0x081D7C39 @152
160
+	.word 0x081D7C4D @153
161
+	.word 0x081D7C8A @154
162
+	.word 0x081D7CE1 @155
163
+	.word 0x081D7D8C @156
164
+	.word 0x081D7DAE @157
165
+	.word 0x081D7DDF @158
166
+	.word 0x081D7E16 @159
167
+	.word 0x081D7E36 @160
168
+	.word 0x081D7E49 @161
169
+	.word 0x081D7E8B @162
170
+	.word 0x081D6900 @163
171
+	.word 0x081D7EA8 @164
172
+	.word 0x081D7EB1 @165
173
+	.word 0x081D7ECD @166
174
+	.word 0x081D7F2B @167
175
+	.word 0x081D7F9F @168
176
+	.word 0x081D8042 @169
177
+	.word 0x081D805C @170
178
+	.word 0x081D806E @171
179
+	.word 0x081D8098 @172
180
+	.word 0x081D80A9 @173
181
+	.word 0x081D80B6 @174
182
+	.word 0x081D80C7 @175
183
+	.word 0x081D80E3 @176
184
+	.word 0x081D80F8 @177
185
+	.word 0x081D8126 @178
186
+	.word 0x081D8142 @179
187
+	.word 0x081D8152 @180
188
+	.word 0x081D8169 @181
189
+	.word 0x081D817E @182
190
+	.word 0x081D8189 @183
191
+	.word 0x081D819E @184
192
+	.word 0x081D81B3 @185
193
+	.word 0x081D81B9 @186
194
+	.word 0x081D820A @187
195
+	.word 0x081D8263 @188
196
+	.word 0x081D826E @189
197
+	.word 0x081D82A9 @190
198
+	.word 0x081D82AF @191
199
+	.word 0x081D82CB @192
200
+	.word 0x081D82E0 @193
201
+	.word 0x081D82F7 @194
202
+	.word 0x081D830C @195
203
+	.word 0x081D8324 @196
204
+	.word 0x081D8334 @197
205
+	.word 0x081D833A @198
206
+	.word 0x081D8345 @199
207
+	.word 0x081D6A55 @200
208
+	.word 0x081D83F3 @201
209
+	.word 0x081D840A @202
210
+	.word 0x081D8415 @203
211
+	.word 0x081D841B @204
212
+	.word 0x081D8426 @205
213
+	.word 0x081D84AD @206
214
+	.word 0x081D8511 @207
215
+	.word 0x081D851F @208
216
+	.word 0x081D69DC @209
217
+	.word 0x081D83F3 @210
218
+	.word 0x081D8583 @211
219
+	.word 0x081D85FB @212
220
+	.word 0x081D865F @213

+ 1207
- 0
data/pkmn_tables/icon_sprites.S
File diff suppressed because it is too large
View File


+ 1206
- 0
data/pkmn_tables/icons_paletten.S
File diff suppressed because it is too large
View File


BIN
data/pkmn_tables/pkmn_enemy_altitude_table_dump.bin View File


BIN
data/pkmn_tables/pkmn_enemy_y_table_dump.bin View File


+ 1
- 0
data/pkmn_tables/pkmn_names_dump.bin
File diff suppressed because it is too large
View File


BIN
data/pkmn_tables/pkmn_player_y_table_dump.bin View File


+ 4337
- 0
data/pkmn_tables/pokedex_daten.S
File diff suppressed because it is too large
View File


+ 1205
- 0
data/pkmn_tables/pokedex_order.S
File diff suppressed because it is too large
View File


+ 2901
- 0
data/pkmn_tables/pokedex_texte.S
File diff suppressed because it is too large
View File


+ 1205
- 0
data/pkmn_tables/pokemon_back_sprites.S
File diff suppressed because it is too large
View File


+ 4253
- 0
data/pkmn_tables/pokemon_egg_moves.S
File diff suppressed because it is too large
View File


+ 7
- 0
data/pkmn_tables/pokemon_enemy_altitude_table.s View File

@@ -0,0 +1,7 @@
1
+.align 2
2
+.thumb
3
+.text
4
+
5
+.global pkmn_enemy_altitude_table
6
+pkmn_enemy_altitude_table:
7
+.incbin "data/pkmn_tables/pkmn_enemy_altitude_table_dump.bin"

+ 7
- 0
data/pkmn_tables/pokemon_enemy_y_table.s View File

@@ -0,0 +1,7 @@
1
+.align 2
2
+.thumb
3
+.text
4
+
5
+.global pkmn_enemy_y_table
6
+pkmn_enemy_y_table:
7
+.incbin "data/pkmn_tables/pkmn_enemy_y_table_dump.bin"

+ 1205
- 0
data/pkmn_tables/pokemon_evolution.s
File diff suppressed because it is too large
View File


+ 2012
- 0
data/pkmn_tables/pokemon_footprints.s
File diff suppressed because it is too large
View File


+ 1205
- 0
data/pkmn_tables/pokemon_front_sprites.S
File diff suppressed because it is too large
View File


+ 1203
- 0
data/pkmn_tables/pokemon_move_tutor.s
File diff suppressed because it is too large
View File


+ 27794
- 0
data/pkmn_tables/pokemon_moveset_table.S
File diff suppressed because it is too large
View File


+ 7
- 0
data/pkmn_tables/pokemon_names.S View File

@@ -0,0 +1,7 @@
1
+.align 2
2
+.thumb
3
+.text
4
+
5
+.global pokemon_names
6
+pokemon_names:
7
+.incbin "data/pkmn_tables/pkmn_names_dump.bin"

+ 1205
- 0
data/pkmn_tables/pokemon_normal_pal.S
File diff suppressed because it is too large
View File


+ 7
- 0
data/pkmn_tables/pokemon_player_y_table.s View File

@@ -0,0 +1,7 @@
1
+.align 2
2
+.thumb
3
+.text
4
+
5
+.global pkmn_player_y_table
6
+pkmn_player_y_table:
7
+.incbin "data/pkmn_tables/pkmn_player_y_table_dump.bin"

+ 1205
- 0
data/pkmn_tables/pokemon_shiny_pal.S
File diff suppressed because it is too large
View File


+ 4804
- 0
data/pkmn_tables/pokemon_stats.S
File diff suppressed because it is too large
View File


+ 24
- 0
icons.makefile View File

@@ -0,0 +1,24 @@
1
+AS = arm-none-eabi-as
2
+LD = arm-none-eabi-ld
3
+
4
+GFX_BUILD_DIR = gfx_build
5
+
6
+ICON_AR = object/pkmn_icons.a
7
+I_ASSET_ROOT = sots-private/assets
8
+ICON_FILES = $(wildcard $(I_ASSET_ROOT)/pkmn_icons/*.png)
9
+OBJ_FILES = $(addprefix $(GFX_BUILD_DIR)/icons/,$(notdir $(ICON_FILES:.png=.o)))
10
+
11
+all: $(ICON_AR)
12
+
13
+.PHONY: clean
14
+clean:
15
+	rm -f $(ICON_AR) $(GFX_BUILD_DIR)/icons/*
16
+
17
+$(ICON_AR): $(OBJ_FILES)
18
+	$(AR) rcs $@ $^
19
+
20
+$(GFX_BUILD_DIR)/icons/%.o: $(GFX_BUILD_DIR)/icons/%.s
21
+	$(AS) -o $@ $<
22
+
23
+$(GFX_BUILD_DIR)/icons/%.s: $(I_ASSET_ROOT)/pkmn_icons/%.png
24
+	grit $< -fts -fh! -g -gB 4 -gt -gz! -m! -p! -s icon_$(notdir $(basename $<)) -o $@

+ 29
- 0
linker.ld View File

@@ -0,0 +1,29 @@
1
+OUTPUT_ARCH(arm)
2
+MEMORY {
3
+
4
+        rom     : ORIGIN = 0x09000000, LENGTH = 16M
5
+        ewram   : ORIGIN = 0x02000000, LENGTH = 4M - 4k
6
+}
7
+
8
+SECTIONS {
9
+        .text : {
10
+
11
+                FILL (0xABCD)
12
+                __text_start = . ;
13
+                *(.init)
14
+                *(.text)
15
+                *(.ctors)
16
+                *(.dtors)
17
+                *(.rodata)
18
+                *(.fini)
19
+                *(COMMON)
20
+                __text_end  = . ;
21
+                *(.data)
22
+                __bss_start__ = . ;
23
+                *(.bss)
24
+                __bss_end__ = . ;
25
+                __file_end__ = . ;
26
+        _end = __file_end__ ;
27
+        __end__ = __file_end__ ;
28
+        } >rom = 0xff
29
+}

+ 32
- 0
main.asm View File

@@ -0,0 +1,32 @@
1
+.gba
2
+.thumb
3
+.open "base/bpre0.gba","build/Pokémon SotS.gba",0x08000000
4
+
5
+.loadtable "strings/de_DE/table.tbl"
6
+
7
+.include "patches/split_physical_special.asm"
8
+.include "patches/hooks.asm"
9
+.include "patches/dynamic_overworld_hooks.asm"
10
+.include "patches/special.asm"
11
+.include "patches/moves.asm"
12
+.include "patches/music.asm"
13
+
14
+//.include "strings/de_DE/pkmn_names.asm"
15
+.include "patches/pokemon_data/pokedex_order.asm"
16
+.include "patches/pokemon_data/pokedex.asm"
17
+.include "patches/pokemon_data/pokemon_egg_moves.asm"
18
+.include "patches/pokemon_data/pokedex_entries.asm"
19
+.include "patches/pokemon_data/pokemon_names.asm"
20
+.include "patches/pokemon_data/limits.asm"
21
+.include "patches/pokemon_data/pokemon_stats.asm"
22
+.include "patches/pokemon_data/moveset_table.asm"
23
+.include "patches/pokemon_data/pokemon_back_sprites.asm"
24
+.include "patches/pokemon_data/pokemon_front_sprites.asm"
25
+.include "patches/pokemon_data/pokemon_normal_pal.asm"
26
+.include "patches/pokemon_data/pokemon_shiny_pal.asm"
27
+.include "patches/pokemon_data/pokemon_icons.asm"
28
+
29
+
30
+.org 0x09000000
31
+.importobj "object/linked.o"
32
+.close

+ 115
- 0
makefile View File

@@ -0,0 +1,115 @@
1
+AS      := arm-none-eabi-as
2
+LD      := arm-none-eabi-ld
3
+OBJCOPY := arm-none-eabi-objcopy
4
+GRIT    := grit
5
+CC      := arm-none-eabi-gcc
6
+ARS     := armips
7
+MAKE    := make
8
+NM      := arm-none-eabi-nm
9
+
10
+export PATH := $(realpath ../tools):$(PATH)
11
+
12
+DEFINES   := -DBPRE -DSOFTWARE_VERSION=0
13
+ASFLAGS   := -mthumb
14
+CFLAGS    := -mthumb -mno-thumb-interwork -mcpu=arm7tdmi -fno-inline -mlong-calls -march=armv4t -O3 -std=gnu99 -Isrc/include $(DEFINES)
15
+GRITFLAGS := -ftc -fa
16
+LDFLAGS   := -z muldefs
17
+BLDPATH   := object
18
+OUTPATH	  := build
19
+SOURCEDIR := src
20
+
21
+MAIN_OBJ  := $(BLDPATH)/linked.o
22
+SPRITES   := $(BLDPATH)/pkmn_sprites.o
23
+ICONS_AR  := $(BLDPATH)/pkmn_icons.a
24
+DYN_OVER  := $(BLDPATH)/dynamic_overworld.o
25
+
26
+SND_ROOT := sots-private/sound
27
+MUSIC_AR := $(SND_ROOT)/Music/music.a
28
+SMPL_AR  := $(SND_ROOT)/Samples/sample.a
29
+VOICE_AR := $(SND_ROOT)/Voicegroup/voice.a
30
+LIST_AR  := $(SND_ROOT)/Songtable/songlist.a
31
+CRY_AR   := $(SND_ROOT)/Crys/cry.a
32
+
33
+rwildcard=$(wildcard $1$2) $(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2))
34
+
35
+ASM_SRC_PP  := $(call rwildcard,src/,*.S)
36
+ASM_SRC     := $(call rwildcard,src/,*.s)
37
+C_SRC       := $(call rwildcard,src/,*.c)
38
+DATA_SRC_PP := $(call rwildcard,data/,*.S)
39
+DATA_SRC    := $(call rwildcard,data/,*.s)
40
+
41
+ASM_OBJ_PP  := $(ASM_SRC_PP:%.S=$(BLDPATH)/%.o)
42
+ASM_OBJ     := $(ASM_SRC:%.s=$(BLDPATH)/%.o)
43
+C_OBJ       := $(C_SRC:%.c=$(BLDPATH)/%.o)
44
+DATA_OBJ_PP := $(DATA_SRC_PP:%.S=$(BLDPATH)/%.o)
45
+DATA_OBJ    := $(DATA_SRC:%.s=$(BLDPATH)/%.o)
46
+ALL_OBJ     := $(C_OBJ) $(ASM_OBJ_PP) $(ASM_OBJ) $(DATA_OBJ_PP) $(DATA_OBJ)
47
+
48
+
49
+$(BLDPATH)/%.o: %.c $(ASSETS)
50
+	$(shell mkdir -p $(dir $@))
51
+	$(CC) $(CFLAGS) -c $< -o $@
52
+
53
+$(BLDPATH)/%.o: %.S
54
+	$(shell mkdir -p $(dir $@))
55
+	$(CC) $(CFLAGS) -c $< -o $@
56
+
57
+$(BLDPATH)/%.o: %.s
58
+	$(shell mkdir -p $(dir $@))
59
+	$(AS) $(ASFLAGS) $< -o $@
60
+
61
+all: rom
62
+
63
+.PHONY: rom
64
+rom: main.asm $(MAIN_OBJ)
65
+	$(ARS) $<
66
+	$(NM) $(BLDPATH)/linked.o -n -g --defined-only | \
67
+		sed -e '{s/^/0x/g};{/.*\sA\s.*/d};{s/\sT\s/ /g}' > $(OUTPATH)/__symbols.sym
68
+	@echo "*** SUCCESSFULLY BUILT PROJECT ***"
69
+
70
+$(MAIN_OBJ): $(ALL_OBJ) $(ICONS_AR) $(SPRITES) $(DYN_OVER) $(MUSIC_AR) $(SMPL_AR) $(VOICE_AR) $(LIST_AR) $(CRY_AR) "built/dynamic_overworld.o"
71
+	$(LD) $(LDFLAGS) -T linker.ld -T bpre.sym --whole-archive -r -o $@ --start-group $^ --end-group
72
+
73
+.PHONY: clean
74
+clean:
75
+	rm -R -f build/*
76
+	rm -R -f object/*
77
+	$(MAKE) -C $(dir $(MUSIC_AR)) clean
78
+	$(MAKE) -C $(dir $(SMPL_AR)) clean
79
+	$(MAKE) -C $(dir $(VOICE_AR)) clean
80
+	$(MAKE) -C $(dir $(LIST_AR)) clean
81
+	$(MAKE) -C $(dir $(CRY_AR)) clean
82
+	$(MAKE) -f sprites.makefile clean
83
+	$(MAKE) -f icons.makefile clean
84
+
85
+.PHONY: $(ASSETS)
86
+$(ASSETS):
87
+	$(MAKE) -f assets.makefile
88
+
89
+.PHONY: $(SPRITES)
90
+$(SPRITES):
91
+	$(MAKE) -f sprites.makefile
92
+
93
+.PHONY: $(ICONS_AR)
94
+$(ICONS_AR):
95
+	$(MAKE) -f icons.makefile
96
+
97
+.PHONY: $(MUSIC_AR)
98
+$(MUSIC_AR):
99
+	$(MAKE) -C $(dir $@) all
100
+
101
+.PHONY: $(SMPL_AR)
102
+$(SMPL_AR):
103
+	$(MAKE) -C $(dir $@) all
104
+
105
+.PHONY: $(VOICE_AR)
106
+$(VOICE_AR):
107
+	$(MAKE) -C $(dir $@) all
108
+
109
+.PHONY: $(LIST_AR)
110
+$(LIST_AR):
111
+	$(MAKE) -C $(dir $@) all
112
+
113
+.PHONY: $(CRY_AR)
114
+$(CRY_AR):
115
+	$(MAKE) -C $(dir $@) all

+ 43
- 0
patches/disable_cry_table_blocks.s View File

@@ -0,0 +1,43 @@
1
+.gba
2
+cry_variable equ 0x02037ECC
3
+cry_handler equ 0x081DE638 + 1
4
+
5
+disableCryTableBlocks:		//  BPED =$080A35BC	; BPRE =$080720C8
6
+
7
+MOV		R1, R0
8
+MOV		R0, #0xC
9
+MUL		R0, R1
10
+MOV		R3, R9
11
+CMP		R3, #0
12
+BEQ		forward_cry
13
+
14
+reverse_cry:
15
+
16
+LDR		R1,=_reverse_crytable
17
+B		calc_table_entry
18
+
19
+forward_cry:
20
+
21
+LDR		R1,=_forward_crytable
22
+
23
+calc_table_entry:
24
+
25
+ADD		R0, R0, R1
26
+BL		call_cry_handler
27
+LDR		R1,=cry_variable
28
+STR		R0, [R1]
29
+
30
+ADD		SP, SP, #4
31
+POP		{R3-R5}
32
+MOV		R8, R3
33
+MOV		R9, R4
34
+MOV		R10, R5
35
+POP		{R4-R7}
36
+POP		{R0}
37
+BX		R0
38
+
39
+call_cry_handler:
40
+
41
+LDR		R1,=cry_handler
42
+BX		R1
43
+.pool

+ 250
- 0
patches/dynamic_overworld_hooks.asm View File

@@ -0,0 +1,250 @@
1
+.org 0x5f574 + 0x08000000
2
+ldr r0, =ClearAllPalettes|1
3
+bx r0
4
+.pool
5
+
6
+.org 0x89e8 + 0x08000000
7
+ldr r1, =FindPalette|1
8
+bx r1
9
+.pool
10
+
11
+.org 0x8928 + 0x08000000
12
+ldr r1, =FindOrLoadPalette|1
13
+bx r1
14
+.pool
15
+
16
+.org 0xdc9e0 + 0x08000000
17
+ldr r3, =SetUpTreeDisguise|1
18
+bx r3
19
+.pool
20
+
21
+.org 0xdc9f0 + 0x08000000
22
+ldr r3, =SetUpRockDisguise|1
23
+bx r3
24
+.pool
25
+
26
+.org 0xdca00 + 0x08000000
27
+ldr r3, =SetUpWeirdDisguise|1
28
+bx r3
29
+.pool
30
+
31
+.org 0x7a748 + 0x08000000
32
+ldr r1, =PaletteNeedsFogBrightening|1
33
+bx r1
34
+.pool
35
+
36
+.org 0x7abc0 + 0x08000000
37
+ldr r1, =LoadCloudOrSandstormPalette|1
38
+bx r1
39
+.pool
40
+
41
+.org 0x5e6b0 + 0x08000000
42
+ldr r0, =SetPalNPC1|1
43
+bx r0
44
+.pool
45
+
46
+.org 0x5ef78 + 0x08000000
47
+ldr r0, =SetPalNPC2|1
48
+bx r0
49
+.pool
50
+
51
+.org 0x5eab0 + 0x08000000
52
+ldr r0, =SetPalNPC3|1
53
+bx r0
54
+.pool
55
+
56
+.org 0x5ebc0 + 0x08000000
57
+ldr r0, =SetPalNPC4|1
58
+bx r0
59
+.pool
60
+
61
+.org 0xdadb4 + 0x08000000
62
+ldr r2, =SetPalReflection|1
63
+bx r2
64
+.pool
65
+
66
+.org 0xdc410 + 0x08000000
67
+ldr r2, =SetPalSurf|1
68
+bx r2
69
+.pool
70
+
71
+.org 0x87188 + 0x08000000
72
+ldr r1, =SetPalFly|1
73
+bx r1
74
+.pool
75
+
76
+.org 0x12d2ac + 0x08000000
77
+ldr r0, =RefreshFameCheckerNPCs|1
78
+bx r0
79
+.pool
80
+
81
+.org 0x71b8 + 0x08000000
82
+ldr r0, =SetPalMisc|1
83
+bx r0
84
+.pool
85
+
86
+.org 0x82664 + 0x08000000
87
+ldr r3, =SetPalEmotionBubble|1
88
+bx r3
89
+.pool
90
+
91
+.org 0xdb1ac + 0x08000000
92
+ldr r3, =SetPalWarpArrow|1
93
+bx r3
94
+.pool
95
+
96
+.org 0x13f434 + 0x08000000
97
+ldr r0, =SetPalItemfinderArrow|1
98
+bx r0
99
+.pool
100
+
101
+.org 0x12d7a8 + 0x08000000
102
+ldr r1, =SetPalFameCheckerUnknown|1
103
+bx r1
104
+.pool
105
+
106
+.org 0x7a2d0 + 0x08000000
107
+ldr r0, =GetDarkeningType1|1
108
+bx r0
109
+.pool
110
+
111
+.org 0x7a428 + 0x08000000
112
+ldr r0, =GetDarkeningType2|1
113
+bx r0
114
+.pool
115
+
116
+.org 0x7a544 + 0x08000000
117
+ldr r0, =GetDarkeningType3|1
118
+bx r0
119
+.pool
120
+
121
+.org 0x7aec4 + 0x08000000
122
+ldr r1, =FogBrightenAll|1
123
+bx r1
124
+.pool
125
+
126
+.org 0x7aaac + 0x08000000
127
+ldr r0, =FogBrightenOnStep|1
128
+bx r0
129
+.pool
130
+
131
+.org 0x7a644 + 0x08000000
132
+ldr r0, =FogBrightenAndFadeIn|1
133
+bx r0
134
+.pool
135
+
136
+.org 0x7a0a8 + 0x08000000
137
+ldr r1, =GetFadeType1|1
138
+bx r1
139
+.pool
140
+
141
+.org 0x7a860 + 0x08000000
142
+ldr r2, =GetFadeType2|1
143
+bx r2
144
+.pool
145
+
146
+.org 0x9d5a8 + 0x08000000
147
+ldr r2, =SetPalFossilImage|1
148
+bx r2
149
+.pool
150
+
151
+.org 0x9d538 + 0x08000000
152
+ldr r1, =LoadPalFossilImage|1
153
+bx r1
154
+.pool
155
+
156
+.org 0x9d568 + 0x08000000
157
+ldr r1, =LoadPalFossilImage|1
158
+bx r1
159
+.pool
160
+
161
+.org 0x15d4e8 + 0x08000000
162
+ldr r2, =SetPalSSAnneWake|1
163
+bx r2
164
+.pool
165
+
166
+.org 0x15d600 + 0x08000000
167
+ldr r2, =SetPalSSAnneSmoke|1
168
+bx r2
169
+.pool
170
+
171
+.org 0x7280 + 0x08000000
172
+ldr r1, =DeleteOBJ|1
173
+bx r1
174
+.pool
175
+
176
+.org 0xdaf88 + 0x08000000
177
+ldr r0, =DeleteReflection|1
178
+bx r0
179
+.pool
180
+
181
+.org 0xdb120 + 0x08000000
182
+ldr r0, =DeleteWarpArrow|1
183
+bx r0
184
+.pool
185
+
186
+//don't auto-load npc palettes into slot 0 or 0xA
187
+.org 0x0805F5E8
188
+bx lr
189
+
190
+.org 0x0805F658
191
+bx lr
192
+
193
+.org 0x080DAEC4
194
+bx lr
195
+
196
+.org 0x080DAF20
197
+bx lr
198
+
199
+.org 0x0805F093
200
+.byte 0xE0
201
+
202
+//don't reset pal slot during player animation or reflection
203
+.org 0x0805F114
204
+lsl r0, #0x0
205
+
206
+.org 0x080DAFB8
207
+lsl r0, #0
208
+
209
+//don't load rain palette on entering map
210
+.org 0x08079C18
211
+.byte 0x0
212
+.byte 0x25
213
+.byte 0xE
214
+.byte 0xE0
215
+
216
+//don't load sand palette on healing
217
+.org 0x081D9895
218
+.byte 0x7
219
+.byte 0x9C
220
+.byte 0xBE
221
+.byte 0x3C
222
+.byte 0x8
223
+.byte 0x8D
224
+.byte 0x3B
225
+.byte 0x8
226
+.byte 0x8
227
+.byte 0x4
228
+
229
+//don't treat slot 0xC as weather palette
230
+.org 0x0807A31F
231
+.byte 0xE0
232
+
233
+//don't record brightened slots
234
+.org 0x0807AAE7
235
+.byte 0xE0
236
+
237
+//pal slot of scroll arrow in frame checker
238
+.org 0x0845FD52
239
+.byte 0x9
240
+
241
+//make it compatible with daniilS snowflakes routine
242
+.org 0x0807A85E
243
+.byte 0x80
244
+.byte 0x18
245
+
246
+.org 0x0807A872
247
+.byte 1
248
+.byte 0x22
249
+.byte 0x5
250
+.byte 0xE0

+ 217
- 0
patches/hooks.asm View File

@@ -0,0 +1,217 @@
1
+//Ipatix sound stuff
2
+  .org 0x080007B4
3
+    .word  0x0203E000   // new PCM work area
4
+  .org 0x081DD0B4
5
+    .word  main_mixer   // new mixer ROM location
6
+    .word  0x03005F50   // new mixer RAM location (used for loading)
7
+    .halfword mixer_size
8
+    .halfword 0x400        // CpuSet, copy code by 32 bit units
9
+    .word  0x0203E000   // new PCM work area
10
+  .org 0x081DD0C8
11
+     // set correct sound driver operation mode
12
+     // 12 channels at 26758 Hz samplerate
13
+    .byte  0x00, 0xCC, 0x98, 0x00
14
+  .org 0x081DC094
15
+    .word  0x03005F50+1 // new mixer RAM location (used for branch)
16
+
17
+   // repoint correctly to the new cry tables
18
+  .org 0x080720C8
19
+  .include "patches/disable_cry_table_blocks.s"
20
+
21
+   // cry-ID = poke-ID
22
+  .org 0x08043304
23
+  LSL	R0, R0, #0x10
24
+  LSR	R0, R0, #0x10
25
+  BX  LR
26
+
27
+   // music overrides
28
+  .org 0x081DD0F4
29
+    LDR R1, =music_override|1
30
+    BX R1
31
+  .pool
32
+
33
+
34
+
35
+//End of sound stuff
36
+
37
+//Don't know what thats all about... leaving it commented for now
38
+//.org 0x0800f268
39
+//    .halfword 0xE000
40
+
41
+//Battle bg use new table
42
+.org 0x0800F2A0
43
+    .word battle_bg_table
44
+
45
+.org 0x0800F2E0
46
+    .word battle_bg_table
47
+
48
+.org 0x0800F320
49
+    .word battle_bg_table
50
+
51
+.org 0x0800F40E
52
+    ldr r0, =battle_bg_hook|1
53
+    bx r0
54
+    lsl r0, #0
55
+	.pool
56
+
57
+.org 0x0800FD5C
58
+    .word battle_bg_table
59
+
60
+.org 0x0800FD88
61
+    .word battle_bg_table
62
+//end of battle bg table
63
+
64
+//flag routine
65
+.org 0x0806E5D6
66
+	ldr r0, =flag_hook|1
67
+	bx r0
68
+	lsl r0, #0
69
+	.pool
70
+//end of flag routine
71
+
72
+//var routine
73
+.org 0x0806E45C
74
+    ldr r0,=var_hook+1
75
+    bx r0
76
+	.pool
77
+
78
+//end of var routine
79
+
80
+//trainer Flag stuff
81
+.org 0x08080382
82
+	mov r1, #0x80
83
+	lsl r1, #0x15
84
+
85
+.org 0x080800BA
86
+	mov r2, #0x80
87
+	lsl r2, #0x5
88
+
89
+.org 0x08080428
90
+    mov r1, #0x80
91
+    lsl r1, #0x15
92
+
93
+.org 0x08080440
94
+    mov r1, #0x80
95
+    lsl r1, #0x15
96
+
97
+.org 0x08080454
98
+    mov r1, #0x80
99
+    lsl r1, #0x15
100
+//end of trainer flag stuff
101
+
102
+//New behavior bytes for jumping
103
+
104
+.org 0x0806811A
105
+	ldr r0,=jump_behavior|1
106
+	bx r0
107
+	.pool
108
+
109
+//behavior walk stuff
110
+.org 0x0806D720
111
+	ldr r0,=on_step|1
112
+	bx r0
113
+	.pool
114
+
115
+//end of new behavior bytes for jumping
116
+
117
+//transparent textboxes and mugshots
118
+.org 0x08069410
119
+    bx r0
120
+
121
+.org 0x0806941C
122
+    .word trans_activate|1
123
+
124
+.org 0x08069504
125
+    bx r1
126
+
127
+.org 0x0806950C
128
+    .word trans_deactivate|1
129
+
130
+.org 0x08150000
131
+    ldr r0, =pal_load_hook_2|1
132
+    bx r0
133
+	.pool
134
+
135
+.org 0x0815044A
136
+    bx r1
137
+
138
+.org 0x08150450
139
+    .word pal_load_hook|1
140
+
141
+.org 0x0809CEB2
142
+    ldr r0, =trans_mug_close_fix+1
143
+    bx r0
144
+    lsl r0, #0
145
+	.pool
146
+
147
+//end of transparent textboxes and mugshots
148
+
149
+//saveblock routine start
150
+
151
+.org 0x080D9EDC
152
+    ldr r0, =load_hijack|1
153
+    bx r0
154
+	.pool
155
+
156
+.org 0x080d991E
157
+    bx r7
158
+.org 0x080d995C
159
+    .word store_hijack|1
160
+
161
+.org 0x083FEC94
162
+.include "patches/save_table/save_table.S"
163
+
164
+//end of saveblock routine
165
+//new battle script commands
166
+	//replace tables
167
+.org 0x08014C1C
168
+	.word bs_command_table
169
+.org 0x08015A28
170
+	.word bs_command_table
171
+.org 0x08015C6C
172
+	.word bs_command_table
173
+.org 0x08015C98
174
+	.word bs_command_table
175
+.org 0x0801D054
176
+	.word bs_command_table
177
+
178
+//end of new battle script commands
179
+
180
+//move effect table
181
+
182
+.org 0x08016364
183
+	.word m_effect_table
184
+.org 0x08023328
185
+	.word m_effect_table
186
+.org 0x08025CF8
187
+	.word m_effect_table
188
+.org 0x08027464
189
+	.word m_effect_table
190
+.org 0x080297F0
191
+	.word m_effect_table
192
+.org 0x0802BE80
193
+	.word m_effect_table
194
+
195
+//end of move effect table
196
+
197
+//move limits
198
+
199
+.org 0x080D75FC
200
+	.byte 0,0,0,0,0,0
201
+
202
+//end of move limits
203
+
204
+//print string mod
205
+
206
+.org 0x080D77C0
207
+	bx r1
208
+
209
+.org 0x080D77CC
210
+	.word custom_print_string|1
211
+
212
+//end of print string mod
213
+
214
+//new move animation table
215
+.org 0x080725d0
216
+    .word m_animation_table
217
+//end of new move animation table

+ 20
- 0
patches/moves.asm View File

@@ -0,0 +1,20 @@
1
+//new learning_moveset
2
+
3
+.org 0x0803EB20
4
+    ldr r1, =new_move_first|1
5
+	bx r1
6
+
7
+.org 0x0803EB84
8
+	.pool
9
+
10
+.org 0x0803EA10
11
+	ldr r1, =new_move_second|1
12
+	bx r1
13
+	.pool
14
+
15
+.org 0x08043CE8
16
+	ldr r2, =new_move_third|1
17
+	bx r2
18
+	.pool
19
+
20
+//end of new learning moveset

+ 14
- 0
patches/music.asm View File

@@ -0,0 +1,14 @@
1
+.org 0x081DD11C
2
+.word _songtable
3
+
4
+.org 0x081DD150
5
+.word _songtable
6
+
7
+.org 0x081DD19C
8
+.word _songtable
9
+
10
+.org 0x081DD1F0
11
+.word _songtable
12
+
13
+.org 0x081DD224
14
+.word _songtable

+ 12
- 0
patches/pokemon_data/altitude_table.asm View File

@@ -0,0 +1,12 @@
1
+.org 0x080356F8
2
+.word altitude_table
3
+
4
+.org 0x0803575C
5
+.word altitude_table
6
+
7
+.org 0x08074794
8
+.word altitude_table
9
+
10
+.org 0x080747A8
11
+.word altitude_table
12
+

+ 48
- 0
patches/pokemon_data/enemy_y_table.asm View File

@@ -0,0 +1,48 @@
1
+.org 0x08011F4C
2
+.word enemy_y_table
3
+
4
+.org 0x08011F80
5
+.word enemy_y_table
6
+
7
+.org 0x08011FAC
8
+.word enemy_y_table
9
+
10
+.org 0x080477E0
11
+.word enemy_y_table
12
+
13
+.org 0x08051410
14
+.word enemy_y_table
15
+
16
+.org 0x08052120
17
+.word enemy_y_table
18
+
19
+.org 0x08052800
20
+.word enemy_y_table
21
+
22
+.org 0x0805357C
23
+.word enemy_y_table
24
+
25
+.org 0x08074700
26
+.word enemy_y_table
27
+
28
+.org 0x08074734
29
+.word enemy_y_table
30
+
31
+.org 0x08074748
32
+.word enemy_y_table
33
+
34
+.org 0x080765A8
35
+.word enemy_y_table
36
+
37
+.org 0x08076AD8
38
+.word enemy_y_table
39
+
40
+.org 0x08076CD4
41
+.word enemy_y_table
42
+
43
+.org 0x08076CF0
44
+.word enemy_y_table
45
+
46
+.org 0x0814A938
47
+.word enemy_y_table
48
+

+ 34
- 0
patches/pokemon_data/limits.asm View File

@@ -0,0 +1,34 @@
1
+//name table limit
2
+.org 0x08041000
3
+.byte 0,0,0,0,0,0
4
+
5
+//sprite table limit
6
+.org 0x0800ED72
7
+.byte 0x07, 0xE0
8
+
9
+.org 0x0800F1B6
10
+.byte 0x07, 0xE0
11
+
12
+//pal table limit
13
+.org 0x08044104
14
+.byte 0x04, 0xE0
15
+
16
+//height and altitude limit
17
+.org 0x0807472E
18
+.byte 0x03, 0xE0
19
+
20
+.org 0x0807465E
21
+.byte 0x03, 0xE0
22
+
23
+.org 0x08074788
24
+.byte 0x06, 0xE0
25
+
26
+//icon limits
27
+.org 0x08096F90
28
+.halfword 0x0000
29
+
30
+.org 0x08096E7A
31
+.word 0x00000000
32
+
33
+.org 0x080971DA
34
+.halfword 0x0000

+ 18
- 0
patches/pokemon_data/moveset_table.asm View File

@@ -0,0 +1,18 @@
1
+.org 0x0803EA7C
2
+.word moveset_table
3
+
4
+.org 0x0803EB10
5
+.word moveset_table
6
+
7
+.org 0x08043DC8
8
+.word moveset_table
9
+
10
+.org 0x08043E20
11
+.word moveset_table
12
+
13
+.org 0x08043F84
14
+.word moveset_table
15
+
16
+//Im not fully sure of why or how this works but it does
17
+.org 0x0803EAE8
18
+.byte 0x2E, 0xD1

+ 24
- 0
patches/pokemon_data/player_y_table.asm View File

@@ -0,0 +1,24 @@
1
+.org 0x08074634
2
+.word player_y_table
3
+
4
+.org 0x08074664
5
+.word player_y_table
6
+
7
+.org 0x08074670
8
+.word player_y_table
9
+
10
+.org 0x08076564
11
+.word player_y_table
12
+
13
+.org 0x08076B1C
14
+.word player_y_table
15
+
16
+.org 0x08076BE8
17
+.word player_y_table
18
+
19
+.org 0x08076BF8
20
+.word player_y_table
21
+
22
+.org 0x08076C04
23
+.word player_y_table
24
+

+ 48
- 0
patches/pokemon_data/pokedex.asm View File

@@ -0,0 +1,48 @@
1
+.org 0x08104B10
2
+.word 0x0203C000 //Pokédex SEEN flags
3
+
4
+.org 0x08104B00
5
+.halfword 0x0000
6
+
7
+.org 0x08104B02
8
+.halfword 0x0000
9
+
10
+.org 0x08104B5C
11
+.word 0x0203C100 //Pokédex CAUGHT flags
12
+
13
+.org 0x08104B16
14
+.halfword 0x0000
15
+
16
+.org 0x08104B18
17
+.halfword 0x0000
18
+
19
+.org 0x08104B1A
20
+.halfword 0x0000
21
+
22
+.org 0x08104B26
23
+.halfword 0xE016
24
+
25
+.org 0x08104B34
26
+.halfword 0xE00F
27
+
28
+.org 0x08104B94
29
+.word 0x0203C000 //Pokédex SEEN flags
30
+.word 0x0203C000 //Pokédex SEEN flags
31
+
32
+.org 0x08104B6A
33
+.halfword 0x1C01
34
+
35
+.org 0x08104B6C
36
+.halfword 0x0000
37
+
38
+.org 0x08104B78
39
+.halfword 0xE01A
40
+
41
+.org 0x08104BB8 //Pokédex  CAUGHT flags
42
+.word 0x0203C100
43
+
44
+.org 0x08104BA2
45
+.halfword 0x1C01 
46
+
47
+.org 0x08104BA4
48
+.halfword 0x0000

+ 23
- 0
patches/pokemon_data/pokedex_entries.asm View File

@@ -0,0 +1,23 @@
1
+.org 0x08088e34
2
+.word pokedex_data
3
+
4
+.org 0x08088e5c
5
+.word pokedex_data
6
+
7
+.org 0x08088e70
8
+.word pokedex_data
9
+
10
+.org 0x08105860
11
+.word pokedex_data
12
+
13
+.org 0x08105974
14
+.word pokedex_data
15
+
16
+.org 0x08105ACC
17
+.word pokedex_data
18
+
19
+.org 0x08105D44
20
+.word pokedex_data
21
+
22
+.org 0x081066C8
23
+.word pokedex_data

+ 17
- 0
patches/pokemon_data/pokedex_order.asm View File

@@ -0,0 +1,17 @@
1
+.org 0x0804323C
2
+.word pokedex_order
3
+
4
+.org 0x080432B0
5
+.word pokedex_order
6
+
7
+.org 0x081025EC
8
+.byte 0xC0			//1/4 dex length more or less
9
+
10
+.org 0x081025EE
11
+.halfword 0x0140	//fix alloc
12
+
13
+.org 0x08103920
14
+.halfword 0x2CF
15
+
16
+.org 0x08043220
17
+.halfword 0x0000	//break limit

+ 30
- 0
patches/pokemon_data/pokemon_back_sprites.asm View File

@@ -0,0 +1,30 @@
1
+.org 0x0800012C
2
+.word pokemon_back_sprites
3
+
4
+.org 0x0800ED58
5
+.word pokemon_back_sprites
6
+
7
+.org 0x0800F19C
8
+.word pokemon_back_sprites
9
+
10
+.org 0x08034540
11
+.word pokemon_back_sprites
12
+
13
+.org 0x08034584
14
+.word pokemon_back_sprites
15
+
16
+.org 0x08034F04
17
+.word pokemon_back_sprites
18
+
19
+.org 0x08076A58
20
+.word pokemon_back_sprites
21
+
22
+.org 0x08076AC8
23
+.word pokemon_back_sprites
24
+
25
+.org 0x0810BC0C
26
+.word pokemon_back_sprites
27
+
28
+.org 0x0810BC24
29
+.word pokemon_back_sprites
30
+

+ 8
- 0
patches/pokemon_data/pokemon_egg_moves.asm View File

@@ -0,0 +1,8 @@
1
+.org 0x08045C50
2
+.word pokemon_egg_moves
3
+
4
+.org 0x08045CC8
5
+.word pokemon_egg_moves
6
+
7
+.org 0x08045CC4
8
+.byte 20

+ 84
- 0
patches/pokemon_data/pokemon_front_sprites.asm View File

@@ -0,0 +1,84 @@
1
+.org 0x08000128
2
+.word pokemon_front_sprites
3
+
4
+.org 0x0800ECA8
5
+.word pokemon_front_sprites
6
+
7
+.org 0x0800ECEC
8
+.word pokemon_front_sprites
9
+
10
+.org 0x0800ED68
11
+.word pokemon_front_sprites
12
+
13
+.org 0x0800ED80
14
+.word pokemon_front_sprites
15
+
16
+.org 0x0800F0F8
17
+.word pokemon_front_sprites
18
+
19
+.org 0x0800F130
20
+.word pokemon_front_sprites
21
+
22
+.org 0x0800F1AC
23
+.word pokemon_front_sprites
24
+
25
+.org 0x0800F1C4
26
+.word pokemon_front_sprites
27
+
28
+.org 0x080343C4
29
+.word pokemon_front_sprites
30
+
31
+.org 0x08034D60
32
+.word pokemon_front_sprites
33
+
34
+.org 0x0803507C
35
+.word pokemon_front_sprites
36
+
37
+.org 0x08046F64
38
+.word pokemon_front_sprites
39
+
40
+.org 0x08050074
41
+.word pokemon_front_sprites
42
+
43
+.org 0x080500BC
44
+.word pokemon_front_sprites
45
+
46
+.org 0x08052068
47
+.word pokemon_front_sprites
48
+
49
+.org 0x080534C4
50
+.word pokemon_front_sprites
51
+
52
+.org 0x080769C0
53
+.word pokemon_front_sprites
54
+
55
+.org 0x080769E4
56
+.word pokemon_front_sprites
57
+
58
+.org 0x0808F470
59
+.word pokemon_front_sprites
60
+
61
+.org 0x080CE0B8
62
+.word pokemon_front_sprites
63
+
64
+.org 0x080CE2B8
65
+.word pokemon_front_sprites
66
+
67
+.org 0x080CE454
68
+.word pokemon_front_sprites
69
+
70
+.org 0x080CE6C4
71
+.word pokemon_front_sprites
72
+
73
+.org 0x0810BBE4
74
+.word pokemon_front_sprites
75
+
76
+.org 0x0810BBF0
77
+.word pokemon_front_sprites
78
+
79
+.org 0x0811D900
80
+.word pokemon_front_sprites
81
+
82
+.org 0x0814AED8
83
+.word pokemon_front_sprites
84
+

+ 41
- 0
patches/pokemon_data/pokemon_icons.asm View File

@@ -0,0 +1,41 @@
1
+.org 0x08000138
2
+.word icon_table
3
+
4
+.org 0x08097050
5
+.word icon_table
6
+
7
+.org 0x083D4050
8
+.word icon_table
9
+
10
+.org 0x0800013C
11
+.word icon_palette_table
12
+
13
+.org 0x08091390
14
+.word icon_palette_table
15
+
16
+.org 0x08096EC0
17
+.word icon_palette_table
18
+
19
+.org 0x08096F50
20
+.word icon_palette_table
21
+
22
+.org 0x080970D8
23
+.word icon_palette_table
24
+
25
+.org 0x0809710C
26
+.word icon_palette_table
27
+
28
+.org 0x08097160
29
+.word icon_palette_table
30
+
31
+.org 0x08097184
32
+.word icon_palette_table
33
+
34
+.org 0x080971F4
35
+.word icon_palette_table
36
+
37
+.org 0x08097214
38
+.word icon_palette_table
39
+
40
+.org 0x08097224
41
+.word icon_palette_table

+ 120
- 0
patches/pokemon_data/pokemon_names.asm View File

@@ -0,0 +1,120 @@
1
+.org 0x08000144
2
+.word pokemon_names
3
+
4
+.org 0x08011450
5
+.word pokemon_names
6
+
7
+.org 0x0801150C
8
+.word pokemon_names
9
+
10
+.org 0x080115A4
11
+.word pokemon_names
12
+
13
+.org 0x080116BC
14
+.word pokemon_names
15
+
16
+.org 0x08034D80
17
+.word pokemon_names
18
+
19
+.org 0x08040FEC
20
+.word pokemon_names
21
+
22
+.org 0x080435DC
23
+.word pokemon_names
24
+
25
+.org 0x08049768
26
+.word pokemon_names
27
+
28
+.org 0x08053ADC
29
+.word pokemon_names
30
+
31
+.org 0x08053B44
32
+.word pokemon_names
33
+
34
+.org 0x0806BCC4
35
+.word pokemon_names
36
+
37
+.org 0x0806BD10
38
+.word pokemon_names
39
+
40
+.org 0x08093E8C
41
+.word pokemon_names
42
+
43
+.org 0x0809F560
44
+.word pokemon_names
45
+
46
+.org 0x080A0900
47
+.word pokemon_names
48
+
49
+.org 0x080BD820
50
+.word pokemon_names
51
+
52
+.org 0x080CB120
53
+.word pokemon_names
54
+
55
+.org 0x080CBEAC
56
+.word pokemon_names
57
+
58
+.org 0x080CE0B4
59
+.word pokemon_names
60
+
61
+.org 0x080CE6B8
62
+.word pokemon_names
63
+
64
+.org 0x080CE8D0
65
+.word pokemon_names
66
+
67
+.org 0x080E651C
68
+.word pokemon_names
69
+
70
+.org 0x080F3324
71
+.word pokemon_names
72
+
73
+.org 0x081035C0
74
+.word pokemon_names
75
+
76
+.org 0x08103698
77
+.word pokemon_names
78
+
79
+.org 0x08103738
80
+.word pokemon_names
81
+
82
+.org 0x081037D0
83
+.word pokemon_names
84
+
85
+.org 0x0810386C
86
+.word pokemon_names
87
+
88
+.org 0x081038CC
89
+.word pokemon_names
90
+
91
+.org 0x08104E70
92
+.word pokemon_names
93
+
94
+.org 0x08105FE0
95
+.word pokemon_names
96
+
97
+.org 0x081066B0
98
+.word pokemon_names
99
+
100
+.org 0x08113EFC
101
+.word pokemon_names
102
+
103
+.org 0x08119458
104
+.word pokemon_names
105
+
106
+.org 0x0811ACA0
107
+.word pokemon_names
108
+
109
+.org 0x0811AFF4
110
+.word pokemon_names
111
+
112
+.org 0x0811B048
113
+.word pokemon_names
114
+
115
+.org 0x0812190C
116
+.word pokemon_names
117
+
118
+.org 0x08136318
119
+.word pokemon_names
120
+

+ 15
- 0
patches/pokemon_data/pokemon_normal_pal.asm View File

@@ -0,0 +1,15 @@
1
+.org 0x08000130
2
+.word pokemon_normal_pal
3
+
4
+.org 0x0804410C
5
+.word pokemon_normal_pal
6
+
7
+.org 0x08044130
8
+.word pokemon_normal_pal
9
+
10
+.org 0x080441A4
11
+.word pokemon_normal_pal
12
+
13
+.org 0x080839C0
14
+.word pokemon_normal_pal
15
+

+ 9
- 0
patches/pokemon_data/pokemon_shiny_pal.asm View File

@@ -0,0 +1,9 @@
1
+.org 0x08000134
2
+.word pokemon_shiny_pal
3
+
4
+.org 0x08044144
5
+.word pokemon_shiny_pal
6
+
7
+.org 0x080441B4
8
+.word pokemon_shiny_pal
9
+

+ 174
- 0
patches/pokemon_data/pokemon_stats.asm View File

@@ -0,0 +1,174 @@
1
+.org 0x080001BC
2
+.word pokemon_stats
3
+
4
+.org 0x08012754
5
+.word pokemon_stats
6
+
7
+.org 0x08012FA8
8
+.word pokemon_stats
9
+
10
+.org 0x08013230
11
+.word pokemon_stats
12
+
13
+.org 0x08016A60
14
+.word pokemon_stats
15
+
16
+.org 0x0801F008
17
+.word pokemon_stats
18
+
19
+.org 0x08021C28
20
+.word pokemon_stats
21
+
22
+.org 0x080240B4
23
+.word pokemon_stats
24
+
25
+.org 0x0802BABC
26
+.word pokemon_stats
27
+
28
+.org 0x0802CE90
29
+.word pokemon_stats
30
+
31
+.org 0x0802D53C
32
+.word pokemon_stats
33
+
34
+.org 0x0802FFBC
35
+.word pokemon_stats
36
+
37
+.org 0x080300E8
38
+.word pokemon_stats
39
+
40
+.org 0x080301F8
41
+.word pokemon_stats
42
+
43
+.org 0x08039558
44
+.word pokemon_stats
45
+
46
+.org 0x080399BC
47
+.word pokemon_stats
48
+
49
+.org 0x08039A68
50
+.word pokemon_stats
51
+
52
+.org 0x08039FE8
53
+.word pokemon_stats
54
+
55
+.org 0x0803DCC4
56
+.word pokemon_stats
57
+
58
+.org 0x0803DD94
59
+.word pokemon_stats
60
+
61
+.org 0x0803E734
62
+.word pokemon_stats
63
+
64
+.org 0x0803E82C
65
+.word pokemon_stats
66
+
67
+.org 0x0803E898
68
+.word pokemon_stats
69
+
70
+.org 0x0803F780
71
+.word pokemon_stats
72
+
73
+.org 0x0803F7C8
74
+.word pokemon_stats
75
+
76
+.org 0x08040D58
77
+.word pokemon_stats
78
+
79
+.org 0x08040D78
80
+.word pokemon_stats
81
+
82
+.org 0x080413B8
83
+.word pokemon_stats
84
+
85
+.org 0x080419A0
86
+.word pokemon_stats
87
+
88
+.org 0x08043914
89
+.word pokemon_stats
90
+
91
+.org 0x08043928
92
+.word pokemon_stats
93
+
94
+.org 0x0804393C
95
+.word pokemon_stats
96
+
97
+.org 0x08043950
98
+.word pokemon_stats
99
+
100
+.org 0x08043964
101
+.word pokemon_stats
102
+
103
+.org 0x080439A4
104
+.word pokemon_stats
105
+
106
+.org 0x08043B8C
107
+.word pokemon_stats
108
+
109
+.org 0x08043C10
110
+.word pokemon_stats
111
+
112
+.org 0x08044208
113
+.word pokemon_stats
114
+
115
+.org 0x08044458
116
+.word pokemon_stats
117
+
118
+.org 0x08046600
119
+.word pokemon_stats
120
+
121
+.org 0x08049F4C
122
+.word pokemon_stats
123
+
124
+.org 0x0804FC88
125
+.word pokemon_stats
126
+
127
+.org 0x080C84E0
128
+.word pokemon_stats
129
+
130
+.org 0x080CA850
131
+.word pokemon_stats
132
+
133
+.org 0x080E7F14
134
+.word pokemon_stats
135
+
136
+.org 0x080E8040
137
+.word pokemon_stats
138
+
139
+.org 0x080E8150
140
+.word pokemon_stats
141
+
142
+.org 0x08103AC4
143
+.word pokemon_stats
144
+
145
+.org 0x081066B4
146
+.word pokemon_stats
147
+
148
+.org 0x0811AE48
149
+.word pokemon_stats
150
+
151
+.org 0x081361F8
152
+.word pokemon_stats
153
+
154
+.org 0x08136794
155
+.word pokemon_stats
156
+
157
+.org 0x0813AAE0
158
+.word pokemon_stats
159
+
160
+.org 0x081569EC
161
+.word pokemon_stats
162
+
163
+.org 0x08156B18
164
+.word pokemon_stats
165
+
166
+.org 0x08156C28
167
+.word pokemon_stats
168
+
169
+//EGG HATCHING TIME
170
+.org 0x08046204
171
+.word pokemon_stats + 0x11
172
+
173
+.org 0x080462A8
174
+.word pokemon_stats + 0x11

+ 46
- 0
patches/save_table/save_table.S View File

@@ -0,0 +1,46 @@
1
+//new table data
2
+//500c block
3
+.halfword 0x0
4
+.halfword 0xf24
5
+
6
+//5008 block
7
+.halfword 0x0
8
+.halfword 0xff0
9
+
10
+.halfword 0xff0
11
+.halfword 0xff0
12
+
13
+.halfword 0x1fe0
14
+.halfword 0xff0
15
+
16
+.halfword 0x2fd0
17
+.halfword 0xd98
18
+
19
+//5010 (box) block
20
+
21
+.halfword 0x0
22
+.halfword 0xff0
23
+
24
+.halfword 0xff0
25
+.halfword 0xff0
26
+
27
+.halfword 0x1fe0
28
+.halfword 0xff0
29
+
30
+.halfword 0x2fd0
31
+.halfword 0xff0
32
+
33
+.halfword 0x3fc0
34
+.halfword 0xff0
35
+
36
+.halfword 0x4fb0
37
+.halfword 0xff0
38
+
39
+.halfword 0x5fa0
40
+.halfword 0xff0
41
+
42
+.halfword 0x6f90
43
+.halfword 0xff0
44
+
45
+.halfword 0x7f80
46
+.halfword 0x450

+ 2
- 0
patches/special.asm View File

@@ -0,0 +1,2 @@
1
+.org 0x0815FD60 + (4 * 0x68) //special 0x68
2
+.word special_asm|1

+ 843
- 0
patches/split_physical_special.asm View File

@@ -0,0 +1,843 @@
1
+.org 0x0801DF3F
2
+.byte 0x7A
3
+
4
+.org 0x0801E0C0
5
+.byte 0x00
6
+
7
+.org 0x0801F6C3
8
+.byte 0x7A
9
+
10
+.org 0x0801F908
11
+.byte 0x00 
12
+.byte 0x2E 
13
+.byte 0x41 
14
+.byte 0xD1
15
+
16
+.org 0x0803ECEE
17
+.byte 0x5F 
18
+.byte 0x46 
19
+.byte 0x56 
20
+.byte 0x46 
21
+.byte 0x4D 
22
+.byte 0x46 
23
+.byte 0x44 
24
+.byte 0x46 
25
+.byte 0xF0 
26
+.byte 0xB4 
27
+.byte 0x8B 
28
+.byte 0xB0 
29
+.byte 0x06 
30
+.byte 0x1C 
31
+.byte 0x01 
32
+.byte 0x91 
33
+.byte 0x02 
34
+.byte 0x92 
35
+.byte 0x14 
36
+.byte 0x98 
37
+.byte 0x15 
38
+.byte 0x99 
39
+.byte 0x16 
40
+.byte 0x9A 
41
+.byte 0x17 
42
+.byte 0x9C 
43
+.byte 0x1B 
44
+.byte 0x04 
45
+.byte 0x1B 
46
+.byte 0x0C 
47
+.byte 0x03 
48
+.byte 0x93 
49
+.byte 0x00 
50
+.byte 0x04 
51
+.byte 0x03 
52
+.byte 0x0C 
53
+.byte 0x09 
54
+.byte 0x06 
55
+.byte 0x0F 
56
+.byte 0x0E 
57
+.byte 0x12 
58
+.byte 0x06 
59
+.byte 0x12 
60
+.byte 0x0E 
61
+.byte 0x04 
62
+.byte 0x92 
63
+.byte 0x24 
64
+.byte 0x06 
65
+.byte 0x24 
66
+.byte 0x0E 
67
+.byte 0x00 
68
+.byte 0x25 
69
+.byte 0x00 
70
+.byte 0x2B 
71
+.byte 0x0A 
72
+.byte 0xD1 
73
+.byte 0x0D 
74
+.byte 0x4A 
75
+.byte 0x0D 
76
+.byte 0x49 
77
+.byte 0x02 
78
+.byte 0x9B 
79
+.byte 0x58 
80
+.byte 0x00 
81
+.byte 0xC0 
82
+.byte 0x18 
83
+.byte 0x80 
84
+.byte 0x00 
85
+.byte 0x40 
86
+.byte 0x18 
87
+.byte 0x40 
88
+.byte 0x78 
89
+.byte 0x10 
90
+.byte 0x80 
91
+.byte 0x02 
92
+.byte 0xE0 
93
+.byte 0xFF 
94
+.byte 0xFF 
95
+.byte 0x07 
96
+.byte 0x48 
97
+.byte 0x03 
98
+.byte 0x80 
99
+.byte 0x07 
100
+.byte 0x49 
101
+.byte 0x02 
102
+.byte 0x9A 
103
+.byte 0x50 
104
+.byte 0x00 
105
+.byte 0x80 
106
+.byte 0x18 
107
+.byte 0x80 
108
+.byte 0x00 
109
+.byte 0x40 
110
+.byte 0x18 
111
+.byte 0x82 
112
+.byte 0x7A 
113
+.byte 0x93 
114
+.byte 0x46 
115
+.byte 0x00 
116
+.byte 0x2F 
117
+.byte 0x07 
118
+.byte 0xD1
119
+
120
+.org 0x0803EF06
121
+.byte 0x59 
122
+.byte 0x46 
123
+.byte 0x00
124
+
125
+.org 0x0803F03C
126
+.byte 0x0C
127
+
128
+.org 0x0803F046
129
+.byte 0x07
130
+
131
+.org 0x0803F04E
132
+.byte 0x7F
133
+.byte 0x08 
134
+.byte 0x02 
135
+.byte 0xE0
136
+.byte 0xFF
137
+.byte 0xFF
138
+.byte 0xFF
139
+.byte 0xFF
140
+.byte 0xFF
141
+.byte 0xFF
142
+.byte 0x09
143
+.byte 0x98
144
+.byte 0x04
145
+.byte 0x78
146
+.byte 0x37
147
+.byte 0x2C
148
+.byte 0x01
149
+.byte 0xD1
150
+.byte 0x78
151
+.byte 0x08
152
+.byte 0xC7
153
+.byte 0x19
154
+
155
+.org 0x0803F20A
156
+.byte 0x2B 
157
+.byte 0xE0
158
+
159
+.org 0x0803F20C
160
+.byte 0x00 
161
+.byte 0x00 
162
+.byte 0x00 
163
+.byte 0x00 
164
+.byte 0x00 
165
+.byte 0x00 
166
+.byte 0x00 
167
+.byte 0x00 
168
+.byte 0x00 
169
+.byte 0x00 
170
+.byte 0x00 
171
+.byte 0x00 
172
+.byte 0x00 
173
+.byte 0x00 
174
+.byte 0x00 
175
+.byte 0x00 
176
+.byte 0x00 
177
+.byte 0x00 
178
+.byte 0x00 
179
+.byte 0x00 
180
+.byte 0x00 
181
+.byte 0x00 
182
+.byte 0x00 
183
+.byte 0x00 
184
+.byte 0x00 
185
+.byte 0x00 
186
+.byte 0x00 
187
+.byte 0x00 
188
+.byte 0x00 
189
+.byte 0x00 
190
+.byte 0x00 
191
+.byte 0x00 
192
+.byte 0x00 
193
+.byte 0x00 
194
+.byte 0x00 
195
+.byte 0x00 
196
+.byte 0x00 
197
+.byte 0x00 
198
+.byte 0x00 
199
+.byte 0x00 
200
+.byte 0x00 
201
+.byte 0x00 
202
+.byte 0x00 
203
+.byte 0x00 
204
+.byte 0x00 
205
+.byte 0x00 
206
+.byte 0x00 
207
+.byte 0x00 
208
+.byte 0x00 
209
+.byte 0x00 
210
+.byte 0x00 
211
+.byte 0x00 
212
+.byte 0x00 
213
+.byte 0x00
214
+
215
+.org 0x0803F264
216
+.byte 0x00 
217
+.byte 0x20 
218
+.byte 0x00 
219
+.byte 0x90 
220
+.byte 0x0E 
221
+.byte 0x20 
222
+.byte 0x00 
223
+.byte 0x21 
224
+.byte 0x0D 
225
+.byte 0x22 
226
+.byte 0x00 
227
+.byte 0x23 
228
+.byte 0xDA 
229
+.byte 0xF7 
230
+.byte 0x52 
231
+.byte 0xFE 
232
+.byte 0x00 
233
+.byte 0x06 
234
+.byte 0x00 
235
+.byte 0x0E 
236
+.byte 0x00 
237
+.byte 0x28 
238
+.byte 0x1D 
239
+.byte 0xD1 
240
+.byte 0x00 
241
+.byte 0x90 
242
+.byte 0x0E 
243
+.byte 0x20 
244
+.byte 0x00 
245
+.byte 0x21 
246
+.byte 0x4D 
247
+.byte 0x22 
248
+.byte 0x00 
249
+.byte 0x23 
250
+.byte 0xDA 
251
+.byte 0xF7 
252
+.byte 0x47 
253
+.byte 0xFE 
254
+.byte 0x00 
255
+.byte 0x06 
256
+.byte 0x00 
257
+.byte 0x28 
258
+.byte 0x13 
259
+.byte 0xD1 
260
+.byte 0x0A 
261
+.byte 0x4A 
262
+.byte 0x13 
263
+.byte 0x88 
264
+.byte 0x18 
265
+.byte 0x20 
266
+.byte 0x18 
267
+.byte 0x40 
268
+.byte 0x00 
269
+.byte 0x28 
270
+.byte 0x0D 
271
+.byte 0xD0 
272
+.byte 0x01 
273
+.byte 0x99 
274
+.byte 0x21 
275
+.byte 0x31 
276
+.byte 0x08 
277
+.byte 0x78 
278
+.byte 0x05 
279
+.byte 0x28 
280
+.byte 0x04 
281
+.byte 0xD0 
282
+.byte 0x01 
283
+.byte 0x99 
284
+.byte 0x22 
285
+.byte 0x31 
286
+.byte 0x08 
287
+.byte 0x78 
288
+.byte 0x05 
289
+.byte 0x28 
290
+.byte 0x03 
291
+.byte 0xD1 
292
+.byte 0x06 
293
+.byte 0x99 
294
+.byte 0x48 
295
+.byte 0x08 
296
+.byte 0x41 
297
+.byte 0x18 
298
+.byte 0x06 
299
+.byte 0x91 
300
+.byte 0x20 
301
+.byte 0xE0 
302
+.byte 0x00 
303
+.byte 0x00 
304
+.byte 0x1C 
305
+.byte 0x3F 
306
+.byte 0x02 
307
+.byte 0x02
308
+
309
+.org 0x0803F2C0
310
+.byte 0x00 
311
+.byte 0x00 
312
+.byte 0x00 
313
+.byte 0x00 
314
+.byte 0x00 
315
+.byte 0x00 
316
+.byte 0x00 
317
+.byte 0x00 
318
+.byte 0x00 
319
+.byte 0x00 
320
+.byte 0x00 
321
+.byte 0x00 
322
+.byte 0x00 
323
+.byte 0x00 
324
+.byte 0x00 
325
+.byte 0x00 
326
+.byte 0x00 
327
+.byte 0x00 
328
+.byte 0x00 
329
+.byte 0x00 
330
+.byte 0x00 
331
+.byte 0x00 
332
+.byte 0x00 
333
+.byte 0x00 
334
+.byte 0x00 
335
+.byte 0x00 
336
+.byte 0x00 
337
+.byte 0x00 
338
+.byte 0x00 
339
+.byte 0x00 
340
+.byte 0x00 
341
+.byte 0x00 
342
+.byte 0x00 
343
+.byte 0x00 
344
+.byte 0x00 
345
+.byte 0x00 
346
+.byte 0x00 
347
+.byte 0x00 
348
+.byte 0x00 
349
+.byte 0x00 
350
+.byte 0x00 
351
+.byte 0x00 
352
+.byte 0x00 
353
+.byte 0x00 
354
+.byte 0x00 
355
+.byte 0x00 
356
+.byte 0x00 
357
+.byte 0x00 
358
+.byte 0x00 
359
+.byte 0x00 
360
+.byte 0x00 
361
+.byte 0x00 
362
+.byte 0x00 
363
+.byte 0x00 
364
+.byte 0x00 
365
+.byte 0x00 
366
+.byte 0x00 
367
+.byte 0x00 
368
+.byte 0x00 
369
+.byte 0x00
370
+
371
+.org 0x0803F2FC
372
+.byte 0x0A 
373
+.byte 0x48 
374
+.byte 0x00 
375
+.byte 0x68 
376
+.byte 0x18 
377
+.byte 0x21 
378
+.byte 0x08 
379
+.byte 0x40 
380
+.byte 0x00 
381
+.byte 0x28 
382
+.byte 0x0E 
383
+.byte 0xD0 
384
+.byte 0x01 
385
+.byte 0x99 
386
+.byte 0x21 
387
+.byte 0x31 
388
+.byte 0x08 
389
+.byte 0x78 
390
+.byte 0x05 
391
+.byte 0x28 
392
+.byte 0x02 
393
+.byte 0xD0 
394
+.byte 0x48 
395
+.byte 0x78 
396
+.byte 0x05 
397
+.byte 0x28 
398
+.byte 0x06 
399
+.byte 0xD1 
400
+.byte 0x40 
401
+.byte 0x46 
402
+.byte 0x64 
403
+.byte 0x21 
404
+.byte 0x48 
405
+.byte 0x43 
406
+.byte 0x96 
407
+.byte 0x21 
408
+.byte 0xA4 
409
+.byte 0xF1 
410
+.byte 0x7A 
411
+.byte 0xFE 
412
+.byte 0x80 
413
+.byte 0x46 
414
+.byte 0x37 
415
+.byte 0xE0 
416
+.byte 0x1C 
417
+.byte 0x3F 
418
+.byte 0x02 
419
+.byte 0x02
420
+
421
+.org 0x0803F32D
422
+.byte 0x00 
423
+.byte 0x00 
424
+.byte 0x00 
425
+.byte 0x00 
426
+.byte 0x00 
427
+.byte 0x00 
428
+.byte 0x00 
429
+.byte 0x00 
430
+.byte 0x00 
431
+.byte 0x00 
432
+.byte 0x00 
433
+.byte 0x00 
434
+.byte 0x00 
435
+.byte 0x00 
436
+.byte 0x00 
437
+.byte 0x00 
438
+.byte 0x00 
439
+.byte 0x00 
440
+.byte 0x00 
441
+.byte 0x00 
442
+.byte 0x00 
443
+.byte 0x00 
444
+.byte 0x00 
445
+.byte 0x00 
446
+.byte 0x00 
447
+.byte 0x00 
448
+.byte 0x00 
449
+.byte 0x00 
450
+.byte 0x00 
451
+.byte 0x00 
452
+.byte 0x00 
453
+.byte 0x00 
454
+.byte 0x00 
455
+.byte 0x00 
456
+.byte 0x00 
457
+.byte 0x00 
458
+.byte 0x00 
459
+.byte 0x00 
460
+.byte 0x00 
461
+.byte 0x00 
462
+.byte 0x00 
463
+.byte 0x00 
464
+.byte 0x00 
465
+.byte 0x00 
466
+.byte 0x00 
467
+.byte 0x00 
468
+.byte 0x00 
469
+.byte 0x00 
470
+.byte 0x00 
471
+.byte 0x00 
472
+.byte 0x00 
473
+.byte 0x00 
474
+.byte 0x00 
475
+.byte 0x00 
476
+.byte 0x00 
477
+.byte 0x00 
478
+.byte 0x00 
479
+.byte 0x00 
480
+.byte 0x00 
481
+.byte 0x00 
482
+.byte 0x00 
483
+.byte 0x00 
484
+.byte 0x00 
485
+.byte 0x00 
486
+.byte 0x00 
487
+.byte 0x00 
488
+.byte 0x00 
489
+.byte 0x00 
490
+.byte 0x00 
491
+.byte 0x00 
492
+.byte 0x00 
493
+.byte 0x00 
494
+.byte 0x00 
495
+.byte 0x00 
496
+.byte 0x00 
497
+.byte 0x00 
498
+.byte 0x00 
499
+.byte 0x00 
500
+.byte 0x00 
501
+.byte 0x00 
502
+.byte 0x00 
503
+.byte 0x00 
504
+.byte 0x00 
505
+.byte 0x00 
506
+.byte 0x00 
507
+.byte 0x00 
508
+.byte 0x00 
509
+.byte 0x00 
510
+.byte 0x00 
511
+.byte 0x00 
512
+.byte 0x00 
513
+.byte 0x00 
514
+.byte 0x00 
515
+.byte 0x00 
516
+.byte 0x00 
517
+.byte 0x00 
518
+.byte 0x00 
519
+.byte 0x00 
520
+.byte 0x00 
521
+.byte 0x00 
522
+.byte 0x00 
523
+.byte 0x00 
524
+.byte 0x00 
525
+.byte 0x00 
526
+.byte 0x00 
527
+.byte 0x00 
528
+.byte 0x00
529
+
530
+.org 0x0803F398
531
+.byte 0xF0 
532
+.byte 0x6C 
533
+.byte 0x10 
534
+.byte 0x21 
535
+.byte 0x08 
536
+.byte 0x40 
537
+.byte 0x00 
538
+.byte 0x28 
539
+.byte 0x06 
540
+.byte 0xD0 
541
+.byte 0x09 
542
+.byte 0x99 
543
+.byte 0x08 
544
+.byte 0x78 
545
+.byte 0x3E 
546
+.byte 0x28 
547
+.byte 0x02 
548
+.byte 0xD0 
549
+.byte 0xF8 
550
+.byte 0x0F 
551
+.byte 0x38 
552
+.byte 0x18 
553
+.byte 0x47 
554
+.byte 0x10 
555
+.byte 0x59 
556
+.byte 0x46 
557
+.byte 0x00 
558
+.byte 0x29 
559
+.byte 0x02 
560
+.byte 0xD0 
561
+.byte 0x45 
562
+.byte 0x46 
563
+.byte 0x1C 
564
+.byte 0x20 
565
+.byte 0x01 
566
+.byte 0xE0 
567
+.byte 0x3D 
568
+.byte 0x1C 
569
+.byte 0x19 
570
+.byte 0x20 
571
+.byte 0x32 
572
+.byte 0x56 
573
+.byte 0x3B 
574
+.byte 0x4F 
575
+.byte 0x3B 
576
+.byte 0x48 
577
+.byte 0x04 
578
+.byte 0x78 
579
+.byte 0x02 
580
+.byte 0x2C 
581
+.byte 0x01 
582
+.byte 0xD1 
583
+.byte 0x06 
584
+.byte 0x2A 
585
+.byte 0x07 
586
+.byte 0xDD 
587
+.byte 0x50 
588
+.byte 0x00 
589
+.byte 0xC1 
590
+.byte 0x19 
591
+.byte 0x08 
592
+.byte 0x78 
593
+.byte 0x68 
594
+.byte 0x43 
595
+.byte 0x49 
596
+.byte 0x78 
597
+.byte 0xA4 
598
+.byte 0xF1 
599
+.byte 0x1D 
600
+.byte 0xFE 
601
+.byte 0x05 
602
+.byte 0x1C 
603
+.byte 0x35 
604
+.byte 0x48 
605
+.byte 0x00 
606
+.byte 0x88 
607
+.byte 0x45 
608
+.byte 0x43 
609
+.byte 0x30 
610
+.byte 0x1C 
611
+.byte 0x2A 
612
+.byte 0x30 
613
+.byte 0x00 
614
+.byte 0x78 
615
+.byte 0x40 
616
+.byte 0x00 
617
+.byte 0x05 
618
+.byte 0x21 
619
+.byte 0xA4 
620
+.byte 0xF1 
621
+.byte 0x12 
622
+.byte 0xFE 
623
+.byte 0x02 
624
+.byte 0x30 
625
+.byte 0x45 
626
+.byte 0x43 
627
+.byte 0x59 
628
+.byte 0x46 
629
+.byte 0x01 
630
+.byte 0x20 
631
+.byte 0x08 
632
+.byte 0x40 
633
+.byte 0x00 
634
+.byte 0x28 
635
+.byte 0x02 
636
+.byte 0xD0 
637
+.byte 0x06 
638
+.byte 0x9B 
639
+.byte 0x1D 
640
+.byte 0x20 
641
+.byte 0x01 
642
+.byte 0xE0 
643
+.byte 0x05 
644
+.byte 0x9B 
645
+.byte 0x1A 
646
+.byte 0x20 
647
+.byte 0x01 
648
+.byte 0x9A 
649
+.byte 0x12 
650
+.byte 0x56 
651
+.byte 0x02 
652
+.byte 0x2C 
653
+.byte 0x01 
654
+.byte 0xD1 
655
+.byte 0x05 
656
+.byte 0x2A 
657
+.byte 0x07 
658
+.byte 0xDC 
659
+.byte 0x50 
660
+.byte 0x00 
661
+.byte 0xC1 
662
+.byte 0x19 
663
+.byte 0x08 
664
+.byte 0x78 
665
+.byte 0x58 
666
+.byte 0x43 
667
+.byte 0x49 
668
+.byte 0x78 
669
+.byte 0xA4 
670
+.byte 0xF1 
671
+.byte 0xF9 
672
+.byte 0xFD 
673
+.byte 0x03 
674
+.byte 0x1C 
675
+.byte 0x28 
676
+.byte 0x1C 
677
+.byte 0x19 
678
+.byte 0x1C 
679
+.byte 0xA4 
680
+.byte 0xF1 
681
+.byte 0xF4 
682
+.byte 0xFD 
683
+.byte 0x32 
684
+.byte 0x21 
685
+.byte 0xA4 
686
+.byte 0xF1 
687
+.byte 0xF1 
688
+.byte 0xFD 
689
+.byte 0x05 
690
+.byte 0x1C 
691
+.byte 0x20 
692
+.byte 0x48 
693
+.byte 0x07 
694
+.byte 0x68 
695
+.byte 0x01 
696
+.byte 0x20 
697
+.byte 0x07 
698
+.byte 0x40 
699
+.byte 0x58 
700
+.byte 0x46 
701
+.byte 0x01 
702
+.byte 0x30 
703
+.byte 0x03 
704
+.byte 0x99 
705
+.byte 0x08 
706
+.byte 0x40 
707
+.byte 0x00 
708
+.byte 0x28 
709
+.byte 0x13 
710
+.byte 0xD0 
711
+.byte 0x01 
712
+.byte 0x2C 
713
+.byte 0x11 
714
+.byte 0xD1 
715
+.byte 0x00 
716
+.byte 0x2F 
717
+.byte 0x0C 
718
+.byte 0xD0 
719
+.byte 0x02 
720
+.byte 0x20 
721
+.byte 0x00 
722
+.byte 0xF0 
723
+.byte 0xAD 
724
+.byte 0xF8 
725
+.byte 0x00 
726
+.byte 0x06 
727
+.byte 0x00 
728
+.byte 0x0E 
729
+.byte 0x02 
730
+.byte 0x28 
731
+.byte 0x05 
732
+.byte 0xD1 
733
+.byte 0x28 
734
+.byte 0x1C 
735
+.byte 0x03 
736
+.byte 0x21 
737
+.byte 0xA4 
738
+.byte 0xF1 
739
+.byte 0xD7 
740
+.byte 0xFD 
741
+.byte 0x45 
742
+.byte 0x00 
743
+.byte 0x02 
744
+.byte 0xE0 
745
+.byte 0xE8 
746
+.byte 0x0F 
747
+.byte 0x28 
748
+.byte 0x18 
749
+.byte 0x45 
750
+.byte 0x10 
751
+.byte 0x00 
752
+.byte 0x2F 
753
+.byte 0x25 
754
+.byte 0xD0 
755
+.byte 0x11 
756
+.byte 0x48 
757
+.byte 0x02 
758
+.byte 0x9A 
759
+.byte 0x51 
760
+.byte 0x00 
761
+.byte 0x89 
762
+.byte 0x18 
763
+.byte 0x89 
764
+.byte 0x00 
765
+.byte 0x0C 
766
+.byte 0x18 
767
+.byte 0xA3 
768
+.byte 0x79 
769
+.byte 0x01 
770
+.byte 0x27 
771
+.byte 0x02 
772
+.byte 0x20 
773
+.byte 0x08 
774
+.byte 0x2B 
775
+.byte 0x07 
776
+.byte 0xD0 
777
+.byte 0x32 
778
+.byte 0x2B 
779
+.byte 0x18 
780
+.byte 0xD1 
781
+.byte 0x02 
782
+.byte 0x27 
783
+.byte 0x00 
784
+.byte 0x20 
785
+.byte 0x23 
786
+.byte 0x78 
787
+.byte 0x07 
788
+.byte 0x2B 
789
+.byte 0x00 
790
+.byte 0xD1 
791
+.byte 0x03 
792
+.byte 0x27 
793
+.byte 0x00 
794
+.byte 0xF0 
795
+.byte 0x89 
796
+.byte 0xF8 
797
+.byte 0x00 
798
+.byte 0x06 
799
+.byte 0x00 
800
+.byte 0x0E 
801
+.byte 0xB8 
802
+.byte 0x42 
803
+.byte 0x0C 
804
+.byte 0xD9 
805
+.byte 0xA8 
806
+.byte 0x08 
807
+.byte 0x2D 
808
+.byte 0x1A 
809
+.byte 0x09 
810
+.byte 0xE0 
811
+.byte 0xAD 
812
+.byte 0xDE 
813
+.byte 0x25 
814
+.byte 0x08 
815
+.byte 0x71 
816
+.byte 0x3D 
817
+.byte 0x02 
818
+.byte 0x02 
819
+.byte 0x20 
820
+.byte 0x40 
821
+.byte 0x02 
822
+.byte 0x02 
823
+.byte 0x4C 
824
+.byte 0x2B 
825
+.byte 0x02 
826
+.byte 0x02 
827
+.byte 0x04 
828
+.byte 0x0C 
829
+.byte 0x25 
830
+.byte 0x08
831
+
832
+.org 0x0803F5A0
833
+.byte 0x78
834
+
835
+.org 0x0803F5A8
836
+.byte 0xB3 
837
+.byte 0x46 
838
+.byte 0xF0 
839
+.byte 0xBC 
840
+.byte 0x02 
841
+.byte 0xBC 
842
+.byte 0x08 
843
+.byte 0x47

+ 1
- 0
sots-private

@@ -0,0 +1 @@
1
+Subproject commit 30ff21dd66436d5bf710f5d9633d5e4998bcaa6c

+ 129
- 0
sprites.makefile View File

@@ -0,0 +1,129 @@
1
+AS = arm-none-eabi-as
2
+AR = arm-none-eabi-ar
3
+LD = arm-none-eabi-ld
4
+
5
+GFX_BUILD_DIR = gfx_build
6
+TMP_FILE = $(GFX_BUILD_DIR)/tmp.o
7
+TMP_FILE2 = $(GFX_BUILD_DIR)/tmp2.o
8
+
9
+ASSET_ROOT = sots-private/assets
10
+
11
+SPRITES_BINARY = object/pkmn_sprites.o
12
+
13
+NORMAL_PNG = $(sort $(wildcard $(ASSET_ROOT)/pkmn_sprites/normal_*.png))
14
+NORMAL_PAL_OBJ = $(addprefix $(GFX_BUILD_DIR)/sprites/normal_pal/,$(notdir $(NORMAL_PNG:.png=.o)))
15
+
16
+SHINY_PNG = $(sort $(wildcard $(ASSET_ROOT)/pkmn_sprites/shiny_*.png))
17
+SHINY_PAL_OBJ = $(addprefix $(GFX_BUILD_DIR)/sprites/shiny_pal/,$(notdir $(SHINY_PNG:.png=.o)))
18
+
19
+SPRITE_FRONT_OBJ = $(addprefix $(GFX_BUILD_DIR)/sprites/front_sprites/,$(notdir $(NORMAL_PNG:.png=.o)))
20
+SPRITE_BACK_OBJ = $(addprefix $(GFX_BUILD_DIR)/sprites/back_sprites/,$(notdir $(NORMAL_PNG:.png=.o)))
21
+
22
+CASTFORM_PNG = $(ASSET_ROOT)/pkmn_sprites/castform/castform.png
23
+NORMAL_CASTFORM_PAL_OBJ = $(GFX_BUILD_DIR)/sprites/castform/castform_normal_pal.o
24
+SHINY_CASTFORM_PAL_OBJ = $(GFX_BUILD_DIR)/sprites/castform/castform_shiny_pal.o
25
+CASTFORM_FRONT_OBJ = $(GFX_BUILD_DIR)/sprites/castform/castform_front.o
26
+CASTFORM_BACK_OBJ = $(GFX_BUILD_DIR)/sprites/castform/castform_back.o
27
+
28
+
29
+all: $(SPRITES_BINARY)
30
+
31
+.PHONY: clean
32
+clean:
33
+	rm -f $(TMP_FILE) $(GFX_BUILD_DIR)/sprites/castform/*
34
+	rm -f $(GFX_BUILD_DIR)/sprites/normal_pal/*
35
+	rm -f $(GFX_BUILD_DIR)/sprites/shiny_pal/*
36
+	rm -f $(GFX_BUILD_DIR)/sprites/front_sprites/*
37
+	rm -f $(GFX_BUILD_DIR)/sprites/back_sprites/*
38
+
39
+$(SPRITES_BINARY): $(NORMAL_PAL_OBJ) $(SHINY_PAL_OBJ) $(SPRITE_FRONT_OBJ) $(SPRITE_BACK_OBJ) $(NORMAL_CASTFORM_PAL_OBJ) $(SHINY_CASTFORM_PAL_OBJ) $(CASTFORM_FRONT_OBJ) $(CASTFORM_BACK_OBJ)
40
+	rm -f $(TMP_FILE2)
41
+	rm -f $(TMP_FILE)
42
+	for file in $^;\
43
+	do \
44
+		if [ ! -f $(TMP_FILE) ]; then\
45
+			$(LD) -r -o $(TMP_FILE) $$file;\
46
+		else\
47
+			$(LD) -r -o $(TMP_FILE2) $$file $(TMP_FILE);\
48
+			mv -f $(TMP_FILE2) $(TMP_FILE);\
49
+		fi;\
50
+	done
51
+	mv $(TMP_FILE) $@
52
+
53
+
54
+# Normal Palette Targets
55
+$(GFX_BUILD_DIR)/sprites/normal_pal/%.o: $(GFX_BUILD_DIR)/sprites/normal_pal/%.s
56
+	$(AS) -o $@ $<
57
+
58
+.PRECIOUS: $(GFX_BUILD_DIR)/sprites/normal_pal/%.s
59
+$(GFX_BUILD_DIR)/sprites/normal_pal/%.s: $(ASSET_ROOT)/pkmn_sprites/%.png
60
+	grit $< -fts -fh! -g! -gB 4 -gt -m! -p -pzl -pu16 -pn 16 \
61
+		-s $(shell echo $(notdir $(basename $<)) | sed "s/normal_/n_p_/g") \
62
+		-o $@
63
+
64
+
65
+# Shiny Palette Targets
66
+$(GFX_BUILD_DIR)/sprites/shiny_pal/%.o: $(GFX_BUILD_DIR)/sprites/shiny_pal/%.s
67
+	$(AS) -o $@ $<
68
+
69
+.PRECIOUS: $(GFX_BUILD_DIR)/sprites/shiny_pal/%.s
70
+$(GFX_BUILD_DIR)/sprites/shiny_pal/%.s: $(ASSET_ROOT)/pkmn_sprites/%.png
71
+	grit $< -fts -fh! -g! -gB 4 -gt -m! -p -pzl -pu16 -pn 16 \
72
+		-s $(shell echo $(notdir $(basename $<)) | sed "s/shiny_/s_p_/g") \
73
+		-o $@
74
+
75
+
76
+# Front Sprite Targets
77
+$(GFX_BUILD_DIR)/sprites/front_sprites/%.o: $(GFX_BUILD_DIR)/sprites/front_sprites/%.s
78
+	$(AS) -o $@ $<
79
+
80
+.PRECIOUS: $(GFX_BUILD_DIR)/sprites/front_sprites/%.s
81
+$(GFX_BUILD_DIR)/sprites/front_sprites/%.s: $(ASSET_ROOT)/pkmn_sprites/%.png
82
+	grit $< -fts -fh! -g -gB 4 -gt -gzl -al 0 -aw 64 -m! -p! \
83
+		-s $(shell echo $(notdir $(basename $<)) | sed "s/normal_/front_/g") \
84
+		-o $@
85
+
86
+
87
+# Back Sprite Targets
88
+$(GFX_BUILD_DIR)/sprites/back_sprites/%.o: $(GFX_BUILD_DIR)/sprites/bacj_sprites/%.s
89
+	$(AS) -o $@ $<
90
+
91
+.PRECIOUS: $(GFX_BUILD_DIR)/sprites/back_sprites/%.s
92
+$(GFX_BUILD_DIR)/sprites/back_sprites/%.s: $(ASSET_ROOT)/pkmn_sprites/%.png
93
+	grit $< -fts -fh! -g -gB 4 -gt -gzl -al 64 -aw 64 -m! -p! \
94
+		-s $(shell echo $(notdir $(basename $<)) | sed "s/normal_/back_/g") \
95
+		-o $@
96
+
97
+
98
+# Misc hardcoded targets
99
+$(NORMAL_CASTFORM_PAL_OBJ): $(NORMAL_CASTFORM_PAL_OBJ:.o=.s)
100
+	$(AS) -o $@ $<
101
+
102
+$(NORMAL_CASTFORM_PAL_OBJ:.o=.s): $(CASTFORM_PNG)
103
+	grit $< -fts -fh! -g! -gB 4 -gt -m! -p -pzl -pu16 -pn 64 \
104
+		-s n_p_0385 -o $@
105
+
106
+
107
+$(SHINY_CASTFORM_PAL_OBJ): $(SHINY_CASTFORM_PAL_OBJ:.o=.s)
108
+	$(AS) -o $@ $<
109
+
110
+$(SHINY_CASTFORM_PAL_OBJ:.o=.s): $(CASTFORM_PNG)
111
+	grit $< -fts -fh! -g! -gB 4 -gt -m! -p -pzl -pu16 -pn 64 \
112
+		-s s_p_0385 -o $@
113
+
114
+
115
+$(CASTFORM_FRONT_OBJ): $(CASTFORM_FRONT_OBJ:.o=.s)
116
+	$(AS) -o $@ $<
117
+
118
+$(CASTFORM_FRONT_OBJ:.o=.s): $(CASTFORM_PNG)
119
+	grit $< -fts -fh! -g -gB 4 -gt -gzl -al 0 -aw 256 -ah 64 -m! -p! \
120
+		-s front_0385 -o $@
121
+
122
+
123
+$(CASTFORM_BACK_OBJ): $(CASTFORM_BACK_OBJ:.o=.s)
124
+	$(AS) -o $@ $<
125
+
126
+$(CASTFORM_BACK_OBJ:.o=.s): $(CASTFORM_PNG)
127
+	grit $< -fts -fh! -g -gB 4 -gt -gzl -al 0 -aw 256 -at 64 -ah 64 -m! -p! \
128
+		-s back_0385 -o $@
129
+

+ 45
- 0
src/assets/meteor/met_background.c View File

@@ -0,0 +1,45 @@
1
+
2
+//{{BLOCK(met_background)
3
+
4
+//======================================================================
5
+//
6
+//	met_background, 256x160@4, 
7
+//	Transparent color : 00,FF,00
8
+//	+ palette 6 entries, lz77 compressed
9
+//	+ 2 tiles (t|f reduced) lz77 compressed
10
+//	+ regular map (flat), lz77 compressed, 32x20 
11
+//	Total size: 12 + 20 + 164 = 196
12
+//
13
+//	Time-stamp: 2016-05-29, 04:14:05
14
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
15
+//	( http://www.coranac.com/projects/#grit )
16
+//
17
+//======================================================================
18
+
19
+const unsigned int met_backgroundTiles[5] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
20
+{
21
+	0x00004010,0xF0000033,0x11059001,0x9001F011,0x00000005,
22
+};
23
+
24
+const unsigned short met_backgroundMap[82] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
25
+{
26
+	0x0010,0x0005,0x013F,0xF000,0xF001,0xF001,0xF001,0xF001,
27
+	0xF001,0xFB01,0x01F0,0x01F0,0x01F0,0x01F0,0x0770,0xF000,
28
+	0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
29
+	0x01F0,0x01F0,0xF0FF,0xF001,0xF001,0xF001,0xF001,0xF001,
30
+	0xF001,0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
31
+	0x01F0,0x01F0,0x01F0,0xF0FF,0xF001,0xF001,0xF001,0xF001,
32
+	0xF001,0xF001,0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,
33
+	0x01F0,0x01F0,0x01F0,0x01F0,0xF0FF,0xF001,0xF001,0xF001,
34
+
35
+	0xF001,0xF001,0xF001,0xA001,0xFF05,0x91F3,0x01F0,0x01F0,
36
+	0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0xF0E0,0xF001,0x9401,
37
+	0x003F,0x0000,
38
+};
39
+
40
+const unsigned short met_backgroundPal[6] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
41
+{
42
+	0x2010,0x0000,0x0030,0xF000,0x9001,0x1101,
43
+};
44
+
45
+//}}BLOCK(met_background)

+ 33
- 0
src/assets/meteor/met_background.h View File

@@ -0,0 +1,33 @@
1
+
2
+//{{BLOCK(met_background)
3
+
4
+//======================================================================
5
+//
6
+//	met_background, 256x160@4, 
7
+//	Transparent color : 00,FF,00
8
+//	+ palette 6 entries, lz77 compressed
9
+//	+ 2 tiles (t|f reduced) lz77 compressed
10
+//	+ regular map (flat), lz77 compressed, 32x20 
11
+//	Total size: 12 + 20 + 164 = 196
12
+//
13
+//	Time-stamp: 2016-05-29, 04:14:05
14
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
15
+//	( http://www.coranac.com/projects/#grit )
16
+//
17
+//======================================================================
18
+
19
+#ifndef GRIT_MET_BACKGROUND_H
20
+#define GRIT_MET_BACKGROUND_H
21
+
22
+#define met_backgroundTilesLen 20
23
+extern const unsigned int met_backgroundTiles[5];
24
+
25
+#define met_backgroundMapLen 164
26
+extern const unsigned short met_backgroundMap[82];
27
+
28
+#define met_backgroundPalLen 12
29
+extern const unsigned short met_backgroundPal[6];
30
+
31
+#endif // GRIT_MET_BACKGROUND_H
32
+
33
+//}}BLOCK(met_background)

+ 64
- 0
src/assets/meteor/met_clouds.c View File

@@ -0,0 +1,64 @@
1
+
2
+//{{BLOCK(met_clouds)
3
+
4
+//======================================================================
5
+//
6
+//	met_clouds, 256x160@4, 
7
+//	+ palette 14 entries, lz77 compressed
8
+//	+ 46 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 28 + 448 + 256 = 732
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+const unsigned int met_cloudsTiles[112] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
19
+{
20
+	0x0005C010,0xF0000033,0x6003B001,0x7013F066,0x66661707,0x601F1066,0x1F7019F0,0x60722320,
21
+	0x1FF02720,0x06661E40,0xD1064320,0x41301FF0,0x063F0060,0x43E00606,0x105F50F8,0x805DF042,
22
+	0x501AE05F,0x00240054,0x55030045,0x509B2055,0x50650455,0x10554444,0x03444503,0x44555554,
23
+	0x01505555,0x060AC320,0x01056665,0xF100550B,0x00657255,0x000C0003,0x00550003,0x60FA662A,
24
+	0x8018002A,0x00F20001,0x4860451A,0x4B50F656,0xEC101441,0x00056540,0x064B016D,0x404F11F6,
25
+	0xB10B0003,0xDDF0550D,0xF7051950,0x43004710,0x01F09000,0x7012F050,0xB69F00FF,0x1044E910,
26
+	0x55FFF088,0x0871DE10,0x56663B65,0xFF200C11,0x80060330,0xFF2A61DE,0x1E02F361,0x9710D710,
27
+	0xCF206501,0x03202D12,0xE1E901F9,0x019FF0EC,0x55AE51A3,0xD79FF005,0xA8725510,0x55C40105,
28
+
29
+	0x4D210200,0x01801211,0x444000B0,0x44440054,0x6045443B,0x01DB7103,0xE55165B7,0x547B0421,
30
+	0xB061AC21,0x1D21ED00,0x000F0244,0x1F10FC7A,0x0B21ECA0,0xC7117E31,0x06558341,0x023112FF,
31
+	0xF0EB2034,0xF1B32001,0x014760CB,0xC6F1F7CB,0x8BF3C741,0x02008502,0x223F1257,0x2613FFA7,
32
+	0x6B313BF0,0x8F4018F0,0xCF329B33,0x72FB7FC0,0x527BF0FF,0xE018F094,0xC0115601,0xC0CF6750,
33
+	0x551F42BE,0xF0651306,0xF08CB4BE,0x3823BF12,0x23F90166,0x9067D47C,0x2173F2BF,0x9713FF3F,
34
+	0x3FF10722,0x99F0FFB0,0x7420C821,0xC4FF1AF0,0xC49BF0BF,0xF01044BF,0x442E741F,0x003F9231,
35
+};
36
+
37
+const unsigned short met_cloudsMap[128] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
38
+{
39
+	0x0010,0x0005,0x003F,0xF020,0xF001,0xF001,0xF001,0xF001,
40
+	0xF001,0xF801,0x01F0,0x01F0,0x01F0,0x01F0,0x0590,0x2001,
41
+	0x0002,0x0320,0x0420,0x0520,0x0620,0x2000,0x2007,0x2008,
42
+	0x2009,0x080A,0x0B20,0x0C20,0x2920,0x200D,0x800E,0x3120,
43
+	0x200F,0x2010,0x2011,0x0012,0x1320,0x1420,0x1520,0x1620,
44
+	0x2000,0x2017,0x2018,0x2019,0x881A,0x4D00,0x201B,0x001C,
45
+	0x1D53,0x1E20,0x2020,0x001F,0x200B,0x2120,0x2220,0x2088,
46
+	0x2335,0x2420,0x6B60,0x2025,0x3026,0x2720,0x1700,0x2710,
47
+
48
+	0x2028,0x2029,0x2A01,0x2B20,0x2C20,0x2D20,0x8BF0,0xF0FF,
49
+	0xF001,0xF001,0xF001,0xF001,0xF001,0xF001,0xF001,0xFF01,
50
+	0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
51
+	0xF0FF,0xF001,0xF001,0xF001,0xF001,0xF001,0xF001,0xF001,
52
+	0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
53
+	0x01F0,0xF0FF,0xF001,0xF001,0xF001,0xF001,0xF001,0xF001,
54
+	0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
55
+	0x01F0,0x01F0,0xF0F8,0xF001,0xF001,0xF001,0x8001,0x0005,
56
+};
57
+
58
+const unsigned short met_cloudsPal[14] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
59
+{
60
+	0x2010,0x0000,0x0000,0x9602,0x747F,0x517F,0x007F,0x7FFE,
61
+	0x7F9C,0x7F7A,0x0000,0xD080,0x0001,0x0000,
62
+};
63
+
64
+//}}BLOCK(met_clouds)

+ 32
- 0
src/assets/meteor/met_clouds.h View File

@@ -0,0 +1,32 @@
1
+
2
+//{{BLOCK(met_clouds)
3
+
4
+//======================================================================
5
+//
6
+//	met_clouds, 256x160@4, 
7
+//	+ palette 14 entries, lz77 compressed
8
+//	+ 46 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 28 + 448 + 256 = 732
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+#ifndef GRIT_MET_CLOUDS_H
19
+#define GRIT_MET_CLOUDS_H
20
+
21
+#define met_cloudsTilesLen 448
22
+extern const unsigned int met_cloudsTiles[112];
23
+
24
+#define met_cloudsMapLen 256
25
+extern const unsigned short met_cloudsMap[128];
26
+
27
+#define met_cloudsPalLen 28
28
+extern const unsigned short met_cloudsPal[14];
29
+
30
+#endif // GRIT_MET_CLOUDS_H
31
+
32
+//}}BLOCK(met_clouds)

+ 148
- 0
src/assets/meteor/met_foreground.c View File

@@ -0,0 +1,148 @@
1
+
2
+//{{BLOCK(met_foreground)
3
+
4
+//======================================================================
5
+//
6
+//	met_foreground, 256x160@4, 
7
+//	+ palette 18 entries, lz77 compressed
8
+//	+ 140 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 36 + 2356 + 464 = 2856
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+const unsigned int met_foregroundTiles[589] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
19
+{
20
+	0x00118010,0xF000003D,0xF001F001,0x990F0001,0xBB600200,0x1C4017F0,0xBB999999,0xF0BB63BB,
21
+	0xAA1F901F,0x19F0AAAA,0x095C0B30,0x109A1200,0x1001F004,0x0300440E,0x00114000,0x03001400,
22
+	0x040018C0,0x41110000,0x2F110004,0x03004111,0xF00D0011,0x10446001,0x01F0CE2C,0x11445F40,
23
+	0x5FE00200,0xB8400B40,0x30141300,0x0018C083,0x44111499,0x007B20DE,0x3BF0417F,0xC6002B90,
24
+	0xB0901630,0x00B91D00,0xA92F0106,0xAF9000AA,0x01901701,0x3F31B93B,0x4F114B51,0x20EC3201,
25
+	0x710F5002,0x1300AB6B,0x88AA1D50,0x8AAABB00,0x6AAAAB78,0xA821C878,0x9AAA4C01,0x99AA0300,
26
+	0xAAAA0499,0x0088BBBA,0x03A8873E,0xA68766AA,0x67508AAA,0xBB606E00,0x5B106440,0x666666AA,
27
+	0x88880B66,0x77408888,0x501750AB,0x6666017F,0x8888AAA6,0x92706068,0x66660870,0x66AA3C10,
28
+
29
+	0x576AA910,0x097730A6,0x109A7B00,0x007F0003,0x0320813B,0xAAAA555A,0x63114885,0x21224000,
30
+	0x11222411,0x22221112,0x22070012,0x03004A22,0x24444500,0x41111422,0x43118024,0x21211111,
31
+	0x70121121,0x001E0021,0x1202701D,0x80211222,0x4240EE01,0x22240000,0x22400004,0x32404222,
32
+	0x44004222,0x33421223,0x02122233,0x11223332,0x14009322,0x5200A000,0x42560004,0x42322222,
33
+	0x22232207,0x01403333,0x9591A312,0x430D12AF,0x0233A601,0xD0031043,0xF5C3F21F,0x5F713E30,
34
+	0x5F01E730,0x095F0109,0x01E25F01,0x0233A275,0x00244437,0x2000AA00,0x03201124,0x11111240,
35
+	0xA802CE14,0x12210220,0x0300E500,0x7622F000,0x90EB3011,0x42AD129B,0xCE00F902,0x11221040,
36
+	0x42320142,0x87400022,0x12240303,0x0B014012,0x3F213B01,0x4424218F,0xBE022244,0x5C20C102,
37
+
38
+	0x10B95810,0x40A12154,0x81126500,0x91000422,0x43014248,0x7E010422,0x19223444,0x00333421,
39
+	0x2143011C,0xB1141032,0x01223B31,0x323D013A,0x3FF13222,0x123B31FE,0x013B21CD,0xF1031044,
40
+	0x0903E43F,0xAAEA02B9,0xEA020310,0x777A0E04,0x02810310,0x6888467B,0x00441466,0xEF628703,
41
+	0x47A4444B,0x2E511042,0x11442301,0xAA788902,0x6A03008A,0xA4780266,0x42777777,0x00110300,
42
+	0x11888884,0x22666641,0x68884108,0x87870287,0x0098A866,0x00AAA603,0x4403101E,0x48008888,
43
+	0x14666612,0x34486611,0xE3121111,0x04BAEB12,0x2B44448C,0x3201AAAA,0xB46F02BB,0x1F107732,
44
+	0xEB226873,0xDB1477D3,0x8F136664,0x22F4E302,0x03F702D0,0x4BA74335,0xAA24FB04,0x124AAA00,
45
+	0x1445AAAA,0x24AA0666,0x004A6611,0xBBE801AB,0x2211140F,0x01980244,0x01E401AA,0x6740F5FC,
46
+
47
+	0xBA02D6C0,0x01141F30,0x0E1242B1,0x102412D2,0xE4014191,0x3D024422,0x03425422,0xC3012110,
48
+	0xA91903A9,0x92220011,0x922221AB,0x222022BB,0x910330B9,0x9224BBAA,0xBA2D44AD,0x04AB6805,
49
+	0xBAC5131F,0xA4AC0330,0x1504AB2D,0x101804BA,0x60BBBB17,0x3403108B,0x8A88AA26,0x00059888,
50
+	0x4098888B,0x40390B04,0x20985C03,0x1D047703,0x73550300,0x04084333,0x13332300,0x3294236B,
51
+	0x399C0280,0x39411223,0x11532223,0xF1A9DF91,0x030914DF,0x3B0310F0,0xB212149A,0xF3330504,
52
+	0x43E36142,0xB912F5F1,0x2704BD42,0x1412E712,0x0D843118,0x121C04B0,0x5D21E022,0x13422221,
53
+	0x4E14114A,0x0C034442,0x11440112,0x2103408F,0x4B042444,0x84117B11,0x13F57CC1,0x207F137B,
54
+	0x444F0305,0x01217204,0x0D32B1B3,0x009B0314,0x44422179,0x118A8F20,0x9222128A,0x03926704,
55
+
56
+	0x0490B9B1,0x2122B99D,0x24BB9283,0xBAA90712,0xA1A92242,0x55783160,0x7112EA4D,0x9F819FF1,
57
+	0x8A1E078B,0x5E096405,0x8B0300BA,0x03107701,0x03209315,0x20877078,0x04C73603,0x004433B3,
58
+	0x23320833,0xE3042904,0x31122329,0xFD049821,0x21120300,0x0BC40664,0x21442241,0x0142C910,
59
+	0xAF6C041F,0x0442D812,0x6F04146B,0xE3004313,0x11EB2904,0x137F213C,0x8B042456,0x008F0414,
60
+	0x68442F0C,0x12648D04,0x159F056F,0x65AA159E,0x05911224,0x0066119F,0x48004444,0x314A21FF,
61
+	0x14A08553,0x144E21C6,0xB46E11D6,0xF005A27F,0x41430341,0xB702BB44,0x04B85484,0x032078D3,
62
+	0x41031022,0x0405B478,0x03431374,0x0310224E,0x48018877,0x14487721,0xBF017721,0x32224717,
63
+	0xB4333306,0x320232D0,0x0732FF0A,0x01F02B12,0x71152942,0x6372A420,0x20E04012,0x02463203,
64
+
65
+	0xAAAAB940,0xAB28B914,0xABA200AA,0xB4410310,0x21BA00BB,0x23BABB42,0xAA08A422,0x21422233,
66
+	0xAAABBABA,0x615993EF,0x8A5A33E0,0x47078B17,0x4F074B17,0x68888B1C,0x76040320,0x88664007,
67
+	0xC701776C,0x408603B0,0x661B1003,0x7405C898,0x39880310,0x22330310,0x33981688,0x33030023,
68
+	0x03108E03,0x2F94E043,0xEA90F860,0x11333114,0x33343444,0xCF150E03,0x22032034,0x0300A022,
69
+	0x12810612,0x11133341,0x10072464,0x33140350,0x42233506,0x24390780,0x22421322,0xB7FF1332,
70
+	0x07855371,0xF0934390,0x16F73101,0x00D616BF,0xAAAB9242,0xAABB9142,0x01B44238,0x050300E7,
71
+	0x2211AB5E,0x31ABB416,0x11313B01,0xAA7B0444,0x140C03F6,0x241D4392,0xCF08BAA1,0xDC881A43,
72
+	0x87085F01,0x7103408B,0x685A0147,0x04786188,0x86038088,0x90687778,0x3731F903,0x48013F01,
73
+
74
+	0x37313B21,0x48018633,0x450310FC,0x18BAA086,0x041D2269,0x0011425F,0x44211324,0x24211322,
75
+	0x004F08C0,0x32411203,0x47231133,0x42030024,0x11003132,0x2832D902,0x236C0AB4,0x5C688F04,
76
+	0x227F0823,0x28336B22,0x31CB07B5,0x01338C04,0xC37C686C,0x88082100,0x31122122,0x66006D01,
77
+	0x43331101,0x43333211,0x10FA9C08,0x07BD0803,0x02D1086D,0x8A0713E3,0x00127533,0x0807103D,
78
+	0x230933C3,0xFD2E0532,0xC0242316,0x5790E704,0x37257B60,0xEF1B2033,0x84701FB0,0x90314217,
79
+	0x20BA40B6,0x856C197C,0x1233E312,0x6903A422,0x590700B4,0xB40308B4,0x67066809,0x8007BB41,
80
+	0x3C26A479,0xFD82C001,0x66883FC6,0x06BF0310,0x0340682C,0xA801B834,0xE752FD12,0x7872F782,
81
+	0x1B100340,0x34986506,0xA9337206,0x40196E06,0xF9049803,0x4D008798,0xF15510EB,0x29BF31BF,
82
+
83
+	0x16194009,0x76E4351F,0x3107F121,0x234408A5,0xBA21760A,0x6701FD11,0x250ABD51,0x6F114639,
84
+	0x01244B0A,0x0720F5DA,0x8207D301,0x05227C17,0xBA19213F,0xC15A00EE,0x327B215F,0xF801B726,
85
+	0x94131402,0x33337BF1,0x01234809,0x1733A4E6,0x03422123,0x07204287,0x63016B39,0x0AB41229,
86
+	0x1C36410B,0x3766ABBA,0x681FF6AF,0x068B881B,0x33031010,0x4C9D070C,0x86031068,0x430FE378,
87
+	0x2178872F,0x03107877,0x49888886,0x395C0300,0x10984E06,0x278E2403,0x078886DA,0x88866887,
88
+	0x211B9212,0xECD72214,0x3F178327,0x0214690B,0x11BB00AE,0x740BD741,0x0B42271A,0xBB1034A9,
89
+	0x9D97FD10,0x31D21AB8,0x7304C60B,0x1111D102,0x8F21FE34,0xC1342E64,0x17297B25,0x6F265A21,
90
+	0x32422822,0x07329B06,0x432132CE,0x3132220E,0x30580343,0x13292903,0x04D50ADD,0x872112A8,
91
+
92
+	0x5B116723,0xFF7F5323,0x7B705F80,0x0B560B52,0x5E3C3928,0x7F207C60,0x184070F8,0x93262217,
93
+	0x43840AC4,0x049B1222,0x033111C9,0x314F02FE,0xBF43D733,0xFF151156,0x420306B4,0x0310FF05,
94
+	0x88841022,0x88030078,0x90666422,0x68660310,0x66680106,0x667E7886,0xBE0A0300,0xE3570220,
95
+	0x1340831D,0x0340C787,0x66881FE0,0x102A0B86,0xED4A0603,0x2B103A00,0x04983F90,0x332E0692,
96
+	0x33103B06,0x37062988,0x88333298,0x99630DAF,0x0D196C0D,0x818B3151,0xFFE40BE0,0x0F273F49,
97
+	0x470DDFF1,0xA01A4909,0xDFA1909D,0x13DB219F,0x02CC0411,0x3C5030F7,0xE66361D2,0xBF19F15C,
98
+	0x12245B1C,0xD109CB0C,0x0C115F22,0xE1041171,0xA80D6D03,0x3A08D80C,0x276401ED,0x11DB31E9,
99
+	0x8A222605,0xFFCC0C32,0xA9576A0A,0x3700CF27,0x73236765,0x7C905CD2,0x021F0ADE,0x430A128E,
100
+
101
+	0x2114E711,0xCA23DC61,0xEF1C9C05,0x4B0FB412,0x227F0642,0x308BB42C,0x73044203,0x86660320,
102
+	0x2142212F,0x400C787F,0xC0517F21,0xB0C0BFF1,0x001F9003,
103
+};
104
+
105
+const unsigned short met_foregroundMap[232] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
106
+{
107
+	0x0010,0x0005,0x003F,0xF030,0xF001,0xF001,0xF001,0xF001,
108
+	0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
109
+	0x01F0,0x01F0,0xF0FF,0xF001,0xF001,0xF001,0xF001,0xF001,
110
+	0xF001,0xF001,0xFF01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
111
+	0x01F0,0x01F0,0x01F0,0xF0FF,0xF001,0xF001,0xF001,0xF001,
112
+	0xF001,0xF001,0xF001,0xC001,0x01F0,0x0950,0x3001,0x3002,
113
+	0x3003,0x0405,0x0530,0x0630,0x1D00,0xE007,0x0021,0x3008,
114
+	0x3408,0x3000,0x3009,0x0A50,0x3B00,0x800B,0x0C3F,0x0D30,
115
+
116
+	0x0030,0x300E,0x300F,0x3010,0x3011,0x1200,0x1330,0x1430,
117
+	0x1530,0x0130,0x3016,0x3017,0x3018,0x6019,0x001D,0x301A,
118
+	0x301B,0x301C,0x341C,0x1D00,0x1E30,0x1F30,0x2030,0x0430,
119
+	0x3021,0x3022,0x4023,0x2483,0x0030,0x3025,0x3026,0x3027,
120
+	0x3028,0x2900,0x2A30,0x2B30,0x2C30,0x0030,0x302D,0x302E,
121
+	0x302F,0x3030,0x3104,0x3230,0x3330,0x1D40,0x3034,0x3500,
122
+	0x3630,0x3730,0x3830,0x0030,0x3039,0x303A,0x303B,0x303C,
123
+	0x3D10,0x3E30,0xC520,0x303F,0x3040,0x4100,0x4230,0x4330,
124
+
125
+	0x4430,0x0030,0x3045,0x3046,0x3047,0x3048,0x4900,0x4A30,
126
+	0x4B30,0x4C30,0x4030,0x604D,0x4E1D,0x4F30,0x5030,0x0030,
127
+	0x3051,0x3052,0x3451,0x3053,0x5401,0x5530,0x5630,0x5730,
128
+	0x0521,0x5800,0x5830,0x5934,0x5A30,0x0030,0x305B,0x305C,
129
+	0x305D,0x305E,0x5F00,0x6030,0x6130,0x6230,0x0130,0x3063,
130
+	0x3064,0x3065,0x4066,0x001D,0x3067,0x3068,0x3069,0x306A,
131
+	0x6B00,0x6A30,0x6C34,0x6D30,0x0430,0x306E,0x306F,0x2170,
132
+	0x7145,0x0030,0x3471,0x3072,0x3073,0x3074,0x7500,0x7630,
133
+
134
+	0x7730,0x7830,0x0030,0x3079,0x307A,0x307B,0x307C,0x7D00,
135
+	0x7E30,0x7F30,0x8030,0x0030,0x3081,0x3082,0x3083,0x3084,
136
+	0x8500,0x8630,0x8730,0x8630,0x0034,0x3088,0x3089,0x308A,
137
+	0x308B,0x8A7F,0x4F01,0x01F0,0x01F0,0x01F0,0x01F0,0x01F0,
138
+	0x01F0,0xF0F8,0xF001,0xF001,0xF001,0xB001,0x0003,0x008F,
139
+};
140
+
141
+const unsigned short met_foregroundPal[18] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
142
+{
143
+	0x2010,0x0000,0x0000,0x0E7E,0xCB3B,0x8932,0x002A,0x21E0,
144
+	0x5F19,0x4E97,0x4634,0xF200,0x493D,0xF825,0xB619,0x2015,
145
+	0x0000,0x0130,
146
+};
147
+
148
+//}}BLOCK(met_foreground)

+ 32
- 0
src/assets/meteor/met_foreground.h View File

@@ -0,0 +1,32 @@
1
+
2
+//{{BLOCK(met_foreground)
3
+
4
+//======================================================================
5
+//
6
+//	met_foreground, 256x160@4, 
7
+//	+ palette 18 entries, lz77 compressed
8
+//	+ 140 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 36 + 2356 + 464 = 2856
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+#ifndef GRIT_MET_FOREGROUND_H
19
+#define GRIT_MET_FOREGROUND_H
20
+
21
+#define met_foregroundTilesLen 2356
22
+extern const unsigned int met_foregroundTiles[589];
23
+
24
+#define met_foregroundMapLen 464
25
+extern const unsigned short met_foregroundMap[232];
26
+
27
+#define met_foregroundPalLen 36
28
+extern const unsigned short met_foregroundPal[18];
29
+
30
+#endif // GRIT_MET_FOREGROUND_H
31
+
32
+//}}BLOCK(met_foreground)

+ 68
- 0
src/assets/meteor/met_meteor.c View File

@@ -0,0 +1,68 @@
1
+
2
+//{{BLOCK(met_meteor)
3
+
4
+//======================================================================
5
+//
6
+//	met_meteor, 32x96@4, 
7
+//	+ palette 16 entries, not compressed
8
+//	+ 48 tiles lz77 compressed
9
+//	Total size: 32 + 1168 = 1200
10
+//
11
+//	Time-stamp: 2016-05-29, 04:14:05
12
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
13
+//	( http://www.coranac.com/projects/#grit )
14
+//
15
+//======================================================================
16
+
17
+const unsigned int met_meteorTiles[292] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
18
+{
19
+	0x00060010,0xF000003A,0x2001F001,0x1300100D,0x00001013,0x221A0020,0x02100032,0x11000031,
20
+	0x27801103,0x10334002,0x00401134,0x00300001,0x11300000,0x10442230,0x3740246C,0x20023E30,
21
+	0x10480002,0x00037400,0x40410060,0x0E003066,0x00001243,0x00214230,0x00421430,0x64213000,
22
+	0x76441300,0x64210000,0x21213077,0x22130022,0x62216464,0x42005756,0x66247756,0x00665775,
23
+	0x65657755,0x64246577,0x56465700,0x44254465,0x46550012,0x44663124,0x44002211,0x44446424,
24
+	0x00016664,0x33242655,0x03144666,0x3124440C,0x10671010,0x760322CB,0x20BC1030,0x01C81077,
25
+	0x7910B010,0x75560042,0x87556413,0x75006413,0x87562388,0x00562178,0x86427778,0x65428775,
26
+	0x41888700,0x46777855,0x77750066,0x57777778,0x55017788,0x65557766,0x04005746,0x77878800,
27
+
28
+	0x76788757,0x68880055,0x46576575,0x75004444,0x55246557,0x00122465,0x33322466,0x00124246,
29
+	0x31266500,0x11244631,0x34653F21,0x2E012701,0x8750EB10,0xF710E910,0x23975080,0x13888876,
30
+	0x78008772,0x66755130,0x04576130,0x46130078,0x42FF0055,0x33002000,0x57305B11,0x40466765,
31
+	0x755C0067,0x77244667,0x12461067,0x44EB0066,0x08311224,0x33031221,0x11218211,0x33030211,
32
+	0x01000333,0xFF038E01,0xA4115401,0x01F0F350,0x01F001F0,0x068001F0,0x12D801D0,0x07020303,
33
+	0x11303010,0x0F101170,0xDB01C131,0x14421241,0x24664404,0xF5016400,0x11051102,0x34222100,
34
+	0x01107E51,0x1113596F,0x422020F6,0x01218031,0x20903E40,0x00133045,0x00302156,0x10120021,
35
+	0x30231430,0x62002120,0x24422423,0x00223213,0x46642333,0x44662213,0x44624400,0x52614565,
36
+
37
+	0x61660066,0x26655642,0x46007564,0x64675642,0x04134442,0x31311211,0x42FE0123,0x01224024,
38
+	0x466666FD,0x00457756,0x64556422,0x46665524,0x02226400,0x11440001,0x26000032,0x24000440,
39
+	0x00020342,0x00031214,0x32A80231,0x04DB00A0,0x5643DF00,0x00636442,0x61564425,0x24756644,
40
+	0x77556208,0x44070214,0x78008656,0x77865642,0x10776541,0x00775675,0x6646654E,0x65451077,
41
+	0x66FF0144,0x00565777,0x74656756,0x57577576,0x78885500,0x44656565,0x46440264,0x64646656,
42
+	0x00569702,0x66344657,0x65221266,0x11331400,0x33421466,0x34310F66,0xF4020600,0x3C112451,
43
+	0x51817752,0x7865435A,0x00661088,0x68440003,0x56413075,0x13140075,0xFF026664,0x00FF4144,
44
+	0x65770088,0x65577866,0x57005765,0x65576556,0x13566655,0x00256566,0x02424404,0x049E11DC,
45
+
46
+	0x00034126,0x24D30044,0x00300D32,0xDB000142,0x0323DF00,0x8B23FF9A,0x01F001F0,0x01F001F0,
47
+	0xF7130D20,0x225A16B0,0x60904633,0x9900142C,0x8001E503,0x13000320,0x00901131,0x00994D90,
48
+	0x70099913,0x90087024,0x40560931,0x04141A00,0x34044130,0x5023F700,0x64660462,0x00424D02,
49
+	0x44002613,0x33226656,0x00416452,0x66444412,0x45655622,0x64546600,0x22465522,0x22560464,
50
+	0x03777564,0x0021579A,0x61922222,0x44314466,0x00145600,0x00124556,0x11660075,0x14465700,
51
+	0x640A6502,0x00665555,0x9D000202,0x7814B492,0x00804009,0x9504606D,0x00101246,0x04043600,
52
+	0x66426130,0x54421000,0x76461375,0x46630087,0x62618876,0x21007875,0x21558876,0x00585876,
53
+	0x78856543,0x66566775,0x46578800,0x87888866,0x67880078,0x55788875,0x04805656,0x5777457F,
54
+
55
+	0x58886666,0x55655500,0x46166556,0x11460065,0x31244565,0x14006657,0x44457701,0x00556431,
56
+	0x64240436,0x44645465,0x14712216,0x4421E804,0x0597936F,0x430340A4,0x86105900,0x58440300,
57
+	0x41305505,0xFF015666,0x90FF2476,0x8833FF33,0x5555F711,0x55105546,0x6C044465,0x21666522,
58
+	0x12466600,0x64224442,0x13110034,0x64033311,0x55002456,0x66644222,0x03442442,0x22226466,
59
+	0x57451634,0x10B0F754,0x13F40667,0x00FF0160,
60
+};
61
+
62
+const unsigned short met_meteorPal[16] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
63
+{
64
+	0x2108,0x211B,0x223E,0x2117,0x22BE,0x4BDE,0x375E,0x5FDE,
65
+	0x7BDE,0x21BE,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
66
+};
67
+
68
+//}}BLOCK(met_meteor)

+ 28
- 0
src/assets/meteor/met_meteor.h View File

@@ -0,0 +1,28 @@
1
+
2
+//{{BLOCK(met_meteor)
3
+
4
+//======================================================================
5
+//
6
+//	met_meteor, 32x96@4, 
7
+//	+ palette 16 entries, not compressed
8
+//	+ 48 tiles lz77 compressed
9
+//	Total size: 32 + 1168 = 1200
10
+//
11
+//	Time-stamp: 2016-05-29, 04:14:05
12
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
13
+//	( http://www.coranac.com/projects/#grit )
14
+//
15
+//======================================================================
16
+
17
+#ifndef GRIT_MET_METEOR_H
18
+#define GRIT_MET_METEOR_H
19
+
20
+#define met_meteorTilesLen 1168
21
+extern const unsigned int met_meteorTiles[292];
22
+
23
+#define met_meteorPalLen 32
24
+extern const unsigned short met_meteorPal[16];
25
+
26
+#endif // GRIT_MET_METEOR_H
27
+
28
+//}}BLOCK(met_meteor)

+ 55
- 0
src/assets/meteor/met_sky.c View File

@@ -0,0 +1,55 @@
1
+
2
+//{{BLOCK(met_sky)
3
+
4
+//======================================================================
5
+//
6
+//	met_sky, 256x160@4, 
7
+//	+ palette 14 entries, lz77 compressed
8
+//	+ 25 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 28 + 204 + 240 = 472
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+const unsigned int met_skyTiles[51] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
19
+{
20
+	0x00032010,0xF0000033,0x33059001,0x2001F033,0x3332010D,0x23232333,0xBD19F023,0xF0321E60,
21
+	0xF040B01F,0x325E801F,0xF0E03FF0,0x601EF07F,0x23332308,0x30E13232,0x90471001,0x22232207,
22
+	0xDF015022,0x0F001FF0,0xF0217022,0x803F001F,0xDF1FF040,0x3FA00F10,0x90A71022,0xF07F9007,
23
+	0x7B3D003B,0x70010032,0x8001F0A2,0x01002106,0x50880730,0x1122220F,0x11210F30,0x12123712,
24
+	0x276031F0,0xF01E0021,0x0757601F,0x12122212,0xF0565021,0x363A0001,0x01302121,0x40116710,
25
+	0x210FF007,0xF06720FC,0xF00F5007,0x20079015,0x3F121157,0x01F01111,0x31200D20,0x1F801FF0,
26
+	0x11789C10,0x01F04300,0x01F001F0,
27
+};
28
+
29
+const unsigned short met_skyMap[120] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
30
+{
31
+	0x0010,0x0005,0x003F,0xF010,0xF001,0xF001,0xF001,0xF001,
32
+	0xF001,0xF801,0x01F0,0x01F0,0x01F0,0x01F0,0x0770,0x1001,
33
+	0x3402,0x0310,0x05F0,0x05A0,0x0004,0x0515,0x0210,0x1402,
34
+	0x1401,0x1403,0x0570,0x8306,0x4D20,0x1007,0x1008,0xF009,
35
+	0xA005,0x4005,0x000A,0x0B15,0x0810,0x0714,0x2B14,0x1409,
36
+	0x0570,0x200C,0x0D8D,0x01F0,0x01F0,0xF0E3,0x2001,0x100D,
37
+	0x0ECD,0x0F10,0x01F0,0x0B40,0x101C,0x1110,0x01F0,0x0780,
38
+	0x0D11,0x1012,0x1361,0x01F0,0x0B40,0x1014,0x1413,0x01F0,
39
+
40
+	0x70C6,0x1107,0x154D,0x1610,0x01F0,0x0B40,0x1D17,0x1610,
41
+	0xF014,0x7001,0x1107,0x188D,0x01F0,0xF0FF,0xF001,0x2001,
42
+	0xF00D,0xF03F,0xF001,0xF001,0xF03F,0xFF01,0x01F0,0x01F0,
43
+	0x3FF0,0x01F0,0x01F0,0x3FF0,0x01F0,0x01F0,0xF0FF,0xF001,
44
+	0xF03F,0xF001,0xF001,0xF03F,0xF015,0xF001,0xFF01,0x3FF0,
45
+	0x01F0,0x01F0,0x3FF0,0x01F0,0x01F0,0x01F0,0x01F0,0xF0FE,
46
+	0xF001,0xF001,0xF001,0xF001,0xF001,0xB001,0x0003,0x0000,
47
+};
48
+
49
+const unsigned short met_skyPal[14] __attribute__((aligned(4))) __attribute__((visibility("hidden")))=
50
+{
51
+	0x2010,0x0000,0x0000,0x9602,0x747F,0x517F,0x007F,0x7FFE,
52
+	0x7F9C,0x7F7A,0x0000,0xD080,0x0001,0x0000,
53
+};
54
+
55
+//}}BLOCK(met_sky)

+ 32
- 0
src/assets/meteor/met_sky.h View File

@@ -0,0 +1,32 @@
1
+
2
+//{{BLOCK(met_sky)
3
+
4
+//======================================================================
5
+//
6
+//	met_sky, 256x160@4, 
7
+//	+ palette 14 entries, lz77 compressed
8
+//	+ 25 tiles (t|f reduced) lz77 compressed
9
+//	+ regular map (flat), lz77 compressed, 32x20 
10
+//	Total size: 28 + 204 + 240 = 472
11
+//
12
+//	Time-stamp: 2016-05-29, 04:14:05
13
+//	Exported by Cearn's GBA Image Transmogrifier, v0.8.13
14
+//	( http://www.coranac.com/projects/#grit )
15
+//
16
+//======================================================================
17
+
18
+#ifndef GRIT_MET_SKY_H
19
+#define GRIT_MET_SKY_H
20
+
21
+#define met_skyTilesLen 204
22
+extern const unsigned int met_skyTiles[51];
23
+
24
+#define met_skyMapLen 240
25
+extern const unsigned short met_skyMap[120];
26
+
27
+#define met_skyPalLen 28
28
+extern const unsigned short met_skyPal[14];
29
+
30
+#endif // GRIT_MET_SKY_H
31
+
32
+//}}BLOCK(met_sky)

+ 49
- 0
src/battle_bg/battle_bg_hook.S View File

@@ -0,0 +1,49 @@
1
+#include <config.h>
2
+.align 2
3
+.thumb
4
+.text
5
+
6
+.global battle_bg_hook
7
+battle_bg_hook:
8
+	ldr r0, =npc_states
9
+	ldrb r0, [r0, #0x1E]
10
+	cmp r0, #0x10
11
+	beq sea_type_bg
12
+	cmp r0, #0x11
13
+	beq sea_type_bg
14
+	cmp r0, #0x12
15
+	beq sea_type_bg
16
+	cmp r0, #0x15
17
+	beq sea_type_bg
18
+normal_type_bg:
19
+	ldrh r0, =NORMAL_VAR
20
+	b custom_load_attempt
21
+sea_type_bg:
22
+	ldrh r0, =SEA_VAR
23
+custom_load_attempt:
24
+	ldr r1, =var_access
25
+	bl bxr1
26
+	ldrh r0, [r0]
27
+	cmp r0, #0
28
+	beq normal_end
29
+	sub r0, #1
30
+	b end
31
+
32
+	ldr r1, =var_access
33
+	bl bxr1
34
+	ldrh r0, [r0]
35
+	
36
+normal_end:
37
+	ldr r0, =get_bs_elem_env_index
38
+	bl bxr0
39
+	lsl r0, #0x18
40
+	lsr r0, #0x18
41
+	end:
42
+	ldr r1, =load_battle_screen_elements_1
43
+	bl bxr1
44
+	pop {r0}
45
+	bx r0
46
+bxr1:
47
+	bx r1
48
+bxr0:
49
+	bx r0

+ 61
- 0
src/encode/crc32.c View File

@@ -0,0 +1,61 @@
1
+#include <config.h>
2
+#include <types.h>
3
+
4
+static u32 crc32_tab[] = {
5
+	0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f,
6
+	0xe963a535, 0x9e6495a3,	0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988,
7
+	0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, 0x1db71064, 0x6ab020f2,
8
+	0xf3b97148, 0x84be41de,	0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7,
9
+	0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec,	0x14015c4f, 0x63066cd9,
10
+	0xfa0f3d63, 0x8d080df5,	0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172,
11
+	0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b,	0x35b5a8fa, 0x42b2986c,
12
+	0xdbbbc9d6, 0xacbcf940,	0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59,
13
+	0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423,
14
+	0xcfba9599, 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924,
15
+	0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d,	0x76dc4190, 0x01db7106,
16
+	0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433,
17
+	0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d,
18
+	0x91646c97, 0xe6635c01, 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e,
19
+	0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950,
20
+	0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65,
21
+	0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, 0x4adfa541, 0x3dd895d7,
22
+	0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0,
23
+	0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa,
24
+	0xbe0b1010, 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f,
25
+	0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, 0x2eb40d81,
26
+	0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a,
27
+	0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, 0xe3630b12, 0x94643b84,
28
+	0x0d6d6a3e, 0x7a6a5aa8, 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1,
29
+	0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb,
30
+	0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc,
31
+	0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, 0xd6d6a3e8, 0xa1d1937e,
32
+	0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b,
33
+	0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55,
34
+	0x316e8eef, 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236,
35
+	0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, 0xb2bd0b28,
36
+	0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d,
37
+	0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, 0x9c0906a9, 0xeb0e363f,
38
+	0x72076785, 0x05005713, 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38,
39
+	0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242,
40
+	0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777,
41
+	0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, 0x8f659eff, 0xf862ae69,
42
+	0x616bffd3, 0x166ccf45, 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2,
43
+	0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc,
44
+	0x40df0b66, 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9,
45
+	0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, 0xcdd70693,
46
+	0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94,
47
+	0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d
48
+};
49
+
50
+u32 crc32(u32 crc, const void *buf, u32 size)
51
+{
52
+	const u8 *p;
53
+
54
+	p = buf;
55
+	crc = crc ^ ~0U;
56
+
57
+	while (size--)
58
+		crc = crc32_tab[(crc ^ *p++) & 0xFF] ^ (crc >> 8);
59
+
60
+	return crc ^ ~0U;
61
+}

+ 621
- 0
src/include/attack_names.h View File

@@ -0,0 +1,621 @@
1
+.equ ABSORB, 0x47
2
+.equ ACID, 0x33
3
+.equ ACID_ARMOR, 0x97
4
+.equ ACID_SPRAY, 0x1EB
5
+.equ ACROBATICS, 0x200
6
+.equ ACUPRESSURE, 0x16F
7
+.equ AERIAL_ACE, 0x14C
8
+.equ AEROBLAST, 0xB1
9
+.equ AFTER_YOU, 0x1EF
10
+.equ AGILITY, 0x61
11
+.equ AIR_CUTTER, 0x13A
12
+.equ AIR_SLASH, 0x193
13
+.equ ALLY_SWITCH, 0x1F6
14
+.equ AMNESIA, 0x85
15
+.equ ANCIENT_POWER, 0xF6
16
+.equ AQUA_JET, 0x1C5
17
+.equ AQUA_RING, 0x188
18
+.equ AQUA_TAIL, 0x191
19
+.equ ARM_THRUST, 0x124
20
+.equ AROMATHERAPY, 0x138
21
+.equ AROMATIC_MIST, 0x255
22
+.equ ASSIST, 0x112
23
+.equ ASSURANCE, 0x174
24
+.equ ASTONISH, 0x136
25
+.equ ATTACK_ORDER, 0x1C6
26
+.equ ATTRACT, 0xD5
27
+.equ AURA_SPHERE, 0x18C
28
+.equ AURORA_BEAM, 0x3E
29
+.equ AUTOTOMIZE, 0x1DB
30
+.equ AVALANCHE, 0x1A3
31
+.equ BABYDOLL_EYES, 0x260
32
+.equ BARRAGE, 0x8C
33
+.equ BARRIER, 0x70
34
+.equ BATON_PASS, 0xE2
35
+.equ BEAT_UP, 0xFB
36
+.equ BELCH, 0x232
37
+.equ BELLY_DRUM, 0xBB
38
+.equ BESTOW, 0x204
39
+.equ BIDE, 0x75
40
+.equ BIND, 0x14
41
+.equ BITE, 0x2C
42
+.equ BLAST_BURN, 0x133
43
+.equ BLAZE_KICK, 0x12B
44
+.equ BLIZZARD, 0x3B
45
+.equ BLOCK, 0x14F
46
+.equ BLUE_FLARE, 0x227
47
+.equ BODY_SLAM, 0x22
48
+.equ BOLT_STRIKE, 0x226
49
+.equ BONE_CLUB, 0x7D
50
+.equ BONE_RUSH, 0xC6
51
+.equ BONEMERANG, 0x9B
52
+.equ BOOMBURST, 0x24A
53
+.equ BOUNCE, 0x154
54
+.equ BRAVE_BIRD, 0x19D
55
+.equ BRICK_BREAK, 0x118
56
+.equ BRINE, 0x16A
57
+.equ BUBBLE, 0x91
58
+.equ BUBBLE_BEAM, 0x3D
59
+.equ BUG_BITE, 0x1C2
60
+.equ BUG_BUZZ, 0x195
61
+.equ BULK_UP, 0x153
62
+.equ BULLDOZE, 0x20B
63
+.equ BULLET_PUNCH, 0x1A2
64
+.equ BULLET_SEED, 0x14B
65
+.equ CALM_MIND, 0x15B
66
+.equ CAMOUFLAGE, 0x125
67
+.equ CAPTIVATE, 0x1BD
68
+.equ CELEBRATE, 0x25E
69
+.equ CHARGE, 0x10C
70
+.equ CHARGE_BEAM, 0x1C3
71
+.equ CHARM, 0xCC
72
+.equ CHATTER, 0x1C0
73
+.equ CHIP_AWAY, 0x1F2
74
+.equ CIRCLE_THROW, 0x1FD
75
+.equ CLAMP, 0x80
76
+.equ CLEAR_SMOG, 0x1F3
77
+.equ CLOSE_COMBAT, 0x172
78
+.equ COIL, 0x1E9
79
+.equ COMET_PUNCH, 0x4
80
+.equ CONFIDE, 0x24E
81
+.equ CONFUSE_RAY, 0x6D
82
+.equ CONFUSION, 0x5D
83
+.equ CONSTRICT, 0x84
84
+.equ CONVERSION, 0xA0
85
+.equ CONVERSION_2, 0xB0
86
+.equ COPYCAT, 0x17F
87
+.equ COSMIC_POWER, 0x142
88
+.equ COTTON_GUARD, 0x21A
89
+.equ COTTON_SPORE, 0xB2
90
+.equ COUNTER, 0x44
91
+.equ COVET, 0x157
92
+.equ CRABHAMMER, 0x98
93
+.equ CRAFTY_SHIELD, 0x242
94
+.equ CROSS_CHOP, 0xEE
95
+.equ CROSS_POISON, 0x1B8
96
+.equ CRUNCH, 0xF2
97
+.equ CRUSH_CLAW, 0x132
98
+.equ CRUSH_GRIP, 0x1CE
99
+.equ CURSE, 0xAE
100
+.equ CUT, 0xF
101
+.equ DARK_PULSE, 0x18F
102
+.equ DARK_VOID, 0x1D0
103
+.equ DAZZLING_GLEAM, 0x25D
104
+.equ DEFEND_ORDER, 0x1C7
105
+.equ DEFENSE_CURL, 0x6F
106
+.equ DEFOG, 0x1B0
107
+.equ DESTINY_BOND, 0xC2
108
+.equ DETECT, 0xC5
109
+.equ DIAMOND_STORM, 0x24F
110
+.equ DIG, 0x5B
111
+.equ DISABLE, 0x32
112
+.equ DISARMING_VOICE, 0x23E
113
+.equ DISCHARGE, 0x1B3
114
+.equ DIVE, 0x123
115
+.equ DIZZY_PUNCH, 0x92
116
+.equ DOOM_DESIRE, 0x161
117
+.equ DOUBLEEDGE, 0x26
118
+.equ DOUBLE_HIT, 0x1CA
119
+.equ DOUBLE_KICK, 0x18
120
+.equ DOUBLE_SLAP, 0x3
121
+.equ DOUBLE_TEAM, 0x68
122
+.equ DRACO_METEOR, 0x1B2
123
+.equ DRAGON_ASCENT, 0x26C
124
+.equ DRAGON_BREATH, 0xE1
125
+.equ DRAGON_CLAW, 0x151
126
+.equ DRAGON_DANCE, 0x15D
127
+.equ DRAGON_PULSE, 0x196
128
+.equ DRAGON_RAGE, 0x52
129
+.equ DRAGON_RUSH, 0x197
130
+.equ DRAGON_TAIL, 0x20D
131
+.equ DRAINING_KISS, 0x241
132
+.equ DRAIN_PUNCH, 0x199
133
+.equ DREAM_EATER, 0x8A
134
+.equ DRILL_PECK, 0x41
135
+.equ DRILL_RUN, 0x211
136
+.equ DUAL_CHOP, 0x212
137
+.equ DYNAMIC_PUNCH, 0xDF
138
+.equ EARTH_POWER, 0x19E
139
+.equ EARTHQUAKE, 0x59
140
+.equ ECHOED_VOICE, 0x1F1
141
+.equ EERIE_IMPULSE, 0x256
142
+.equ EGG_BOMB, 0x79
143
+.equ ELECTRIC_TERRAIN, 0x25C
144
+.equ ELECTRIFY, 0x246
145
+.equ ELECTRO_BALL, 0x1E6
146
+.equ ELECTROWEB, 0x20F
147
+.equ EMBARGO, 0x175
148
+.equ EMBER, 0x34
149
+.equ ENCORE, 0xE3
150
+.equ ENDEAVOR, 0x11B
151
+.equ ENDURE, 0xCB
152
+.equ ENERGY_BALL, 0x19C
153
+.equ ENTRAINMENT, 0x1EE
154
+.equ ERUPTION, 0x11C
155
+.equ EXPLOSION, 0x99
156
+.equ EXTRASENSORY, 0x146
157
+.equ EXTREME_SPEED, 0xF5
158
+.equ FACADE, 0x107
159
+.equ FEINT_ATTACK, 0xB9
160
+.equ FAIRY_LOCK, 0x24B
161
+.equ FAIRY_WIND, 0x248
162
+.equ FAKE_OUT, 0xFC
163
+.equ FAKE_TEARS, 0x139
164
+.equ FALSE_SWIPE, 0xCE
165
+.equ FEATHER_DANCE, 0x129
166
+.equ FEINT, 0x16C
167
+.equ FELL_STINGER, 0x235
168
+.equ FIERY_DANCE, 0x228
169
+.equ FINAL_GAMBIT, 0x203
170
+.equ FIRE_BLAST, 0x7E
171
+.equ FIRE_FANG, 0x1A8
172
+.equ FIRE_PLEDGE, 0x207
173
+.equ FIRE_PUNCH, 0x7
174
+.equ FIRE_SPIN, 0x53
175
+.equ FISSURE, 0x5A
176
+.equ FLAIL, 0xAF
177
+.equ FLAME_BURST, 0x1E1
178
+.equ FLAME_CHARGE, 0x1E8
179
+.equ FLAME_WHEEL, 0xAC
180
+.equ FLAMETHROWER, 0x35
181
+.equ FLARE_BLITZ, 0x18A
182
+.equ FLASH, 0x94
183
+.equ FLASH_CANNON, 0x1AE
184
+.equ FLATTER, 0x104
185
+.equ FLING, 0x176
186
+.equ FLOWER_SHIELD, 0x243
187
+.equ FLY, 0x13
188
+.equ FLYING_PRESS, 0x230
189
+.equ FOCUS_BLAST, 0x19B
190
+.equ FOCUS_ENERGY, 0x74
191
+.equ FOCUS_PUNCH, 0x108
192
+.equ FOLLOW_ME, 0x10A
193
+.equ FORCE_PALM, 0x18B
194
+.equ FORESIGHT, 0xC1
195
+.equ FORESTS_CURSE, 0x23B
196
+.equ FOUL_PLAY, 0x1EC
197
+.equ FREEZEDRY, 0x23D
198
+.equ FREEZE_SHOCK, 0x229
199
+.equ FRENZY_PLANT, 0x152
200
+.equ FROST_BREATH, 0x20C
201
+.equ FRUSTRATION, 0xDA
202
+.equ FURY_ATTACK, 0x1F
203
+.equ FURY_CUTTER, 0xD2
204
+.equ FURY_SWIPES, 0x9A
205
+.equ FUSION_BOLT, 0x22F
206
+.equ FUSION_FLARE, 0x22E
207
+.equ FUTURE_SIGHT, 0xF8
208
+.equ GASTRO_ACID, 0x17C
209
+.equ GEAR_GRIND, 0x220
210
+.equ GEOMANCY, 0x259
211
+.equ GIGA_DRAIN, 0xCA
212
+.equ GIGA_IMPACT, 0x1A0
213
+.equ GLACIATE, 0x225
214
+.equ GLARE, 0x89
215
+.equ GRASS_KNOT, 0x1BF
216
+.equ GRASS_PLEDGE, 0x208
217
+.equ GRASS_WHISTLE, 0x140
218
+.equ GRASSY_TERRAIN, 0x244
219
+.equ GRAVITY, 0x164
220
+.equ GROWL, 0x2D
221
+.equ GROWTH, 0x4A
222
+.equ GRUDGE, 0x120
223
+.equ GUARD_SPLIT, 0x1D6
224
+.equ GUARD_SWAP, 0x181
225
+.equ GUILLOTINE, 0xC
226
+.equ GUNK_SHOT, 0x1B9
227
+.equ GUST, 0x10
228
+.equ GYRO_BALL, 0x168
229
+.equ HAIL, 0x102
230
+.equ HAMMER_ARM, 0x167
231
+.equ HAPPY_HOUR, 0x25B
232
+.equ HARDEN, 0x6A
233
+.equ HAZE, 0x72
234
+.equ HEAD_CHARGE, 0x21F
235
+.equ HEAD_SMASH, 0x1C9
236
+.equ HEADBUTT, 0x1D
237
+.equ HEAL_BELL, 0xD7
238
+.equ HEAL_BLOCK, 0x179
239
+.equ HEAL_ORDER, 0x1C8
240
+.equ HEAL_PULSE, 0x1F9
241
+.equ HEALING_WISH, 0x169
242
+.equ HEART_STAMP, 0x213
243
+.equ HEART_SWAP, 0x187
244
+.equ HEAT_CRASH, 0x217
245
+.equ HEAT_WAVE, 0x101
246
+.equ HEAVY_SLAM, 0x1E4
247
+.equ HELPING_HAND, 0x10E
248
+.equ HEX, 0x1FA
249
+.equ HIDDEN_POWER, 0xED
250
+.equ HIGH_JUMP_KICK, 0x88
251
+.equ HOLD_BACK, 0x262
252
+.equ HOLD_HANDS, 0x267
253
+.equ HONE_CLAWS, 0x1D4
254
+.equ HORN_ATTACK, 0x1E
255
+.equ HORN_DRILL, 0x20
256
+.equ HORN_LEECH, 0x214
257
+.equ HOWL, 0x150
258
+.equ HURRICANE, 0x21E
259
+.equ HYDRO_CANNON, 0x134
260
+.equ HYDRO_PUMP, 0x38
261
+.equ HYPER_BEAM, 0x3F
262
+.equ HYPER_FANG, 0x9E
263
+.equ HYPERSPACE_FURY, 0x26D
264
+.equ HYPERSPACE_HOLE, 0x251
265
+.equ HYPER_VOICE, 0x130
266
+.equ HYPNOSIS, 0x5F
267
+.equ ICE_BALL, 0x12D
268
+.equ ICE_BEAM, 0x3A
269
+.equ ICE_BURN, 0x22A
270
+.equ ICE_FANG, 0x1A7
271
+.equ ICE_PUNCH, 0x8
272
+.equ ICE_SHARD, 0x1A4
273
+.equ ICICLE_CRASH, 0x22C
274
+.equ ICICLE_SPEAR, 0x14D
275
+.equ ICY_WIND, 0xC4
276
+.equ IMPRISON, 0x11E
277
+.equ INCINERATE, 0x1FE
278
+.equ INFERNO, 0x205
279
+.equ INFESTATION, 0x263
280
+.equ INGRAIN, 0x113
281
+.equ ION_DELUGE, 0x239
282
+.equ IRON_DEFENSE, 0x14E
283
+.equ IRON_HEAD, 0x1BA
284
+.equ IRON_TAIL, 0xE7
285
+.equ JUDGMENT, 0x1C1
286
+.equ JUMP_KICK, 0x1A
287
+.equ KARATE_CHOP, 0x2
288
+.equ KINESIS, 0x86
289
+.equ KINGS_SHIELD, 0x24C
290
+.equ KNOCK_OFF, 0x11A
291
+.equ LANDS_WRATH, 0x268
292
+.equ LAST_RESORT, 0x183
293
+.equ LAVA_PLUME, 0x1B4
294
+.equ LEAF_BLADE, 0x15C
295
+.equ LEAF_STORM, 0x1B5
296
+.equ LEAF_TORNADO, 0x218
297
+.equ LEECH_LIFE, 0x8D
298
+.equ LEECH_SEED, 0x49
299
+.equ LEER, 0x2B
300
+.equ LICK, 0x7A
301
+.equ LIGHT_OF_RUIN, 0x269
302
+.equ LIGHT_SCREEN, 0x71
303
+.equ LOCKON, 0xC7
304
+.equ LOVELY_KISS, 0x8E
305
+.equ LOW_KICK, 0x43
306
+.equ LOW_SWEEP, 0x1EA
307
+.equ LUCKY_CHANT, 0x17D
308
+.equ LUNAR_DANCE, 0x1CD
309
+.equ LUSTER_PURGE, 0x127
310
+.equ MACH_PUNCH, 0xB7
311
+.equ MAGIC_COAT, 0x115
312
+.equ MAGIC_ROOM, 0x1DE
313
+.equ MAGICAL_LEAF, 0x159
314
+.equ MAGMA_STORM, 0x1CF
315
+.equ MAGNET_BOMB, 0x1BB
316
+.equ MAGNETIC_FLUX, 0x25A
317
+.equ MAGNET_RISE, 0x189
318
+.equ MAGNITUDE, 0xDE
319
+.equ MAT_BLOCK, 0x231
320
+.equ ME_FIRST, 0x17E
321
+.equ MEAN_LOOK, 0xD4
322
+.equ MEDITATE, 0x60
323
+.equ MEGA_DRAIN, 0x48
324
+.equ MEGA_KICK, 0x19
325
+.equ MEGA_PUNCH, 0x5
326
+.equ MEGAHORN, 0xE0
327
+.equ MEMENTO, 0x106
328
+.equ METAL_BURST, 0x170
329
+.equ METAL_CLAW, 0xE8
330
+.equ METAL_SOUND, 0x13F
331
+.equ METEOR_MASH, 0x135
332
+.equ METRONOME, 0x76
333
+.equ MILK_DRINK, 0xD0
334
+.equ MIMIC, 0x66
335
+.equ MIND_READER, 0xAA
336
+.equ MINIMIZE, 0x6B
337
+.equ MIRACLE_EYE, 0x165
338
+.equ MIRROR_COAT, 0xF3
339
+.equ MIRROR_MOVE, 0x77
340
+.equ MIRROR_SHOT, 0x1AD
341
+.equ MIST, 0x36
342
+.equ MIST_BALL, 0x128
343
+.equ MISTY_TERRAIN, 0x245
344
+.equ MOONBLAST, 0x249
345
+.equ MOONLIGHT, 0xEC
346
+.equ MORNING_SUN, 0xEA
347
+.equ MUD_SLAP, 0xBD
348
+.equ MUD_BOMB, 0x1AA
349
+.equ MUD_SHOT, 0x155
350
+.equ MUD_SPORT, 0x12C
351
+.equ MUDDY_WATER, 0x14A
352
+.equ MYSTICAL_FIRE, 0x253
353
+.equ NASTY_PLOT, 0x1A1
354
+.equ NATURAL_GIFT, 0x16B
355
+.equ NATURE_POWER, 0x10B
356
+.equ NEEDLE_ARM, 0x12E
357
+.equ NIGHT_DAZE, 0x21B
358
+.equ NIGHT_SHADE, 0x65
359
+.equ NIGHT_SLASH, 0x190
360
+.equ NIGHTMARE, 0xAB
361
+.equ NOBLE_ROAR, 0x238
362
+.equ NUZZLE, 0x261
363
+.equ OBLIVION_WING, 0x265
364
+.equ OCTAZOOKA, 0xBE
365
+.equ ODOR_SLEUTH, 0x13C
366
+.equ OMINOUS_WIND, 0x1D2
367
+.equ ORIGIN_PULSE, 0x26A
368
+.equ OUTRAGE, 0xC8
369
+.equ OVERHEAT, 0x13B
370
+.equ PAIN_SPLIT, 0xDC
371
+.equ PARABOLIC_CHARGE, 0x23A
372
+.equ PARTING_SHOT, 0x23F
373
+.equ PAY_DAY, 0x6
374
+.equ PAYBACK, 0x173
375
+.equ PECK, 0x40
376
+.equ PERISH_SONG, 0xC3
377
+.equ PETAL_BLIZZARD, 0x23C
378
+.equ PETAL_DANCE, 0x50
379
+.equ PHANTOM_FORCE, 0x236
380
+.equ PIN_MISSILE, 0x2A
381
+.equ PLAY_NICE, 0x24D
382
+.equ PLAY_ROUGH, 0x247
383
+.equ PLUCK, 0x16D
384
+.equ POISON_FANG, 0x131
385
+.equ POISON_GAS, 0x8B
386
+.equ POISON_JAB, 0x18E
387
+.equ POISON_POWDER, 0x4D
388
+.equ POISON_STING, 0x28
389
+.equ POISON_TAIL, 0x156
390
+.equ POUND, 0x1
391
+.equ POWDER, 0x258
392
+.equ POWDER_SNOW, 0xB5
393
+.equ POWER_GEM, 0x198
394
+.equ POWER_SPLIT, 0x1D7
395
+.equ POWER_SWAP, 0x180
396
+.equ POWER_TRICK, 0x17B
397
+.equ POWERUP_PUNCH, 0x264
398
+.equ POWER_WHIP, 0x1B6
399
+.equ PRECIPICE_BLADES, 0x26B
400
+.equ PRESENT, 0xD9
401
+.equ PROTECT, 0xB6
402
+.equ PSYBEAM, 0x3C
403
+.equ PSYCH_UP, 0xF4
404
+.equ PSYCHIC, 0x5E
405
+.equ PSYCHO_BOOST, 0x162
406
+.equ PSYCHO_CUT, 0x1AB
407
+.equ PSYCHO_SHIFT, 0x177
408
+.equ PSYSHOCK, 0x1D9
409
+.equ PSYSTRIKE, 0x21C
410
+.equ PSYWAVE, 0x95
411
+.equ PUNISHMENT, 0x182
412
+.equ PURSUIT, 0xE4
413
+.equ QUASH, 0x1FF
414
+.equ QUICK_ATTACK, 0x62
415
+.equ QUICK_GUARD, 0x1F5
416
+.equ QUIVER_DANCE, 0x1E3
417
+.equ RAGE, 0x63
418
+.equ RAGE_POWDER, 0x1DC
419
+.equ RAIN_DANCE, 0xF0
420
+.equ RAPID_SPIN, 0xE5
421
+.equ RAZOR_LEAF, 0x4B
422
+.equ RAZOR_SHELL, 0x216
423
+.equ RAZOR_WIND, 0xD
424
+.equ RECOVER, 0x69
425
+.equ RECYCLE, 0x116
426
+.equ REFLECT, 0x73
427
+.equ REFLECT_TYPE, 0x201
428
+.equ REFRESH, 0x11F
429
+.equ RELIC_SONG, 0x223
430
+.equ REST, 0x9C
431
+.equ RETALIATE, 0x202
432
+.equ RETURN, 0xD8
433
+.equ REVENGE, 0x117
434
+.equ REVERSAL, 0xB3
435
+.equ ROAR, 0x2E
436
+.equ ROAR_OF_TIME, 0x1CB
437
+.equ ROCK_BLAST, 0x15E
438
+.equ ROCK_CLIMB, 0x1AF
439
+.equ ROCK_POLISH, 0x18D
440
+.equ ROCK_SLIDE, 0x9D
441
+.equ ROCK_SMASH, 0xF9
442
+.equ ROCK_THROW, 0x58
443
+.equ ROCK_TOMB, 0x13D
444
+.equ ROCK_WRECKER, 0x1B7
445
+.equ ROLE_PLAY, 0x110
446
+.equ ROLLING_KICK, 0x1B
447
+.equ ROLLOUT, 0xCD
448
+.equ ROOST, 0x163
449
+.equ ROTOTILLER, 0x233
450
+.equ ROUND, 0x1F0
451
+.equ SACRED_FIRE, 0xDD
452
+.equ SACRED_SWORD, 0x215
453
+.equ SAFEGUARD, 0xDB
454
+.equ SAND_ATTACK, 0x1C
455
+.equ SAND_TOMB, 0x148
456
+.equ SANDSTORM, 0xC9
457
+.equ SCALD, 0x1F7
458
+.equ SCARY_FACE, 0xB8
459
+.equ SCRATCH, 0xA
460
+.equ SCREECH, 0x67
461
+.equ SEARING_SHOT, 0x221
462
+.equ SECRET_POWER, 0x122
463
+.equ SECRET_SWORD, 0x224
464
+.equ SEED_BOMB, 0x192
465
+.equ SEED_FLARE, 0x1D1
466
+.equ SEISMIC_TOSS, 0x45
467
+.equ SELFDESTRUCT, 0x78
468
+.equ SHADOW_BALL, 0xF7
469
+.equ SHADOW_CLAW, 0x1A5
470
+.equ SHADOW_FORCE, 0x1D3
471
+.equ SHADOW_PUNCH, 0x145
472
+.equ SHADOW_SNEAK, 0x1A9
473
+.equ SHARPEN, 0x9F
474
+.equ SHEER_COLD, 0x149
475
+.equ SHELL_SMASH, 0x1F8
476
+.equ SHIFT_GEAR, 0x1FC
477
+.equ SHOCK_WAVE, 0x15F
478
+.equ SIGNAL_BEAM, 0x144
479
+.equ SILVER_WIND, 0x13E
480
+.equ SIMPLE_BEAM, 0x1ED
481
+.equ SING, 0x2F
482
+.equ SKETCH, 0xA6
483
+.equ SKILL_SWAP, 0x11D
484
+.equ SKULL_BASH, 0x82
485
+.equ SKY_ATTACK, 0x8F
486
+.equ SKY_DROP, 0x1FB
487
+.equ SKY_UPPERCUT, 0x147
488
+.equ SLACK_OFF, 0x12F
489
+.equ SLAM, 0x15
490
+.equ SLASH, 0xA3
491
+.equ SLEEP_POWDER, 0x4F
492
+.equ SLEEP_TALK, 0xD6
493
+.equ SLUDGE, 0x7C
494
+.equ SLUDGE_BOMB, 0xBC
495
+.equ SLUDGE_WAVE, 0x1E2
496
+.equ SMACK_DOWN, 0x1DF
497
+.equ SMELLING_SALTS, 0x109
498
+.equ SMOG, 0x7B
499
+.equ SMOKESCREEN, 0x6C
500
+.equ SNARL, 0x22B
501
+.equ SNATCH, 0x121
502
+.equ SNORE, 0xAD
503
+.equ SPIKY_SHIELD, 0x254
504
+.equ SOAK, 0x1E7
505
+.equ SOFTBOILED, 0x87
506
+.equ SOLAR_BEAM, 0x4C
507
+.equ SONIC_BOOM, 0x31
508
+.equ SPACIAL_REND, 0x1CC
509
+.equ SPARK, 0xD1
510
+.equ SPIDER_WEB, 0xA9
511
+.equ SPIKE_CANNON, 0x83
512
+.equ SPIKES, 0xBF
513
+.equ SPIT_UP, 0xFF
514
+.equ SPITE, 0xB4
515
+.equ SPLASH, 0x96
516
+.equ SPORE, 0x93
517
+.equ STEALTH_ROCK, 0x1BE
518
+.equ STEAM_ERUPTION, 0x250
519
+.equ STEEL_WING, 0xD3
520
+.equ STICKY_WEB, 0x234
521
+.equ STOCKPILE, 0xFE
522
+.equ STOMP, 0x17
523
+.equ STONE_EDGE, 0x1BC
524
+.equ STORED_POWER, 0x1F4
525
+.equ STORM_THROW, 0x1E0
526
+.equ STEAMROLLER, 0x219
527
+.equ STRENGTH, 0x46
528
+.equ STRING_SHOT, 0x51
529
+.equ STRUGGLE, 0xA5
530
+.equ STRUGGLE_BUG, 0x20A
531
+.equ STUN_SPORE, 0x4E
532
+.equ SUBMISSION, 0x42
533
+.equ SUBSTITUTE, 0xA4
534
+.equ SUCKER_PUNCH, 0x185
535
+.equ SUNNY_DAY, 0xF1
536
+.equ SUPER_FANG, 0xA2
537
+.equ SUPERPOWER, 0x114
538
+.equ SUPERSONIC, 0x30
539
+.equ SURF, 0x39
540
+.equ SWAGGER, 0xCF
541
+.equ SWALLOW, 0x100
542
+.equ SWEET_KISS, 0xBA
543
+.equ SWEET_SCENT, 0xE6
544
+.equ SWIFT, 0x81
545
+.equ SWITCHEROO, 0x19F
546
+.equ SWORDS_DANCE, 0xE
547
+.equ SYNCHRONOISE, 0x1E5
548
+.equ SYNTHESIS, 0xEB
549
+.equ TACKLE, 0x21
550
+.equ TAIL_GLOW, 0x126
551
+.equ TAIL_SLAP, 0x21D
552
+.equ TAIL_WHIP, 0x27
553
+.equ TAILWIND, 0x16E
554
+.equ TAKE_DOWN, 0x24
555
+.equ TAUNT, 0x10D
556
+.equ TECHNO_BLAST, 0x222
557
+.equ TEETER_DANCE, 0x12A
558
+.equ TELEKINESIS, 0x1DD
559
+.equ TELEPORT, 0x64
560
+.equ THIEF, 0xA8
561
+.equ THOUSAND_ARROWS, 0x266
562
+.equ THOUSAND_WAVES, 0x267
563
+.equ THRASH, 0x25
564
+.equ THUNDER, 0x57
565
+.equ THUNDER_FANG, 0x1A6
566
+.equ THUNDER_PUNCH, 0x9
567
+.equ THUNDER_SHOCK, 0x54
568
+.equ THUNDER_WAVE, 0x56
569
+.equ THUNDERBOLT, 0x55
570
+.equ TICKLE, 0x141
571
+.equ TOPSYTURVY, 0x240
572
+.equ TORMENT, 0x103
573
+.equ TOXIC, 0x5C
574
+.equ TOXIC_SPIKES, 0x186
575
+.equ TRANSFORM, 0x90
576
+.equ TRI_ATTACK, 0xA1
577
+.equ TRICK, 0x10F
578
+.equ TRICKORTREAT, 0x237
579
+.equ TRICK_ROOM, 0x1B1
580
+.equ TRIPLE_KICK, 0xA7
581
+.equ TRUMP_CARD, 0x178
582
+.equ TWINEEDLE, 0x29
583
+.equ TWISTER, 0xEF
584
+.equ UTURN, 0x171
585
+.equ UPROAR, 0xFD
586
+.equ VCREATE, 0x22D
587
+.equ VACUUM_WAVE, 0x19A
588
+.equ VENOM_DRENCH, 0x257
589
+.equ VENOSHOCK, 0x1DA
590
+.equ VICE_GRIP, 0xB
591
+.equ VINE_WHIP, 0x16
592
+.equ VITAL_THROW, 0xE9
593
+.equ VOLT_SWITCH, 0x209
594
+.equ VOLT_TACKLE, 0x158
595
+.equ WAKEUP_SLAP, 0x166
596
+.equ WATER_GUN, 0x37
597
+.equ WATER_PLEDGE, 0x206
598
+.equ WATER_PULSE, 0x160
599
+.equ WATER_SPORT, 0x15A
600
+.equ WATER_SPOUT, 0x143
601
+.equ WATERFALL, 0x7F
602
+.equ WATER_SHURIKEN, 0x252
603
+.equ WEATHER_BALL, 0x137
604
+.equ WHIRLPOOL, 0xFA
605
+.equ WHIRLWIND, 0x12
606
+.equ WIDE_GUARD, 0x1D5
607
+.equ WILD_CHARGE, 0x210
608
+.equ WILLOWISP, 0x105
609
+.equ WING_ATTACK, 0x11
610
+.equ WISH, 0x111
611
+.equ WITHDRAW, 0x6E
612
+.equ WONDER_ROOM, 0x1D8
613
+.equ WOOD_HAMMER, 0x1C4
614
+.equ WORK_UP, 0x20E
615
+.equ WORRY_SEED, 0x184
616
+.equ WRAP, 0x23
617
+.equ WRING_OUT, 0x17A
618
+.equ XSCISSOR, 0x194
619
+.equ YAWN, 0x119
620
+.equ ZAP_CANNON, 0xC0
621
+.equ ZEN_HEADBUTT, 0x1AC

+ 1246
- 0
src/include/battle_script.h
File diff suppressed because it is too large
View File


+ 35
- 0
src/include/bpre.h View File

@@ -0,0 +1,35 @@
1
+#ifndef BPRE_H_
2
+#define BPRE_H_
3
+
4
+#include "types.h"
5
+#include "sound.h"
6
+#include "fade.h"
7
+#include "lcd.h"
8
+#include <callback.h>
9
+#include <config.h>
10
+
11
+u16 *var_access(int index);
12
+u8 flag_check(int flag);
13
+void clear_flag(u16 flag);
14
+
15
+void* malloc(int size);
16
+void free(void* address);
17
+
18
+
19
+// sound related stuff
20
+extern MPlayTable mplay_table[];
21
+extern SongTable _songtable[];
22
+void m4aSongNumStart(u16 songid);
23
+void MPlayStart_rev01(MusicPlayerArea *ma, SongHeader *so);
24
+void MPlayContinue(MusicPlayerArea *ma);
25
+
26
+//graphical stuff
27
+
28
+//object related stuff
29
+void objc_exec();
30
+void obj_sync();
31
+
32
+//task related stuff
33
+void task_exec();
34
+
35
+#endif

+ 36
- 0
src/include/callback.h View File

@@ -0,0 +1,36 @@
1
+#ifndef CALLBACK_H_
2
+#define CALLBACK_H_
3
+
4
+#include <objects.h>
5
+typedef void (*callback)();
6
+typedef struct super {
7
+	callback callback1;
8
+	callback callback2;
9
+	callback callback2backup;
10
+	callback callback5_vblank;
11
+	callback hblank_callback;
12
+	u32 field_14;
13
+	u32 field_18;
14
+	u32 bit_to_wait_for;
15
+	u32 *ptr_vblank_counter;
16
+	u32 field_24;
17
+	u16 buttons_held;
18
+	u16 buttons_new;
19
+	u16 buttons_held_remapped;
20
+	u16 buttons_new_remapped;
21
+	u16 buttons_new_and_key_repeat;
22
+	u32 keypad_countdown;
23
+	u32 unused_padding;
24
+	sprite sprites[128];
25
+	u8 multi_purpose_state_tracker;
26
+	u8 gpu_sprites_upload_skip;
27
+ } super;
28
+extern super superstate;
29
+void set_callback2(callback address);
30
+void vblank_handler_set(callback address);
31
+
32
+
33
+
34
+void callback_overworld();
35
+
36
+#endif

+ 149
- 0
src/include/config.h View File

@@ -0,0 +1,149 @@
1
+#include "pkmn_types.h"
2
+
3
+#ifndef CONFIG_S_
4
+#define CONFIG_S_
5
+
6
+#define MAGIC_BOUNCE_FLAG	0x0203FFFD
7
+#define OBJ_1_TEMP			0x0203FFFE
8
+#define OBJ_2_TEMP			0x0203FFFF
9
+
10
+
11
+/*Variables regarding battle background loading*/
12
+#define NORMAL_VAR	0x4000
13
+#define SEA_VAR	0x4001
14
+
15
+/*Variables and Tags regarding mugshots*/
16
+#define MUGHSOT_1_TABLE 0x5000
17
+#define MUGSHOT_1_X 0x5001
18
+#define MUGSHOT_1_Y 0x5002
19
+#define MUGSHOT_1_TAG 0x1337
20
+
21
+#define MUGHSOT_2_TABLE 0x5003
22
+#define MUGSHOT_2_X 0x5004
23
+#define MUGSHOT_2_Y 0x5005
24
+#define MUGSHOT_2_TAG 0x1338
25
+
26
+/*Variable for special control*/
27
+#define CALLASM_VAR 0x5006
28
+
29
+/*Variables for camera control*/
30
+#define CAMERA_VAR_X 0x5007
31
+#define CAMERA_VAR_Y 0x5008
32
+
33
+/*Variables for walking script control*/
34
+#define WALK_SCRIPT_VAR 0x5009
35
+
36
+/*Variables to control the music overrides*/
37
+#define VAR_FROM_1 0x51FA
38
+#define VAR_FROM_2 0x51FB
39
+#define VAR_FROM_3 0x51FC
40
+#define VAR_TO_1 0x51FD
41
+#define VAR_TO_2 0x51FE
42
+#define VAR_TO_3 0x51FF
43
+
44
+/*Flag to enable the music overrides*/
45
+#define FLAG_ENABLE_MUSIC_OVERRIDES 0x742
46
+
47
+/*Special music override values*/
48
+#define MUS_NO_OVERRIDE 0xFFFF
49
+#define MUS_SKIP_PLAY 0xFFFE
50
+
51
+/*Flag to deactivate transparent textboxes*/
52
+#define FLAG_ACTIVATE		0x900
53
+#define FLAG_WALK_SCRIPT	0x901
54
+
55
+/*Effect IDs controlling various in-battle item effects etc.*/
56
+#define ITEM_EFFECT_SMOOTH_ROCK	0x48
57
+#define ITEM_EFFECT_DAMP_ROCK	0x49
58
+#define ITEM_EFFECT_HEAT_ROCK	0x4A
59
+#define ITEM_EFFECT_ICY_ROCK	0x4B
60
+#define ITEM_EFFECT_FLAME_ORB	0x4C
61
+#define ITEM_EFFECT_TOXIC_ORB	0x4D
62
+#define ITEM_EFFECT_EXPERT_BELT	0x4E
63
+
64
+/*Battlescript command definitions (Do not edit unless changing the command table [bs_command_table.S])*/
65
+#define BS_ATTACKSTRING			0x02
66
+#define BS_PPREDUCE				0x03
67
+
68
+#define BS_ATTACKANIMATION		0x09
69
+#define BS_WAITANIMATION		0x0A
70
+#define BS_PRINTSTRING			0x10
71
+#define BS_WAITMESSAGE			0x12
72
+#define BS_JUMPIFSTATUS			0x1C
73
+#define BS_JUMPIFABILITY		0x1E
74
+#define BS_JUMPIFSTAT			0x20
75
+#define BS_JUMPIFWORD			0x2B
76
+#define BS_GOTO					0x28
77
+#define BS_JUMPIFARRAYNOTEQUAL	0x2D
78
+#define BS_SETBYTE				0x2E
79
+#define BS_ORWORD				0x35
80
+#define BS_PAUSE 				0x39
81
+#define BS_WAITSTATE			0x3A
82
+#define BS_RETURN				0x3C
83
+#define BS_END3					0x3F
84
+#define BS_CALL					0x41
85
+#define BS_PLAYANIMATION		0x45
86
+#define BS_PLAYSTATANIM			0x48
87
+#define BS_SWITCH1				0x4C
88
+#define BS_SWITCH2				0x4D
89
+#define BS_SWITCH3				0x4E
90
+#define BS_NOP3					0x83
91
+#define BS_STATBUFFCHANGE		0x89
92
+#define BS_CASTFORMSWITCH		0xE7
93
+#define BS_CALLASM				0xF8
94
+#define BS_CURESTATUS			0xF9
95
+#define BS_SETWORD				0xFA
96
+
97
+/*For hacking the miracle eye command into set foresight*/
98
+/*Comment out the first define to deactivate the miracleeye injection in the command table*/
99
+#define MIRACLEEYE
100
+#define MIRACLEEYEADDRESS		0x08C158A0
101
+
102
+/*Ability index numbers*/
103
+#define	ABILITY_SAND_VEIL		0x08	/*Is included in vanilla firered*/
104
+#define ABILITY_NATURAL_CURE	0x1E
105
+#define	ABILITY_HUSTLE			0x37	/*Is included in vanilla firered*/
106
+#define ABILITY_GUTS			0x3E	/*Is included in vanilla firered*/
107
+#define ABILITY_MARVEL_SCALE	0x3F	/*Is included in vanilla firered*/
108
+#define ABILITY_SAND_STREAM		0x2D	/*Is included in vanilla firered*/
109
+#define ABILITY_AIR_LOCK		0x4D	/*Is included in vanilla firered*/
110
+#define	ABILITY_TANGLED_FEET	0x4E
111
+#define	ABILITY_SNOW_CLOAK		0x52
112
+#define ABILITY_HEAT_PROOF		0x56
113
+#define ABILITY_SIMPLE			0x57
114
+#define ABILITY_SKILL_LINK		0x5D
115
+#define	ABILITY_SNIPER			0x62
116
+#define	ABILITY_MAGIC_GUARD		0x63	/*Is not included in the project but needs to be here for consistancy reasons*/
117
+
118
+#define	ABILITY_TECHNICIAN		0x66
119
+#define ABILITY_MOLD_BREAK		0x69
120
+#define ABILITY_SUPER_LUCK		0x6A
121
+#define ABILITY_UNAWARE			0x6E
122
+#define ABILITY_TINTED_LENS		0x6F
123
+#define ABILITY_FILTER			0x70
124
+#define ABILITY_SCRAPPY			0x72
125
+
126
+#define ABILITY_SOLID_ROCK		0x75
127
+#define ABILITY_SNOW_WARNING	0x76
128
+#define	ABILITY_DEFEATIST		0x82
129
+#define ABILITY_MULTI_SCALE		0x89
130
+#define ABILITY_TOXIC_BOOST		0x8A
131
+#define ABILITY_FLARE_BOOST		0x8B
132
+
133
+#define ABILITY_REGENERATOR		0x91
134
+#define ABILITY_BIG_PECKS		0x92
135
+#define ABILITY_WONDER_SKIN		0x94
136
+
137
+#define ABILITY_MOXIE			0x9A
138
+#define ABILITY_MAGIC_BOUNCE	0x9D
139
+
140
+#define ABILITY_VICTORY_STAR	0xA3
141
+
142
+#define ABILITY_FUR_COAT		0xAA
143
+#define ABILITY_TURBOBLAZE		0xA4
144
+#define ABILITY_TERAVOLT		0xA5
145
+
146
+/*Some move effect IDs important for correct implementation*/
147
+#define MOVE_EFFECT_SACRED_SWORD	0xFF
148
+
149
+#endif

+ 21
- 0
src/include/fade.h View File

@@ -0,0 +1,21 @@
1
+#ifndef FADE_H_
2
+#define FADE_H_
3
+
4
+typedef struct fade_control
5
+{
6
+	u16 bg_pal_field;
7
+	u16 obj_pal_field;
8
+	u16 scale;
9
+	u16 mix_color;
10
+	u8 field_8;
11
+	u8 field_9;
12
+	u8 field_A;
13
+	u8 field_B;
14
+} fade_control;
15
+
16
+extern struct fade_control fade_controller;
17
+
18
+void fade_screen(u32 bitmask, int v1, int v2, int v3, u16 color);
19
+void fade_update();
20
+
21
+#endif

+ 44
- 0
src/include/lcd.h View File

@@ -0,0 +1,44 @@
1
+#ifndef LCD_H_
2
+#define LCD_H_
3
+
4
+#include "objects.h"
5
+
6
+struct bg_config
7
+{
8
+	u32 id : 2;
9
+	u32 char_base : 2;
10
+	u32 map_base : 5;
11
+	u32 size: 2;
12
+	u32 colormode : 1;
13
+	u32 priority : 2;
14
+};
15
+
16
+u8 gpu_copy_to_vram_by_bgid(u8 bg_id, void* source, u16 byte_size, u16 start_tile, u8 mode);
17
+void gpu_init_bgs();
18
+void gpu_tile_bg_drop_all_sets(u8 bg);
19
+void bg_vram_setup(u8 mirror, struct bg_config* configs, u8 count);
20
+void bg_set_tilemap(u8 bg_id, void* tilemap);
21
+void bg_nullify_tilemap(u8 bg_id);
22
+void* bg_get_tilemap(u8 bg_id);
23
+void bg_send_tilemap(u8 bg_id);
24
+void wram_decompress(void* src, void* dst);
25
+void pal_decompress_slice_to_faded_and_unfaded(void* src, u16 start, u16 end);
26
+void gpu_bg_show(u8 id);
27
+void gpu_bg_hide(u8 id);
28
+void gpu_sync_bg_visibility_and_mode();
29
+void lcd_io_set_func(u8 id, u16 value);
30
+void gpu_pal_upload();
31
+void gpu_sprites_upload();
32
+
33
+void gpu_pal_obj_alloc_tag_and_apply(resource *pal);
34
+void gpu_pal_free_by_tag(u16 tag);
35
+void gpu_tile_obj_free_by_tag(u16 tag);
36
+void obj_delete_and_free_tiles(object *obj);
37
+void obj_delete_all();
38
+
39
+u16 lcd_io_get(u8 id);
40
+
41
+#define palette_unfaded_buffer ((void*)0x020371F8)
42
+#define palette_faded_buffer ((void*)0x020375F8)
43
+
44
+#endif

+ 76
- 0
src/include/objects.h View File

@@ -0,0 +1,76 @@
1
+#ifndef OBJECTS_H_
2
+#define OBJECTS_H_
3
+
4
+#include "types.h"
5
+
6
+struct object;
7
+typedef struct object object;
8
+typedef void (*object_callback)(object*);
9
+
10
+typedef struct frame {
11
+  u16 data;
12
+  u16 duration;
13
+} frame;
14
+
15
+typedef struct rotscale_frame {
16
+  u16 scale_delta_x;
17
+  u16 scale_delta_y;
18
+  u8 rot_delta;
19
+  u8 duration;
20
+  u16 field_6;
21
+}  rotscale_frame;
22
+
23
+typedef struct sprite {
24
+  u16 attr0;
25
+  u16 attr1;
26
+  u16 attr2;
27
+  u16 rotscale;
28
+} sprite;
29
+
30
+typedef struct template {
31
+  u16 tiles_tag;
32
+  u16 pal_tag;
33
+  sprite *oam;
34
+  frame **animation;
35
+  u32 *graphics;
36
+  rotscale_frame **rotscale;
37
+  object_callback callback;
38
+} template;
39
+
40
+typedef struct object {
41
+  sprite final_oam;
42
+  frame **animation_table;
43
+  u32 *gfx_table;
44
+  u32 *rotscale_table;
45
+  template *template;
46
+  u32 field18;
47
+  u32 *callback;
48
+  u16 x;
49
+  u16 y;
50
+  u16 x2;
51
+  u16 y2;
52
+  u8 x_centre;
53
+  u8 y_centre;
54
+  u8 anim_number;
55
+  u8 anim_frame;
56
+  u8 anim_delay;
57
+  u8 counter;
58
+  u16 private[8];
59
+  u8 bitfield2;
60
+  u8 bitfield;
61
+  u16 anim_data_offset;
62
+  u8 field42;
63
+  u8 field43;
64
+} object;
65
+
66
+typedef struct resource {
67
+  void *data;
68
+  u16 size;
69
+  u16 tag;
70
+} resource;
71
+
72
+u8 template_instanciate_forward_search(struct template *t, u16 x, u16 y, u8 b);
73
+u16 gpu_tile_obj_decompress_alloc_tag_and_upload(resource *src);
74
+#define objects ((object*)0x0202063C)
75
+
76
+#endif

+ 24
- 0
src/include/pkmn_types.h View File

@@ -0,0 +1,24 @@
1
+#ifndef TYPES_S_
2
+#define TYPES_S_
3
+
4
+/*Some Type definitions*/
5
+#define TYPE_NORMAL 0x0
6
+#define TYPE_FIGHTING 0x1
7
+#define TYPE_FLYING 0x2
8
+#define TYPE_POISON 0x3
9
+#define TYPE_GROUND 0x4
10
+#define TYPE_ROCK 0x5
11
+#define TYPE_BUG 0x6
12
+#define TYPE_GHOST 0x7
13
+#define TYPE_STEEL 0x8
14
+
15
+#define TYPE_FIRE 0xA
16
+#define TYPE_WATER 0xB
17
+#define TYPE_GRASS 0xC
18
+#define TYPE_ELECTRIC 0xD
19
+#define TYPE_PSYCHIC 0xE
20
+#define TYPE_ICE 0xF
21
+#define TYPE_DRAGON 0x10
22
+#define TYPE_DARK 0x11
23
+
24
+#endif

+ 21
- 0
src/include/sound.h View File

@@ -0,0 +1,21 @@
1
+#ifndef SOUND_H_
2
+#define SOUND_H_
3
+
4
+#include "types.h"
5
+
6
+typedef struct MusicPlayerArea MusicPlayerArea;
7
+typedef struct MusicPlayerTrack MusicPlayerTrack;
8
+typedef struct SongHeader SongHeader;
9
+
10
+typedef struct {
11
+    MusicPlayerArea *ma;
12
+    MusicPlayerTrack *ta;
13
+    u32 tn;
14
+} MPlayTable;
15
+
16
+typedef struct {
17
+    SongHeader *so;
18
+    u16 ms, me;
19
+} SongTable;
20
+
21
+#endif

+ 19
- 0
src/include/types.h View File

@@ -0,0 +1,19 @@
1
+#ifndef TYPES_H_
2
+#define TYPES_H_
3
+
4
+typedef     unsigned char           u8;
5
+typedef     unsigned short int      u16;
6
+typedef     unsigned int            u32;
7
+typedef     unsigned long long int  u64;
8
+
9
+typedef     signed char             s8;
10
+typedef     signed short int        s16;
11
+typedef     signed int              s32;
12
+typedef     signed long long int    s64;
13
+
14
+typedef     float                   f32;
15
+typedef     double                  f64;
16
+
17
+#define		rgb5(r,g,b)				(u16)( r | ( g << 5) | ( b << 10) )
18
+
19
+#endif

+ 167
- 0
src/interface/lcd_io_test.S View File

@@ -0,0 +1,167 @@
1
+#include <config.h>
2
+
3
+.EQU BLDMOD,0x50
4
+.EQU LCD_WIN_IN,0x48
5
+.EQU COLEV,0x52
6
+
7
+.EQU WIN0_BG0,0x1
8
+.EQU WIN0_BG1,0x2
9
+.EQU WIN0_BG2,0x4
10
+.EQU WIN0_BG3,0x8
11
+.EQU WIN0_OBJ,0x10
12
+.EQU WIN0_FX,0x20
13
+
14
+.EQU WIN1_BG0,0x100
15
+.EQU WIN1_BG1,0x200
16
+.EQU WIN1_BG2,0x400
17
+.EQU WIN1_BG3,0x800
18
+.EQU WIN1_OBJ,0x1000
19
+.EQU WIN1_FX,0x2000
20
+
21
+.EQU WIN0_BG_OBJ,WIN0_BG0 | WIN0_BG1 | WIN0_BG2 | WIN0_BG3 | WIN0_OBJ
22
+.EQU WIN1_BG_OBJ,WIN1_BG0 | WIN1_BG1 | WIN1_BG2 | WIN1_BG3 | WIN1_OBJ
23
+
24
+@Testing
25
+
26
+.align 2
27
+.thumb
28
+.text
29
+
30
+
31
+get_flag_val:
32
+    push {lr}
33
+    ldr r0, =FLAG_ACTIVATE
34
+    bl flag_decrypt
35
+    pop {pc}
36
+
37
+.global trans_activate
38
+trans_activate:
39
+    push {r0-r7}
40
+    bl create_mugshot_on_variable
41
+    bl get_flag_val
42
+    cmp r0, #0
43
+    bne no_activate
44
+    mov r0, #LCD_WIN_IN
45
+    ldrh r1, =WIN0_BG_OBJ | WIN1_BG_OBJ | WIN0_FX
46
+    bl do_lcd_io_set
47
+
48
+    mov r0, #BLDMOD
49
+    ldrh r1, =0x3F41
50
+    bl do_lcd_io_set
51
+
52
+    mov r0, #COLEV
53
+    ldrh r1, =0x0A0F
54
+    bl do_lcd_io_set
55
+
56
+no_activate:
57
+
58
+    pop {r0-r7}
59
+    ldr r0, =0x08069371
60
+    mov r1, #0x50
61
+    bl task_add
62
+    pop {r0}
63
+    bx r0
64
+
65
+.global trans_deactivate
66
+trans_deactivate:
67
+    push {r0-r3}
68
+    bl delete_mugshot
69
+    mov r0, #LCD_WIN_IN
70
+    ldrh r1, =0x1F1F
71
+    bl do_lcd_io_set
72
+
73
+    mov r0, #BLDMOD
74
+    ldrh r1, =0x1E40
75
+    bl do_lcd_io_set
76
+
77
+    mov r0, #COLEV
78
+    ldrh r1, =0x0010
79
+    bl do_lcd_io_set
80
+
81
+    pop {r0-r3}
82
+    ldr r1, =0x0203709C
83
+    mov r0, #0
84
+    strb r0, [r1]
85
+    pop {r0}
86
+    bx r0
87
+
88
+do_lcd_io_set:
89
+    push {r3, lr}
90
+    ldr r3, =lcd_io_set_func
91
+    bl bxr3
92
+    pop {r3}
93
+    pop {r0}
94
+    bx r0
95
+
96
+task_add:
97
+    ldr r2, =task_add_func
98
+    bx r2
99
+
100
+bxr3:
101
+    bx r3
102
+
103
+.global pal_load_hook
104
+pal_load_hook:
105
+    push {r0}
106
+    bl get_flag_val
107
+    mov r1, r0
108
+    pop {r0}
109
+    cmp r1, #0
110
+    bne load_normal
111
+    ldr r1, =box_zero_flag
112
+    ldrb r1, [r1]
113
+    cmp r1, #0
114
+    beq load_normal
115
+    ldr r0, =palette_override
116
+    b load_hook_end
117
+load_normal:
118
+    ldr r1, =0x08471DEC
119
+    add r0, r1
120
+load_hook_end:
121
+    pop {r1}
122
+    bx r1
123
+
124
+.global pal_load_hook_2
125
+pal_load_hook_2:
126
+    add r5, #4
127
+    add r4, r5
128
+    ldr r0, [r4]
129
+    mov r1, r8
130
+    ldr r2, =box_zero_flag
131
+    ldrb r2, [r2]
132
+    cmp r2, #0
133
+    beq load_normal_2
134
+    push {r0-r1}
135
+    bl get_flag_val
136
+    mov r2, r0
137
+    pop {r0-r1}
138
+    cmp r2, #0
139
+    bne load_normal_2
140
+    ldr r0, =palette_override
141
+load_normal_2:
142
+    ldr r2, =0x08150009         @RETURN ADDRESS
143
+    bx r2
144
+
145
+flag_decrypt:
146
+    ldr r1, =flag_decrypt_func
147
+    bx r1
148
+
149
+.align 2
150
+
151
+palette_override:
152
+.hword 0
153
+.hword 0
154
+.hword 0x7FFF
155
+.hword 0x0000
156
+.hword 0x7FFF
157
+.hword 0x7FFF
158
+.hword 0x7FFF
159
+.hword 0x7FFF
160
+.hword 0x7FFF
161
+.hword 0x7FFF
162
+.hword 0x7FFF
163
+.hword 0
164
+.hword 0
165
+.hword 0
166
+.hword 0
167
+.hword 0

+ 131
- 0
src/interface/textbox_mugshots.c View File

@@ -0,0 +1,131 @@
1
+#include <stdbool.h>
2
+#include <objects.h>
3
+#include <config.h>
4
+
5
+typedef struct mugshot {
6
+	void *gfx;
7
+	void *pal;
8
+} mugshot;
9
+
10
+//extern mugshot* mugshots;
11
+mugshot *mugshots = (mugshot (*) ) 0x097007E0;
12
+u8 *temp_obj_id1 = (u8*) OBJ_1_TEMP;
13
+u8 *temp_obj_id2 = (u8*) OBJ_2_TEMP;
14
+
15
+void gpu_pal_obj_alloc_tag_and_apply(resource *pal);
16
+void gpu_pal_free_by_tag(u16 tag);
17
+void gpu_tile_obj_free_by_tag(u16 tag);
18
+void obj_delete_and_free_tiles(object *obj);
19
+void* memset(void* ptr, int value, u32 num);
20
+
21
+u16* var_access(u16 num);
22
+
23
+sprite mug_sprite = {0, 0x8000, 0, 0};
24
+
25
+void null_callback(object *self);
26
+
27
+template mugshot_1_template = {MUGSHOT_1_TAG, MUGSHOT_1_TAG, &mug_sprite, (frame **)0x08231CF0, 0, (rotscale_frame **)0x08231CFC, null_callback};
28
+template mugshot_2_template = {MUGSHOT_2_TAG, MUGSHOT_2_TAG, &mug_sprite, (frame **)0x08231CF0, 0, (rotscale_frame **)0x08231CFC, null_callback};
29
+
30
+void create_mugshot_on_variable()
31
+{
32
+	u16 *mug1_var = var_access(MUGHSOT_1_TABLE);
33
+	u16 c_mug1_var = *mug1_var;
34
+	u16 mug_id_1 = c_mug1_var & 0x3FFF;
35
+	if(mug_id_1 != 0)
36
+	{
37
+		bool h_flip = (c_mug1_var & 0x8000) > 0;
38
+		bool v_flip = (c_mug1_var & 0x4000) > 0;
39
+		u16 *mug1_x = var_access(MUGSHOT_1_X);
40
+		u16 *mug1_y = var_access(MUGSHOT_1_Y);
41
+
42
+		mug_id_1--;
43
+		resource gfx_mugshot_1 = {(mugshots[mug_id_1].gfx), 0x1C00, MUGSHOT_1_TAG};
44
+		resource pal_mugshot_1 = {(mugshots[mug_id_1].pal), MUGSHOT_1_TAG};
45
+
46
+
47
+		gpu_pal_obj_alloc_tag_and_apply(&pal_mugshot_1);
48
+		gpu_tile_obj_decompress_alloc_tag_and_upload(&gfx_mugshot_1);
49
+
50
+		*temp_obj_id1 = (u16)template_instanciate_forward_search(&mugshot_1_template, 0, 100, 1);
51
+
52
+		if(h_flip)
53
+			objects[*temp_obj_id1].final_oam.attr1 |= 0x1000;
54
+		if(v_flip)
55
+			objects[*temp_obj_id1].final_oam.attr1 |= 0x2000;
56
+
57
+		objects[*temp_obj_id1].x = *mug1_x;
58
+		objects[*temp_obj_id1].y = *mug1_y;
59
+	}
60
+	//return;
61
+	u16 *mug2_var = var_access(MUGHSOT_2_TABLE);
62
+	u16 c_mug2_var = *mug2_var;
63
+	u16 mug_id_2 = c_mug2_var & 0x3FFF;
64
+	if(mug_id_2 != 0)
65
+	{
66
+		bool h_flip = (c_mug2_var & 0x8000) > 0;
67
+		bool v_flip = (c_mug2_var & 0x4000) > 0;
68
+		u16 *mug2_x = var_access(MUGSHOT_2_X);
69
+		u16 *mug2_y = var_access(MUGSHOT_2_Y);
70
+
71
+		mug_id_2--;
72
+		resource gfx_mugshot_2 = {(mugshots[mug_id_2].gfx), 0x1C00, MUGSHOT_2_TAG};
73
+		resource pal_mugshot_2 = {(mugshots[mug_id_2].pal), MUGSHOT_2_TAG};
74
+
75
+
76
+		gpu_pal_obj_alloc_tag_and_apply(&pal_mugshot_2);
77
+		gpu_tile_obj_decompress_alloc_tag_and_upload(&gfx_mugshot_2);
78
+
79
+		c_mug2_var = *mug2_var;
80
+		*temp_obj_id2 = (u16)template_instanciate_forward_search(&mugshot_2_template, 0, 100, 1);
81
+
82
+		if(h_flip)
83
+			objects[*temp_obj_id2].final_oam.attr1 |= 0x1000;
84
+		if(v_flip)
85
+			objects[*temp_obj_id2].final_oam.attr1 |= 0x2000;
86
+
87
+		objects[*temp_obj_id2].x = *mug2_x;
88
+		objects[*temp_obj_id2].y = *mug2_y;
89
+	}
90
+}
91
+
92
+void delete_mugshot()
93
+{
94
+	u16 *mug1_var = var_access(MUGHSOT_1_TABLE);
95
+	u16 *mug2_var = var_access(MUGHSOT_2_TABLE);
96
+
97
+	if(*temp_obj_id1 != 0)
98
+	{
99
+		gpu_pal_free_by_tag(MUGSHOT_1_TAG);
100
+		gpu_tile_obj_free_by_tag(MUGSHOT_1_TAG);
101
+
102
+		//*mug1_var = 0;
103
+		//do reset mugshot var ; set it to old value instead
104
+
105
+		//*mug1_var = objects[object_id_1].private[0];
106
+
107
+		obj_delete_and_free_tiles(&objects[*temp_obj_id1]);
108
+		*temp_obj_id1 = 0;
109
+	}
110
+
111
+	//return;
112
+	if(*temp_obj_id2 != 0)
113
+	{
114
+		gpu_pal_free_by_tag(MUGSHOT_2_TAG);
115
+		gpu_tile_obj_free_by_tag(MUGSHOT_2_TAG);
116
+
117
+		//*mug2_var = 0;
118
+		//do reset mugshot var ; set it to old value instead
119
+
120
+		//*mug2_var = objects[object_id_2].private[0];
121
+
122
+		obj_delete_and_free_tiles(&objects[*temp_obj_id2]);
123
+		*temp_obj_id2 = 0;
124
+	}
125
+
126
+}
127
+
128
+void null_callback(object *self)
129
+{
130
+	//null_callback
131
+}

+ 26
- 0
src/interface/textbox_setup.S View File

@@ -0,0 +1,26 @@
1
+.text
2
+.align 2
3
+.thumb
4
+.global set_textbox
5
+set_textbox:
6
+	push {lr}
7
+	
8
+	ldr r0, pointer_bank
9
+	ldr r0, [r0]
10
+	bl setup_textwindow
11
+	
12
+	pop {r0}
13
+	bx r0
14
+	
15
+setup_textwindow:
16
+	ldr r1, rbox_8003B24
17
+	bx r1	
18
+
19
+.align 2
20
+rbox_8003B24:
21
+	.word 0x08003B24 | 1
22
+	
23
+pointer_bank:
24
+	.word 0x03000F14
25
+
26
+	

+ 37
- 0
src/interface/trans_mug_close_fix.S View File

@@ -0,0 +1,37 @@
1
+.EQU BLDMOD,0x50
2
+.EQU LCD_WIN_IN,0x48
3
+.EQU COLEV,0x52
4
+
5
+.align 2
6
+.text
7
+.thumb
8
+
9
+.global trans_mug_close_fix
10
+
11
+trans_mug_close_fix:
12
+	mov r0, r4
13
+	ldr r4, sub_08077508
14
+	bl bxr4
15
+	ldr r4, sub_08069B34
16
+	bl bxr4
17
+	push {r0-r4}
18
+	bl trans_deactivate_2
19
+	pop {r0-r4}
20
+	pop {r4}
21
+	pop {r0}
22
+	bx r0
23
+
24
+bxr4:
25
+	bx r4
26
+.align 2
27
+sub_08077508:
28
+	.word 0x08077508 + 1
29
+
30
+sub_08069B34:
31
+	.word 0x08069B34 + 1
32
+
33
+.align 2
34
+trans_deactivate_2:
35
+	push {lr}
36
+	bl delete_mugshot
37
+	pop {pc}

+ 10
- 0
src/moves/battle_engine/bs_table.S View File

@@ -0,0 +1,10 @@
1
+.align 2
2
+.text
3
+.thumb
4
+
5
+.global bs_command_table
6
+bs_command_table:
7
+.incbin "src/moves/battle_engine/bs_table_d.bin"
8
+
9
+.word bs_callasm+1
10
+.word bs_setword+1

+ 1
- 0
src/moves/battle_engine/bs_table_d.bin View File

@@ -0,0 +1 @@
1
+a×ÅÝÙá-â	ä�åIèñµòAô‰õ©õ…ö}úÑú¡ûQý‘ýÕý1þ…þ%!1­¡ÝA¹1‘‰
iù#Ù%ñ%	&Q&q&'¹'m(õ(y)¡)Í)ù)M*¹*å*+a+�+Å+	,I,i,Á,Í,í,-¡ÛA-q-Í-.5.õ.Á/029<‰>Ù>I?Õ@�AíCIL9NÝPQYQ•QÅQýQ1R}SáVX­XqZ%[u[¥[m\�\]‘]9^Í^©_á_]aÍa	bÙgñghEh¡h¹hýh©iYj±jio¥pÁq!rÅrAs©týtÉu‰v	wÙw!xÍxIyÅyåzÉ{�€Í€!�‘�Ñ�‚
ƒ†©‡=ˆ	‰]Œ™ŒñŒ‘ŽI�Ñ‘y’Õ’u”y•U—ý—-˜�˜y™qšµ›éœ­�­Ÿ ‘¢É£Y¤q¤Ù¤±¦•©ª¥ªÕª�«	­q­%®©®u¯°A±Õ²-³­³õ³Aµqµy¶u·é·¹!»¥»5¼u¼ͼi½µ½¾�¾¿i¿Å¿9ÀáÀ‘Ã	ÄÝÄ5Å•ÅÆqÆÕÆmÇuÈÍÈeÉåÊiËåËÁÌ=Í‘ÍIÎ1Ï™ÏÙÏ‘ÐIÑñÑ¡ÒeÓ¹Ó5ÔØ]ÙÙÙ9ݽßíßà!à

+ 29
- 0
src/moves/battle_engine/cmd_callasm.S View File

@@ -0,0 +1,29 @@
1
+.align 2
2
+.text
3
+.thumb
4
+.global bs_callasm
5
+bs_callasm:
6
+
7
+push {lr}
8
+ldr r0, =0x02023D74 @current script location
9
+ldr r0, [r0]
10
+ldrb r1, [r0, #1]
11
+ldrb r2, [r0, #2]
12
+lsl r2, #0x8
13
+orr r1, r2
14
+ldrb r2, [r0, #3]
15
+ldrb r3, [r0, #4]
16
+lsl r2, #0x10
17
+orr r1, r2
18
+lsl r3, #0x18
19
+orr r1, r3
20
+bl bxr1
21
+ldr r0, =0x02023D74
22
+ldr r1, [r0]
23
+add r1, #5
24
+str r1, [r0]
25
+pop {r0}
26
+bx r0
27
+
28
+bxr1:
29
+bx r1

+ 32
- 0
src/moves/battle_engine/cmd_setword.S View File

@@ -0,0 +1,32 @@
1
+.text
2
+.align 2
3
+.thumb
4
+.global bs_setword
5
+bs_setword:
6
+ldr r0, =0x02023D74 @current script location
7
+ldr r0, [r0]
8
+ldrb r1, [r0, #1]
9
+ldrb r2, [r0, #2]
10
+lsl r2, #0x8
11
+orr r1, r2
12
+ldrb r2, [r0, #3]
13
+ldrb r3, [r0, #4]
14
+lsl r2, #0x10
15
+orr r1, r2
16
+lsl r3, #0x18
17
+orr r1, r3
18
+add r0, #5
19
+ldrb r2, [r0, #0]
20
+ldrb r3, [r0, #1]
21
+lsl r3, #0x8
22
+orr r2, r3
23
+ldrb r3, [r0, #2]
24
+lsl r3, #0x10
25
+orr r2, r3
26
+ldrb r3, [r0, #3]
27
+orr r2, r3
28
+str r2, [r1]
29
+add r0, #4
30
+ldr r1, =0x02023D74
31
+str r0, [r1]
32
+bx lr

+ 51
- 0
src/moves/battle_engine/custom_print_string.S View File

@@ -0,0 +1,51 @@
1
+.text
2
+.align 2
3
+.thumb
4
+.global custom_print_string
5
+
6
+custom_print_string:
7
+	mov r0, #0xC2
8
+	lsl r0, r0, #0x1
9
+	cmp r0, r6
10
+	bne normalcode
11
+	ldr r0, ramlocation
12
+	ldr r7, [r0, #0x0]
13
+	cmp r7, #0x0
14
+	beq alternative
15
+	mov r0, #0xA
16
+	lsl r0, r0, #0x18
17
+	cmp r7, r0
18
+	bge alternative
19
+	mov r0, #0x8
20
+	lsl r0, r0, #0x18
21
+	cmp r7, r0
22
+	blt alternative
23
+	b continue
24
+alternative:
25
+	mov r6, #0xC
26
+	ldr r1, returntwo
27
+	bx r1
28
+continue:
29
+	ldr r0, returnone
30
+	bx r0
31
+normalcode:
32
+	ldr r1, otherramloc
33
+	mov r0, #0xFF
34
+	strb r0, [r1, #0x0]
35
+	pop {r3-r5}
36
+	mov r8, r3
37
+	mov r9, r4
38
+	mov r10, r5
39
+	pop {r4-r7}
40
+	pop {r0}
41
+	bx r0
42
+	
43
+.align 2
44
+ramlocation:
45
+	.word 0x0203C020
46
+returntwo:
47
+	.word 0x080D77D1
48
+returnone:
49
+	.word 0x080D77DD
50
+otherramloc:
51
+	.word 0x0202298C

+ 0
- 0
src/moves/battle_engine/new_move_first.S View File


Some files were not shown because too many files changed in this diff