diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/constants/abilities.h | 129 | ||||
-rw-r--r-- | include/constants/items.h | 448 | ||||
-rw-r--r-- | include/constants/moves.h | 473 | ||||
-rw-r--r-- | include/constants/sinnoh_dex.h | 158 | ||||
-rw-r--r-- | include/filesystem.h | 1 | ||||
-rw-r--r-- | include/global.h | 5 | ||||
-rw-r--r-- | include/math_util.h | 6 | ||||
-rw-r--r-- | include/move_data.h | 7 | ||||
-rw-r--r-- | include/party.h | 19 | ||||
-rw-r--r-- | include/pokemon.h | 468 | ||||
-rw-r--r-- | include/proto.h | 21 | ||||
-rw-r--r-- | include/seals.h | 15 | ||||
-rw-r--r-- | include/string_util.h | 3 | ||||
-rw-r--r-- | include/text.h | 6 |
14 files changed, 1629 insertions, 130 deletions
diff --git a/include/constants/abilities.h b/include/constants/abilities.h new file mode 100644 index 00000000..f107e623 --- /dev/null +++ b/include/constants/abilities.h @@ -0,0 +1,129 @@ +#ifndef POKEDIAMOND_CONSTANTS_ABILITIES_H +#define POKEDIAMOND_CONSTANTS_ABILITIES_H + +#define ABILITY_NONE 0 +#define ABILITY_STENCH 1 +#define ABILITY_DRIZZLE 2 +#define ABILITY_SPEED_BOOST 3 +#define ABILITY_BATTLE_ARMOR 4 +#define ABILITY_STURDY 5 +#define ABILITY_DAMP 6 +#define ABILITY_LIMBER 7 +#define ABILITY_SAND_VEIL 8 +#define ABILITY_STATIC 9 +#define ABILITY_VOLT_ABSORB 10 +#define ABILITY_WATER_ABSORB 11 +#define ABILITY_OBLIVIOUS 12 +#define ABILITY_CLOUD_NINE 13 +#define ABILITY_COMPOUND_EYES 14 +#define ABILITY_INSOMNIA 15 +#define ABILITY_COLOR_CHANGE 16 +#define ABILITY_IMMUNITY 17 +#define ABILITY_FLASH_FIRE 18 +#define ABILITY_SHIELD_DUST 19 +#define ABILITY_OWN_TEMPO 20 +#define ABILITY_SUCTION_CUPS 21 +#define ABILITY_INTIMIDATE 22 +#define ABILITY_SHADOW_TAG 23 +#define ABILITY_ROUGH_SKIN 24 +#define ABILITY_WONDER_GUARD 25 +#define ABILITY_LEVITATE 26 +#define ABILITY_EFFECT_SPORE 27 +#define ABILITY_SYNCHRONIZE 28 +#define ABILITY_CLEAR_BODY 29 +#define ABILITY_NATURAL_CURE 30 +#define ABILITY_LIGHTNING_ROD 31 +#define ABILITY_SERENE_GRACE 32 +#define ABILITY_SWIFT_SWIM 33 +#define ABILITY_CHLOROPHYLL 34 +#define ABILITY_ILLUMINATE 35 +#define ABILITY_TRACE 36 +#define ABILITY_HUGE_POWER 37 +#define ABILITY_POISON_POINT 38 +#define ABILITY_INNER_FOCUS 39 +#define ABILITY_MAGMA_ARMOR 40 +#define ABILITY_WATER_VEIL 41 +#define ABILITY_MAGNET_PULL 42 +#define ABILITY_SOUNDPROOF 43 +#define ABILITY_RAIN_DISH 44 +#define ABILITY_SAND_STREAM 45 +#define ABILITY_PRESSURE 46 +#define ABILITY_THICK_FAT 47 +#define ABILITY_EARLY_BIRD 48 +#define ABILITY_FLAME_BODY 49 +#define ABILITY_RUN_AWAY 50 +#define ABILITY_KEEN_EYE 51 +#define ABILITY_HYPER_CUTTER 52 +#define ABILITY_PICKUP 53 +#define ABILITY_TRUANT 54 +#define ABILITY_HUSTLE 55 +#define ABILITY_CUTE_CHARM 56 +#define ABILITY_PLUS 57 +#define ABILITY_MINUS 58 +#define ABILITY_FORECAST 59 +#define ABILITY_STICKY_HOLD 60 +#define ABILITY_SHED_SKIN 61 +#define ABILITY_GUTS 62 +#define ABILITY_MARVEL_SCALE 63 +#define ABILITY_LIQUID_OOZE 64 +#define ABILITY_OVERGROW 65 +#define ABILITY_BLAZE 66 +#define ABILITY_TORRENT 67 +#define ABILITY_SWARM 68 +#define ABILITY_ROCK_HEAD 69 +#define ABILITY_DROUGHT 70 +#define ABILITY_ARENA_TRAP 71 +#define ABILITY_VITAL_SPIRIT 72 +#define ABILITY_WHITE_SMOKE 73 +#define ABILITY_PURE_POWER 74 +#define ABILITY_SHELL_ARMOR 75 +#define ABILITY_AIR_LOCK 76 +#define ABILITY_TANGLED_FEET 77 +#define ABILITY_MOTOR_DRIVE 78 +#define ABILITY_RIVALRY 79 +#define ABILITY_STEADFAST 80 +#define ABILITY_SNOW_CLOAK 81 +#define ABILITY_GLUTTONY 82 +#define ABILITY_ANGER_POINT 83 +#define ABILITY_UNBURDEN 84 +#define ABILITY_HEATPROOF 85 +#define ABILITY_SIMPLE 86 +#define ABILITY_DRY_SKIN 87 +#define ABILITY_DOWNLOAD 88 +#define ABILITY_IRON_FIST 89 +#define ABILITY_POISON_HEAL 90 +#define ABILITY_ADAPTABILITY 91 +#define ABILITY_SKILL_LINK 92 +#define ABILITY_HYDRATION 93 +#define ABILITY_SOLAR_POWER 94 +#define ABILITY_QUICK_FEET 95 +#define ABILITY_NORMALIZE 96 +#define ABILITY_SNIPER 97 +#define ABILITY_MAGIC_GUARD 98 +#define ABILITY_NO_GUARD 99 +#define ABILITY_STALL 100 +#define ABILITY_TECHNICIAN 101 +#define ABILITY_LEAF_GUARD 102 +#define ABILITY_KLUTZ 103 +#define ABILITY_MOLD_BREAKER 104 +#define ABILITY_SUPER_LUCK 105 +#define ABILITY_AFTERMATH 106 +#define ABILITY_ANTICIPATION 107 +#define ABILITY_FOREWARN 108 +#define ABILITY_UNAWARE 109 +#define ABILITY_TINTED_LENS 110 +#define ABILITY_FILTER 111 +#define ABILITY_SLOW_START 112 +#define ABILITY_SCRAPPY 113 +#define ABILITY_STORM_DRAIN 114 +#define ABILITY_ICE_BODY 115 +#define ABILITY_SOLID_ROCK 116 +#define ABILITY_SNOW_WARNING 117 +#define ABILITY_HONEY_GATHER 118 +#define ABILITY_FRISK 119 +#define ABILITY_RECKLESS 120 +#define ABILITY_MULTITYPE 121 +#define ABILITY_FLOWER_GIFT 122 +#define ABILITY_BAD_DREAMS 123 + +#endif //POKEDIAMOND_CONSTANTS_ABILITIES_H diff --git a/include/constants/items.h b/include/constants/items.h new file mode 100644 index 00000000..98c3dd97 --- /dev/null +++ b/include/constants/items.h @@ -0,0 +1,448 @@ +#ifndef POKEDIAMOND_CONSTANTS_ITEMS_H +#define POKEDIAMOND_CONSTANTS_ITEMS_H + +#define ITEM_NONE 0 +#define ITEM_MASTER_BALL 1 +#define ITEM_ULTRA_BALL 2 +#define ITEM_GREAT_BALL 3 +#define ITEM_POKE_BALL 4 +#define ITEM_SAFARI_BALL 5 +#define ITEM_NET_BALL 6 +#define ITEM_DIVE_BALL 7 +#define ITEM_NEST_BALL 8 +#define ITEM_REPEAT_BALL 9 +#define ITEM_TIMER_BALL 10 +#define ITEM_LUXURY_BALL 11 +#define ITEM_PREMIER_BALL 12 +#define ITEM_DUSK_BALL 13 +#define ITEM_HEAL_BALL 14 +#define ITEM_QUICK_BALL 15 +#define ITEM_CHERISH_BALL 16 +#define ITEM_POTION 17 +#define ITEM_ANTIDOTE 18 +#define ITEM_BURN_HEAL 19 +#define ITEM_ICE_HEAL 20 +#define ITEM_AWAKENING 21 +#define ITEM_PARLYZ_HEAL 22 +#define ITEM_FULL_RESTORE 23 +#define ITEM_MAX_POTION 24 +#define ITEM_HYPER_POTION 25 +#define ITEM_SUPER_POTION 26 +#define ITEM_FULL_HEAL 27 +#define ITEM_REVIVE 28 +#define ITEM_MAX_REVIVE 29 +#define ITEM_FRESH_WATER 30 +#define ITEM_SODA_POP 31 +#define ITEM_LEMONADE 32 +#define ITEM_MOOMOO_MILK 33 +#define ITEM_ENERGYPOWDER 34 +#define ITEM_ENERGY_ROOT 35 +#define ITEM_HEAL_POWDER 36 +#define ITEM_REVIVAL_HERB 37 +#define ITEM_ETHER 38 +#define ITEM_MAX_ETHER 39 +#define ITEM_ELIXIR 40 +#define ITEM_MAX_ELIXIR 41 +#define ITEM_LAVA_COOKIE 42 +#define ITEM_BERRY_JUICE 43 +#define ITEM_SACRED_ASH 44 +#define ITEM_HP_UP 45 +#define ITEM_PROTEIN 46 +#define ITEM_IRON 47 +#define ITEM_CARBOS 48 +#define ITEM_CALCIUM 49 +#define ITEM_RARE_CANDY 50 +#define ITEM_PP_UP 51 +#define ITEM_ZINC 52 +#define ITEM_PP_MAX 53 +#define ITEM_OLD_GATEAU 54 +#define ITEM_GUARD_SPEC_ 55 +#define ITEM_DIRE_HIT 56 +#define ITEM_X_ATTACK 57 +#define ITEM_X_DEFENSE 58 +#define ITEM_X_SPEED 59 +#define ITEM_X_ACCURACY 60 +#define ITEM_X_SPECIAL 61 +#define ITEM_X_SP__DEF 62 +#define ITEM_POKE_DOLL 63 +#define ITEM_FLUFFY_TAIL 64 +#define ITEM_BLUE_FLUTE 65 +#define ITEM_YELLOW_FLUTE 66 +#define ITEM_RED_FLUTE 67 +#define ITEM_BLACK_FLUTE 68 +#define ITEM_WHITE_FLUTE 69 +#define ITEM_SHOAL_SALT 70 +#define ITEM_SHOAL_SHELL 71 +#define ITEM_RED_SHARD 72 +#define ITEM_BLUE_SHARD 73 +#define ITEM_YELLOW_SHARD 74 +#define ITEM_GREEN_SHARD 75 +#define ITEM_SUPER_REPEL 76 +#define ITEM_MAX_REPEL 77 +#define ITEM_ESCAPE_ROPE 78 +#define ITEM_REPEL 79 +#define ITEM_SUN_STONE 80 +#define ITEM_MOON_STONE 81 +#define ITEM_FIRE_STONE 82 +#define ITEM_THUNDERSTONE 83 +#define ITEM_WATER_STONE 84 +#define ITEM_LEAF_STONE 85 +#define ITEM_TINYMUSHROOM 86 +#define ITEM_BIG_MUSHROOM 87 +#define ITEM_PEARL 88 +#define ITEM_BIG_PEARL 89 +#define ITEM_STARDUST 90 +#define ITEM_STAR_PIECE 91 +#define ITEM_NUGGET 92 +#define ITEM_HEART_SCALE 93 +#define ITEM_HONEY 94 +#define ITEM_GROWTH_MULCH 95 +#define ITEM_DAMP_MULCH 96 +#define ITEM_STABLE_MULCH 97 +#define ITEM_GOOEY_MULCH 98 +#define ITEM_ROOT_FOSSIL 99 +#define ITEM_CLAW_FOSSIL 100 +#define ITEM_HELIX_FOSSIL 101 +#define ITEM_DOME_FOSSIL 102 +#define ITEM_OLD_AMBER 103 +#define ITEM_ARMOR_FOSSIL 104 +#define ITEM_SKULL_FOSSIL 105 +#define ITEM_RARE_BONE 106 +#define ITEM_SHINY_STONE 107 +#define ITEM_DUSK_STONE 108 +#define ITEM_DAWN_STONE 109 +#define ITEM_OVAL_STONE 110 +#define ITEM_ODD_KEYSTONE 111 + +#define ITEM_ADAMANT_ORB 135 +#define ITEM_LUSTROUS_ORB 136 +#define ITEM_GRASS_MAIL 137 +#define ITEM_FLAME_MAIL 138 +#define ITEM_BUBBLE_MAIL 139 +#define ITEM_BLOOM_MAIL 140 +#define ITEM_TUNNEL_MAIL 141 +#define ITEM_STEEL_MAIL 142 +#define ITEM_HEART_MAIL 143 +#define ITEM_SNOW_MAIL 144 +#define ITEM_SPACE_MAIL 145 +#define ITEM_AIR_MAIL 146 +#define ITEM_MOSAIC_MAIL 147 +#define ITEM_BRICK_MAIL 148 +#define ITEM_CHERI_BERRY 149 +#define ITEM_CHESTO_BERRY 150 +#define ITEM_PECHA_BERRY 151 +#define ITEM_RAWST_BERRY 152 +#define ITEM_ASPEAR_BERRY 153 +#define ITEM_LEPPA_BERRY 154 +#define ITEM_ORAN_BERRY 155 +#define ITEM_PERSIM_BERRY 156 +#define ITEM_LUM_BERRY 157 +#define ITEM_SITRUS_BERRY 158 +#define ITEM_FIGY_BERRY 159 +#define ITEM_WIKI_BERRY 160 +#define ITEM_MAGO_BERRY 161 +#define ITEM_AGUAV_BERRY 162 +#define ITEM_IAPAPA_BERRY 163 +#define ITEM_RAZZ_BERRY 164 +#define ITEM_BLUK_BERRY 165 +#define ITEM_NANAB_BERRY 166 +#define ITEM_WEPEAR_BERRY 167 +#define ITEM_PINAP_BERRY 168 +#define ITEM_POMEG_BERRY 169 +#define ITEM_KELPSY_BERRY 170 +#define ITEM_QUALOT_BERRY 171 +#define ITEM_HONDEW_BERRY 172 +#define ITEM_GREPA_BERRY 173 +#define ITEM_TAMATO_BERRY 174 +#define ITEM_CORNN_BERRY 175 +#define ITEM_MAGOST_BERRY 176 +#define ITEM_RABUTA_BERRY 177 +#define ITEM_NOMEL_BERRY 178 +#define ITEM_SPELON_BERRY 179 +#define ITEM_PAMTRE_BERRY 180 +#define ITEM_WATMEL_BERRY 181 +#define ITEM_DURIN_BERRY 182 +#define ITEM_BELUE_BERRY 183 +#define ITEM_OCCA_BERRY 184 +#define ITEM_PASSHO_BERRY 185 +#define ITEM_WACAN_BERRY 186 +#define ITEM_RINDO_BERRY 187 +#define ITEM_YACHE_BERRY 188 +#define ITEM_CHOPLE_BERRY 189 +#define ITEM_KEBIA_BERRY 190 +#define ITEM_SHUCA_BERRY 191 +#define ITEM_COBA_BERRY 192 +#define ITEM_PAYAPA_BERRY 193 +#define ITEM_TANGA_BERRY 194 +#define ITEM_CHARTI_BERRY 195 +#define ITEM_KASIB_BERRY 196 +#define ITEM_HABAN_BERRY 197 +#define ITEM_COLBUR_BERRY 198 +#define ITEM_BABIRI_BERRY 199 +#define ITEM_CHILAN_BERRY 200 +#define ITEM_LIECHI_BERRY 201 +#define ITEM_GANLON_BERRY 202 +#define ITEM_SALAC_BERRY 203 +#define ITEM_PETAYA_BERRY 204 +#define ITEM_APICOT_BERRY 205 +#define ITEM_LANSAT_BERRY 206 +#define ITEM_STARF_BERRY 207 +#define ITEM_ENIGMA_BERRY 208 +#define ITEM_MICLE_BERRY 209 +#define ITEM_CUSTAP_BERRY 210 +#define ITEM_JABOCA_BERRY 211 +#define ITEM_ROWAP_BERRY 212 +#define ITEM_BRIGHTPOWDER 213 +#define ITEM_WHITE_HERB 214 +#define ITEM_MACHO_BRACE 215 +#define ITEM_EXP__SHARE 216 +#define ITEM_QUICK_CLAW 217 +#define ITEM_SOOTHE_BELL 218 +#define ITEM_MENTAL_HERB 219 +#define ITEM_CHOICE_BAND 220 +#define ITEM_KINGS_ROCK 221 +#define ITEM_SILVERPOWDER 222 +#define ITEM_AMULET_COIN 223 +#define ITEM_CLEANSE_TAG 224 +#define ITEM_SOUL_DEW 225 +#define ITEM_DEEPSEATOOTH 226 +#define ITEM_DEEPSEASCALE 227 +#define ITEM_SMOKE_BALL 228 +#define ITEM_EVERSTONE 229 +#define ITEM_FOCUS_BAND 230 +#define ITEM_LUCKY_EGG 231 +#define ITEM_SCOPE_LENS 232 +#define ITEM_METAL_COAT 233 +#define ITEM_LEFTOVERS 234 +#define ITEM_DRAGON_SCALE 235 +#define ITEM_LIGHT_BALL 236 +#define ITEM_SOFT_SAND 237 +#define ITEM_HARD_STONE 238 +#define ITEM_MIRACLE_SEED 239 +#define ITEM_BLACKGLASSES 240 +#define ITEM_BLACK_BELT 241 +#define ITEM_MAGNET 242 +#define ITEM_MYSTIC_WATER 243 +#define ITEM_SHARP_BEAK 244 +#define ITEM_POISON_BARB 245 +#define ITEM_NEVERMELTICE 246 +#define ITEM_SPELL_TAG 247 +#define ITEM_TWISTEDSPOON 248 +#define ITEM_CHARCOAL 249 +#define ITEM_DRAGON_FANG 250 +#define ITEM_SILK_SCARF 251 +#define ITEM_UPGRADE 252 +#define ITEM_SHELL_BELL 253 +#define ITEM_SEA_INCENSE 254 +#define ITEM_LAX_INCENSE 255 +#define ITEM_LUCKY_PUNCH 256 +#define ITEM_METAL_POWDER 257 +#define ITEM_THICK_CLUB 258 +#define ITEM_STICK 259 +#define ITEM_RED_SCARF 260 +#define ITEM_BLUE_SCARF 261 +#define ITEM_PINK_SCARF 262 +#define ITEM_GREEN_SCARF 263 +#define ITEM_YELLOW_SCARF 264 +#define ITEM_WIDE_LENS 265 +#define ITEM_MUSCLE_BAND 266 +#define ITEM_WISE_GLASSES 267 +#define ITEM_EXPERT_BELT 268 +#define ITEM_LIGHT_CLAY 269 +#define ITEM_LIFE_ORB 270 +#define ITEM_POWER_HERB 271 +#define ITEM_TOXIC_ORB 272 +#define ITEM_FLAME_ORB 273 +#define ITEM_QUICK_POWDER 274 +#define ITEM_FOCUS_SASH 275 +#define ITEM_ZOOM_LENS 276 +#define ITEM_METRONOME 277 +#define ITEM_IRON_BALL 278 +#define ITEM_LAGGING_TAIL 279 +#define ITEM_DESTINY_KNOT 280 +#define ITEM_BLACK_SLUDGE 281 +#define ITEM_ICY_ROCK 282 +#define ITEM_SMOOTH_ROCK 283 +#define ITEM_HEAT_ROCK 284 +#define ITEM_DAMP_ROCK 285 +#define ITEM_GRIP_CLAW 286 +#define ITEM_CHOICE_SCARF 287 +#define ITEM_STICKY_BARB 288 +#define ITEM_POWER_BRACER 289 +#define ITEM_POWER_BELT 290 +#define ITEM_POWER_LENS 291 +#define ITEM_POWER_BAND 292 +#define ITEM_POWER_ANKLET 293 +#define ITEM_POWER_WEIGHT 294 +#define ITEM_SHED_SHELL 295 +#define ITEM_BIG_ROOT 296 +#define ITEM_CHOICE_SPECS 297 +#define ITEM_FLAME_PLATE 298 +#define ITEM_SPLASH_PLATE 299 +#define ITEM_ZAP_PLATE 300 +#define ITEM_MEADOW_PLATE 301 +#define ITEM_ICICLE_PLATE 302 +#define ITEM_FIST_PLATE 303 +#define ITEM_TOXIC_PLATE 304 +#define ITEM_EARTH_PLATE 305 +#define ITEM_SKY_PLATE 306 +#define ITEM_MIND_PLATE 307 +#define ITEM_INSECT_PLATE 308 +#define ITEM_STONE_PLATE 309 +#define ITEM_SPOOKY_PLATE 310 +#define ITEM_DRACO_PLATE 311 +#define ITEM_DREAD_PLATE 312 +#define ITEM_IRON_PLATE 313 +#define ITEM_ODD_INCENSE 314 +#define ITEM_ROCK_INCENSE 315 +#define ITEM_FULL_INCENSE 316 +#define ITEM_WAVE_INCENSE 317 +#define ITEM_ROSE_INCENSE 318 +#define ITEM_LUCK_INCENSE 319 +#define ITEM_PURE_INCENSE 320 +#define ITEM_PROTECTOR 321 +#define ITEM_ELECTIRIZER 322 +#define ITEM_MAGMARIZER 323 +#define ITEM_DUBIOUS_DISC 324 +#define ITEM_REAPER_CLOTH 325 +#define ITEM_RAZOR_CLAW 326 +#define ITEM_RAZOR_FANG 327 +#define ITEM_TM01 328 +#define ITEM_TM02 329 +#define ITEM_TM03 330 +#define ITEM_TM04 331 +#define ITEM_TM05 332 +#define ITEM_TM06 333 +#define ITEM_TM07 334 +#define ITEM_TM08 335 +#define ITEM_TM09 336 +#define ITEM_TM10 337 +#define ITEM_TM11 338 +#define ITEM_TM12 339 +#define ITEM_TM13 340 +#define ITEM_TM14 341 +#define ITEM_TM15 342 +#define ITEM_TM16 343 +#define ITEM_TM17 344 +#define ITEM_TM18 345 +#define ITEM_TM19 346 +#define ITEM_TM20 347 +#define ITEM_TM21 348 +#define ITEM_TM22 349 +#define ITEM_TM23 350 +#define ITEM_TM24 351 +#define ITEM_TM25 352 +#define ITEM_TM26 353 +#define ITEM_TM27 354 +#define ITEM_TM28 355 +#define ITEM_TM29 356 +#define ITEM_TM30 357 +#define ITEM_TM31 358 +#define ITEM_TM32 359 +#define ITEM_TM33 360 +#define ITEM_TM34 361 +#define ITEM_TM35 362 +#define ITEM_TM36 363 +#define ITEM_TM37 364 +#define ITEM_TM38 365 +#define ITEM_TM39 366 +#define ITEM_TM40 367 +#define ITEM_TM41 368 +#define ITEM_TM42 369 +#define ITEM_TM43 370 +#define ITEM_TM44 371 +#define ITEM_TM45 372 +#define ITEM_TM46 373 +#define ITEM_TM47 374 +#define ITEM_TM48 375 +#define ITEM_TM49 376 +#define ITEM_TM50 377 +#define ITEM_TM51 378 +#define ITEM_TM52 379 +#define ITEM_TM53 380 +#define ITEM_TM54 381 +#define ITEM_TM55 382 +#define ITEM_TM56 383 +#define ITEM_TM57 384 +#define ITEM_TM58 385 +#define ITEM_TM59 386 +#define ITEM_TM60 387 +#define ITEM_TM61 388 +#define ITEM_TM62 389 +#define ITEM_TM63 390 +#define ITEM_TM64 391 +#define ITEM_TM65 392 +#define ITEM_TM66 393 +#define ITEM_TM67 394 +#define ITEM_TM68 395 +#define ITEM_TM69 396 +#define ITEM_TM70 397 +#define ITEM_TM71 398 +#define ITEM_TM72 399 +#define ITEM_TM73 400 +#define ITEM_TM74 401 +#define ITEM_TM75 402 +#define ITEM_TM76 403 +#define ITEM_TM77 404 +#define ITEM_TM78 405 +#define ITEM_TM79 406 +#define ITEM_TM80 407 +#define ITEM_TM81 408 +#define ITEM_TM82 409 +#define ITEM_TM83 410 +#define ITEM_TM84 411 +#define ITEM_TM85 412 +#define ITEM_TM86 413 +#define ITEM_TM87 414 +#define ITEM_TM88 415 +#define ITEM_TM89 416 +#define ITEM_TM90 417 +#define ITEM_TM91 418 +#define ITEM_TM92 419 +#define ITEM_HM01 420 +#define ITEM_HM02 421 +#define ITEM_HM03 422 +#define ITEM_HM04 423 +#define ITEM_HM05 424 +#define ITEM_HM06 425 +#define ITEM_HM07 426 +#define ITEM_HM08 427 +#define ITEM_EXPLORER_KIT 428 +#define ITEM_LOOT_SACK 429 +#define ITEM_RULE_BOOK 430 +#define ITEM_POKE_RADAR 431 +#define ITEM_POINT_CARD 432 +#define ITEM_JOURNAL 433 +#define ITEM_SEAL_CASE 434 +#define ITEM_FASHION_CASE 435 +#define ITEM_SEAL_BAG 436 +#define ITEM_PAL_PAD 437 +#define ITEM_WORKS_KEY 438 +#define ITEM_OLD_CHARM 439 +#define ITEM_GALACTIC_KEY 440 +#define ITEM_RED_CHAIN 441 +#define ITEM_TOWN_MAP 442 +#define ITEM_VS__SEEKER 443 +#define ITEM_COIN_CASE 444 +#define ITEM_OLD_ROD 445 +#define ITEM_GOOD_ROD 446 +#define ITEM_SUPER_ROD 447 +#define ITEM_SPRAYDUCK 448 +#define ITEM_POFFIN_CASE 449 +#define ITEM_BICYCLE 450 +#define ITEM_SUITE_KEY 451 +#define ITEM_OAKS_LETTER 452 +#define ITEM_LUNAR_WING 453 +#define ITEM_MEMBER_CARD 454 +#define ITEM_AZURE_FLUTE 455 +#define ITEM_S_S__TICKET 456 +#define ITEM_CONTEST_PASS 457 +#define ITEM_MAGMA_STONE 458 +#define ITEM_PARCEL 459 +#define ITEM_COUPON_1 460 +#define ITEM_COUPON_2 461 +#define ITEM_COUPON_3 462 +#define ITEM_STORAGE_KEY 463 +#define ITEM_SECRETPOTION 464 + +#endif //POKEDIAMOND_CONSTANTS_ITEMS_H diff --git a/include/constants/moves.h b/include/constants/moves.h new file mode 100644 index 00000000..e25c16c9 --- /dev/null +++ b/include/constants/moves.h @@ -0,0 +1,473 @@ +#ifndef POKEDIAMOND_CONSTANTS_MOVES_H +#define POKEDIAMOND_CONSTANTS_MOVES_H + +#define MOVE_NONE 0 +#define MOVE_POUND 1 +#define MOVE_KARATE_CHOP 2 +#define MOVE_DOUBLE_SLAP 3 +#define MOVE_COMET_PUNCH 4 +#define MOVE_MEGA_PUNCH 5 +#define MOVE_PAY_DAY 6 +#define MOVE_FIRE_PUNCH 7 +#define MOVE_ICE_PUNCH 8 +#define MOVE_THUNDER_PUNCH 9 +#define MOVE_SCRATCH 10 +#define MOVE_VISE_GRIP 11 +#define MOVE_GUILLOTINE 12 +#define MOVE_RAZOR_WIND 13 +#define MOVE_SWORDS_DANCE 14 +#define MOVE_CUT 15 +#define MOVE_GUST 16 +#define MOVE_WING_ATTACK 17 +#define MOVE_WHIRLWIND 18 +#define MOVE_FLY 19 +#define MOVE_BIND 20 +#define MOVE_SLAM 21 +#define MOVE_VINE_WHIP 22 +#define MOVE_STOMP 23 +#define MOVE_DOUBLE_KICK 24 +#define MOVE_MEGA_KICK 25 +#define MOVE_JUMP_KICK 26 +#define MOVE_ROLLING_KICK 27 +#define MOVE_SAND_ATTACK 28 +#define MOVE_HEADBUTT 29 +#define MOVE_HORN_ATTACK 30 +#define MOVE_FURY_ATTACK 31 +#define MOVE_HORN_DRILL 32 +#define MOVE_TACKLE 33 +#define MOVE_BODY_SLAM 34 +#define MOVE_WRAP 35 +#define MOVE_TAKE_DOWN 36 +#define MOVE_THRASH 37 +#define MOVE_DOUBLE_EDGE 38 +#define MOVE_TAIL_WHIP 39 +#define MOVE_POISON_STING 40 +#define MOVE_TWINEEDLE 41 +#define MOVE_PIN_MISSILE 42 +#define MOVE_LEER 43 +#define MOVE_BITE 44 +#define MOVE_GROWL 45 +#define MOVE_ROAR 46 +#define MOVE_SING 47 +#define MOVE_SUPERSONIC 48 +#define MOVE_SONIC_BOOM 49 +#define MOVE_DISABLE 50 +#define MOVE_ACID 51 +#define MOVE_EMBER 52 +#define MOVE_FLAMETHROWER 53 +#define MOVE_MIST 54 +#define MOVE_WATER_GUN 55 +#define MOVE_HYDRO_PUMP 56 +#define MOVE_SURF 57 +#define MOVE_ICE_BEAM 58 +#define MOVE_BLIZZARD 59 +#define MOVE_PSYBEAM 60 +#define MOVE_BUBBLE_BEAM 61 +#define MOVE_AURORA_BEAM 62 +#define MOVE_HYPER_BEAM 63 +#define MOVE_PECK 64 +#define MOVE_DRILL_PECK 65 +#define MOVE_SUBMISSION 66 +#define MOVE_LOW_KICK 67 +#define MOVE_COUNTER 68 +#define MOVE_SEISMIC_TOSS 69 +#define MOVE_STRENGTH 70 +#define MOVE_ABSORB 71 +#define MOVE_MEGA_DRAIN 72 +#define MOVE_LEECH_SEED 73 +#define MOVE_GROWTH 74 +#define MOVE_RAZOR_LEAF 75 +#define MOVE_SOLAR_BEAM 76 +#define MOVE_POISON_POWDER 77 +#define MOVE_STUN_SPORE 78 +#define MOVE_SLEEP_POWDER 79 +#define MOVE_PETAL_DANCE 80 +#define MOVE_STRING_SHOT 81 +#define MOVE_DRAGON_RAGE 82 +#define MOVE_FIRE_SPIN 83 +#define MOVE_THUNDER_SHOCK 84 +#define MOVE_THUNDERBOLT 85 +#define MOVE_THUNDER_WAVE 86 +#define MOVE_THUNDER 87 +#define MOVE_ROCK_THROW 88 +#define MOVE_EARTHQUAKE 89 +#define MOVE_FISSURE 90 +#define MOVE_DIG 91 +#define MOVE_TOXIC 92 +#define MOVE_CONFUSION 93 +#define MOVE_PSYCHIC 94 +#define MOVE_HYPNOSIS 95 +#define MOVE_MEDITATE 96 +#define MOVE_AGILITY 97 +#define MOVE_QUICK_ATTACK 98 +#define MOVE_RAGE 99 +#define MOVE_TELEPORT 100 +#define MOVE_NIGHT_SHADE 101 +#define MOVE_MIMIC 102 +#define MOVE_SCREECH 103 +#define MOVE_DOUBLE_TEAM 104 +#define MOVE_RECOVER 105 +#define MOVE_HARDEN 106 +#define MOVE_MINIMIZE 107 +#define MOVE_SMOKESCREEN 108 +#define MOVE_CONFUSE_RAY 109 +#define MOVE_WITHDRAW 110 +#define MOVE_DEFENSE_CURL 111 +#define MOVE_BARRIER 112 +#define MOVE_LIGHT_SCREEN 113 +#define MOVE_HAZE 114 +#define MOVE_REFLECT 115 +#define MOVE_FOCUS_ENERGY 116 +#define MOVE_BIDE 117 +#define MOVE_METRONOME 118 +#define MOVE_MIRROR_MOVE 119 +#define MOVE_SELF_DESTRUCT 120 +#define MOVE_EGG_BOMB 121 +#define MOVE_LICK 122 +#define MOVE_SMOG 123 +#define MOVE_SLUDGE 124 +#define MOVE_BONE_CLUB 125 +#define MOVE_FIRE_BLAST 126 +#define MOVE_WATERFALL 127 +#define MOVE_CLAMP 128 +#define MOVE_SWIFT 129 +#define MOVE_SKULL_BASH 130 +#define MOVE_SPIKE_CANNON 131 +#define MOVE_CONSTRICT 132 +#define MOVE_AMNESIA 133 +#define MOVE_KINESIS 134 +#define MOVE_SOFT_BOILED 135 +#define MOVE_HIGH_JUMP_KICK 136 +#define MOVE_GLARE 137 +#define MOVE_DREAM_EATER 138 +#define MOVE_POISON_GAS 139 +#define MOVE_BARRAGE 140 +#define MOVE_LEECH_LIFE 141 +#define MOVE_LOVELY_KISS 142 +#define MOVE_SKY_ATTACK 143 +#define MOVE_TRANSFORM 144 +#define MOVE_BUBBLE 145 +#define MOVE_DIZZY_PUNCH 146 +#define MOVE_SPORE 147 +#define MOVE_FLASH 148 +#define MOVE_PSYWAVE 149 +#define MOVE_SPLASH 150 +#define MOVE_ACID_ARMOR 151 +#define MOVE_CRABHAMMER 152 +#define MOVE_EXPLOSION 153 +#define MOVE_FURY_SWIPES 154 +#define MOVE_BONEMERANG 155 +#define MOVE_REST 156 +#define MOVE_ROCK_SLIDE 157 +#define MOVE_HYPER_FANG 158 +#define MOVE_SHARPEN 159 +#define MOVE_CONVERSION 160 +#define MOVE_TRI_ATTACK 161 +#define MOVE_SUPER_FANG 162 +#define MOVE_SLASH 163 +#define MOVE_SUBSTITUTE 164 +#define MOVE_STRUGGLE 165 +#define MOVE_SKETCH 166 +#define MOVE_TRIPLE_KICK 167 +#define MOVE_THIEF 168 +#define MOVE_SPIDER_WEB 169 +#define MOVE_MIND_READER 170 +#define MOVE_NIGHTMARE 171 +#define MOVE_FLAME_WHEEL 172 +#define MOVE_SNORE 173 +#define MOVE_CURSE 174 +#define MOVE_FLAIL 175 +#define MOVE_CONVERSION_2 176 +#define MOVE_AEROBLAST 177 +#define MOVE_COTTON_SPORE 178 +#define MOVE_REVERSAL 179 +#define MOVE_SPITE 180 +#define MOVE_POWDER_SNOW 181 +#define MOVE_PROTECT 182 +#define MOVE_MACH_PUNCH 183 +#define MOVE_SCARY_FACE 184 +#define MOVE_FEINT_ATTACK 185 +#define MOVE_SWEET_KISS 186 +#define MOVE_BELLY_DRUM 187 +#define MOVE_SLUDGE_BOMB 188 +#define MOVE_MUD_SLAP 189 +#define MOVE_OCTAZOOKA 190 +#define MOVE_SPIKES 191 +#define MOVE_ZAP_CANNON 192 +#define MOVE_FORESIGHT 193 +#define MOVE_DESTINY_BOND 194 +#define MOVE_PERISH_SONG 195 +#define MOVE_ICY_WIND 196 +#define MOVE_DETECT 197 +#define MOVE_BONE_RUSH 198 +#define MOVE_LOCK_ON 199 +#define MOVE_OUTRAGE 200 +#define MOVE_SANDSTORM 201 +#define MOVE_GIGA_DRAIN 202 +#define MOVE_ENDURE 203 +#define MOVE_CHARM 204 +#define MOVE_ROLLOUT 205 +#define MOVE_FALSE_SWIPE 206 +#define MOVE_SWAGGER 207 +#define MOVE_MILK_DRINK 208 +#define MOVE_SPARK 209 +#define MOVE_FURY_CUTTER 210 +#define MOVE_STEEL_WING 211 +#define MOVE_MEAN_LOOK 212 +#define MOVE_ATTRACT 213 +#define MOVE_SLEEP_TALK 214 +#define MOVE_HEAL_BELL 215 +#define MOVE_RETURN 216 +#define MOVE_PRESENT 217 +#define MOVE_FRUSTRATION 218 +#define MOVE_SAFEGUARD 219 +#define MOVE_PAIN_SPLIT 220 +#define MOVE_SACRED_FIRE 221 +#define MOVE_MAGNITUDE 222 +#define MOVE_DYNAMIC_PUNCH 223 +#define MOVE_MEGAHORN 224 +#define MOVE_DRAGON_BREATH 225 +#define MOVE_BATON_PASS 226 +#define MOVE_ENCORE 227 +#define MOVE_PURSUIT 228 +#define MOVE_RAPID_SPIN 229 +#define MOVE_SWEET_SCENT 230 +#define MOVE_IRON_TAIL 231 +#define MOVE_METAL_CLAW 232 +#define MOVE_VITAL_THROW 233 +#define MOVE_MORNING_SUN 234 +#define MOVE_SYNTHESIS 235 +#define MOVE_MOONLIGHT 236 +#define MOVE_HIDDEN_POWER 237 +#define MOVE_CROSS_CHOP 238 +#define MOVE_TWISTER 239 +#define MOVE_RAIN_DANCE 240 +#define MOVE_SUNNY_DAY 241 +#define MOVE_CRUNCH 242 +#define MOVE_MIRROR_COAT 243 +#define MOVE_PSYCH_UP 244 +#define MOVE_EXTREME_SPEED 245 +#define MOVE_ANCIENT_POWER 246 +#define MOVE_SHADOW_BALL 247 +#define MOVE_FUTURE_SIGHT 248 +#define MOVE_ROCK_SMASH 249 +#define MOVE_WHIRLPOOL 250 +#define MOVE_BEAT_UP 251 +#define MOVE_FAKE_OUT 252 +#define MOVE_UPROAR 253 +#define MOVE_STOCKPILE 254 +#define MOVE_SPIT_UP 255 +#define MOVE_SWALLOW 256 +#define MOVE_HEAT_WAVE 257 +#define MOVE_HAIL 258 +#define MOVE_TORMENT 259 +#define MOVE_FLATTER 260 +#define MOVE_WILL_O_WISP 261 +#define MOVE_MEMENTO 262 +#define MOVE_FACADE 263 +#define MOVE_FOCUS_PUNCH 264 +#define MOVE_SMELLING_SALTS 265 +#define MOVE_FOLLOW_ME 266 +#define MOVE_NATURE_POWER 267 +#define MOVE_CHARGE 268 +#define MOVE_TAUNT 269 +#define MOVE_HELPING_HAND 270 +#define MOVE_TRICK 271 +#define MOVE_ROLE_PLAY 272 +#define MOVE_WISH 273 +#define MOVE_ASSIST 274 +#define MOVE_INGRAIN 275 +#define MOVE_SUPERPOWER 276 +#define MOVE_MAGIC_COAT 277 +#define MOVE_RECYCLE 278 +#define MOVE_REVENGE 279 +#define MOVE_BRICK_BREAK 280 +#define MOVE_YAWN 281 +#define MOVE_KNOCK_OFF 282 +#define MOVE_ENDEAVOR 283 +#define MOVE_ERUPTION 284 +#define MOVE_SKILL_SWAP 285 +#define MOVE_IMPRISON 286 +#define MOVE_REFRESH 287 +#define MOVE_GRUDGE 288 +#define MOVE_SNATCH 289 +#define MOVE_SECRET_POWER 290 +#define MOVE_DIVE 291 +#define MOVE_ARM_THRUST 292 +#define MOVE_CAMOUFLAGE 293 +#define MOVE_TAIL_GLOW 294 +#define MOVE_LUSTER_PURGE 295 +#define MOVE_MIST_BALL 296 +#define MOVE_FEATHER_DANCE 297 +#define MOVE_TEETER_DANCE 298 +#define MOVE_BLAZE_KICK 299 +#define MOVE_MUD_SPORT 300 +#define MOVE_ICE_BALL 301 +#define MOVE_NEEDLE_ARM 302 +#define MOVE_SLACK_OFF 303 +#define MOVE_HYPER_VOICE 304 +#define MOVE_POISON_FANG 305 +#define MOVE_CRUSH_CLAW 306 +#define MOVE_BLAST_BURN 307 +#define MOVE_HYDRO_CANNON 308 +#define MOVE_METEOR_MASH 309 +#define MOVE_ASTONISH 310 +#define MOVE_WEATHER_BALL 311 +#define MOVE_AROMATHERAPY 312 +#define MOVE_FAKE_TEARS 313 +#define MOVE_AIR_CUTTER 314 +#define MOVE_OVERHEAT 315 +#define MOVE_ODOR_SLEUTH 316 +#define MOVE_ROCK_TOMB 317 +#define MOVE_SILVER_WIND 318 +#define MOVE_METAL_SOUND 319 +#define MOVE_GRASS_WHISTLE 320 +#define MOVE_TICKLE 321 +#define MOVE_COSMIC_POWER 322 +#define MOVE_WATER_SPOUT 323 +#define MOVE_SIGNAL_BEAM 324 +#define MOVE_SHADOW_PUNCH 325 +#define MOVE_EXTRASENSORY 326 +#define MOVE_SKY_UPPERCUT 327 +#define MOVE_SAND_TOMB 328 +#define MOVE_SHEER_COLD 329 +#define MOVE_MUDDY_WATER 330 +#define MOVE_BULLET_SEED 331 +#define MOVE_AERIAL_ACE 332 +#define MOVE_ICICLE_SPEAR 333 +#define MOVE_IRON_DEFENSE 334 +#define MOVE_BLOCK 335 +#define MOVE_HOWL 336 +#define MOVE_DRAGON_CLAW 337 +#define MOVE_FRENZY_PLANT 338 +#define MOVE_BULK_UP 339 +#define MOVE_BOUNCE 340 +#define MOVE_MUD_SHOT 341 +#define MOVE_POISON_TAIL 342 +#define MOVE_COVET 343 +#define MOVE_VOLT_TACKLE 344 +#define MOVE_MAGICAL_LEAF 345 +#define MOVE_WATER_SPORT 346 +#define MOVE_CALM_MIND 347 +#define MOVE_LEAF_BLADE 348 +#define MOVE_DRAGON_DANCE 349 +#define MOVE_ROCK_BLAST 350 +#define MOVE_SHOCK_WAVE 351 +#define MOVE_WATER_PULSE 352 +#define MOVE_DOOM_DESIRE 353 +#define MOVE_PSYCHO_BOOST 354 +#define MOVE_ROOST 355 +#define MOVE_GRAVITY 356 +#define MOVE_MIRACLE_EYE 357 +#define MOVE_WAKE_UP_SLAP 358 +#define MOVE_HAMMER_ARM 359 +#define MOVE_GYRO_BALL 360 +#define MOVE_HEALING_WISH 361 +#define MOVE_BRINE 362 +#define MOVE_NATURAL_GIFT 363 +#define MOVE_FEINT 364 +#define MOVE_PLUCK 365 +#define MOVE_TAILWIND 366 +#define MOVE_ACUPRESSURE 367 +#define MOVE_METAL_BURST 368 +#define MOVE_U_TURN 369 +#define MOVE_CLOSE_COMBAT 370 +#define MOVE_PAYBACK 371 +#define MOVE_ASSURANCE 372 +#define MOVE_EMBARGO 373 +#define MOVE_FLING 374 +#define MOVE_PSYCHO_SHIFT 375 +#define MOVE_TRUMP_CARD 376 +#define MOVE_HEAL_BLOCK 377 +#define MOVE_WRING_OUT 378 +#define MOVE_POWER_TRICK 379 +#define MOVE_GASTRO_ACID 380 +#define MOVE_LUCKY_CHANT 381 +#define MOVE_ME_FIRST 382 +#define MOVE_COPYCAT 383 +#define MOVE_POWER_SWAP 384 +#define MOVE_GUARD_SWAP 385 +#define MOVE_PUNISHMENT 386 +#define MOVE_LAST_RESORT 387 +#define MOVE_WORRY_SEED 388 +#define MOVE_SUCKER_PUNCH 389 +#define MOVE_TOXIC_SPIKES 390 +#define MOVE_HEART_SWAP 391 +#define MOVE_AQUA_RING 392 +#define MOVE_MAGNET_RISE 393 +#define MOVE_FLARE_BLITZ 394 +#define MOVE_FORCE_PALM 395 +#define MOVE_AURA_SPHERE 396 +#define MOVE_ROCK_POLISH 397 +#define MOVE_POISON_JAB 398 +#define MOVE_DARK_PULSE 399 +#define MOVE_NIGHT_SLASH 400 +#define MOVE_AQUA_TAIL 401 +#define MOVE_SEED_BOMB 402 +#define MOVE_AIR_SLASH 403 +#define MOVE_X_SCISSOR 404 +#define MOVE_BUG_BUZZ 405 +#define MOVE_DRAGON_PULSE 406 +#define MOVE_DRAGON_RUSH 407 +#define MOVE_POWER_GEM 408 +#define MOVE_DRAIN_PUNCH 409 +#define MOVE_VACUUM_WAVE 410 +#define MOVE_FOCUS_BLAST 411 +#define MOVE_ENERGY_BALL 412 +#define MOVE_BRAVE_BIRD 413 +#define MOVE_EARTH_POWER 414 +#define MOVE_SWITCHEROO 415 +#define MOVE_GIGA_IMPACT 416 +#define MOVE_NASTY_PLOT 417 +#define MOVE_BULLET_PUNCH 418 +#define MOVE_AVALANCHE 419 +#define MOVE_ICE_SHARD 420 +#define MOVE_SHADOW_CLAW 421 +#define MOVE_THUNDER_FANG 422 +#define MOVE_ICE_FANG 423 +#define MOVE_FIRE_FANG 424 +#define MOVE_SHADOW_SNEAK 425 +#define MOVE_MUD_BOMB 426 +#define MOVE_PSYCHO_CUT 427 +#define MOVE_ZEN_HEADBUTT 428 +#define MOVE_MIRROR_SHOT 429 +#define MOVE_FLASH_CANNON 430 +#define MOVE_ROCK_CLIMB 431 +#define MOVE_DEFOG 432 +#define MOVE_TRICK_ROOM 433 +#define MOVE_DRACO_METEOR 434 +#define MOVE_DISCHARGE 435 +#define MOVE_LAVA_PLUME 436 +#define MOVE_LEAF_STORM 437 +#define MOVE_POWER_WHIP 438 +#define MOVE_ROCK_WRECKER 439 +#define MOVE_CROSS_POISON 440 +#define MOVE_GUNK_SHOT 441 +#define MOVE_IRON_HEAD 442 +#define MOVE_MAGNET_BOMB 443 +#define MOVE_STONE_EDGE 444 +#define MOVE_CAPTIVATE 445 +#define MOVE_STEALTH_ROCK 446 +#define MOVE_GRASS_KNOT 447 +#define MOVE_CHATTER 448 +#define MOVE_JUDGMENT 449 +#define MOVE_BUG_BITE 450 +#define MOVE_CHARGE_BEAM 451 +#define MOVE_WOOD_HAMMER 452 +#define MOVE_AQUA_JET 453 +#define MOVE_ATTACK_ORDER 454 +#define MOVE_DEFEND_ORDER 455 +#define MOVE_HEAL_ORDER 456 +#define MOVE_HEAD_SMASH 457 +#define MOVE_DOUBLE_HIT 458 +#define MOVE_ROAR_OF_TIME 459 +#define MOVE_SPACIAL_REND 460 +#define MOVE_LUNAR_DANCE 461 +#define MOVE_CRUSH_GRIP 462 +#define MOVE_MAGMA_STORM 463 +#define MOVE_DARK_VOID 464 +#define MOVE_SEED_FLARE 465 +#define MOVE_OMINOUS_WIND 466 +#define MOVE_SHADOW_FORCE 467 + +#endif //POKEDIAMOND_CONSTANTS_MOVES_H diff --git a/include/constants/sinnoh_dex.h b/include/constants/sinnoh_dex.h new file mode 100644 index 00000000..555ced8b --- /dev/null +++ b/include/constants/sinnoh_dex.h @@ -0,0 +1,158 @@ +#ifndef POKEDIAMOND_CONSTANTS_SINNOH_DEX_H +#define POKEDIAMOND_CONSTANTS_SINNOH_DEX_H + +#define SINNOH_DEX_ARCEUS 0 +#define SINNOH_DEX_TURTWIG 1 +#define SINNOH_DEX_GROTLE 2 +#define SINNOH_DEX_TORTERRA 3 +#define SINNOH_DEX_CHIMCHAR 4 +#define SINNOH_DEX_MONFERNO 5 +#define SINNOH_DEX_INFERNAPE 6 +#define SINNOH_DEX_PIPLUP 7 +#define SINNOH_DEX_PRINPLUP 8 +#define SINNOH_DEX_EMPOLEON 9 +#define SINNOH_DEX_STARLY 10 +#define SINNOH_DEX_STARAVIA 11 +#define SINNOH_DEX_STARAPTOR 12 +#define SINNOH_DEX_BIDOOF 13 +#define SINNOH_DEX_BIBAREL 14 +#define SINNOH_DEX_KRICKETOT 15 +#define SINNOH_DEX_KRICKETUNE 16 +#define SINNOH_DEX_SHINX 17 +#define SINNOH_DEX_LUXIO 18 +#define SINNOH_DEX_LUXRAY 19 +#define SINNOH_DEX_ABRA 20 +#define SINNOH_DEX_KADABRA 21 +#define SINNOH_DEX_ALAKAZAM 22 +#define SINNOH_DEX_MAGIKARP 23 +#define SINNOH_DEX_GYARADOS 24 +#define SINNOH_DEX_BUDEW 25 +#define SINNOH_DEX_ROSELIA 26 +#define SINNOH_DEX_ROSERADE 27 +#define SINNOH_DEX_ZUBAT 28 +#define SINNOH_DEX_GOLBAT 29 +#define SINNOH_DEX_CROBAT 30 +#define SINNOH_DEX_GEODUDE 31 +#define SINNOH_DEX_GRAVELER 32 +#define SINNOH_DEX_GOLEM 33 +#define SINNOH_DEX_ONIX 34 +#define SINNOH_DEX_STEELIX 35 +#define SINNOH_DEX_CRANIDOS 36 +#define SINNOH_DEX_RAMPARDOS 37 +#define SINNOH_DEX_SHIELDON 38 +#define SINNOH_DEX_BASTIODON 39 +#define SINNOH_DEX_MACHOP 40 +#define SINNOH_DEX_MACHOKE 41 +#define SINNOH_DEX_MACHAMP 42 +#define SINNOH_DEX_PSYDUCK 43 +#define SINNOH_DEX_GOLDUCK 44 +#define SINNOH_DEX_BURMY 45 +#define SINNOH_DEX_WORMADAM 46 +#define SINNOH_DEX_MOTHIM 47 +#define SINNOH_DEX_WURMPLE 48 +#define SINNOH_DEX_SILCOON 49 +#define SINNOH_DEX_BEAUTIFLY 50 +#define SINNOH_DEX_CASCOON 51 +#define SINNOH_DEX_DUSTOX 52 +#define SINNOH_DEX_COMBEE 53 +#define SINNOH_DEX_VESPIQUEN 54 +#define SINNOH_DEX_PACHIRISU 55 +#define SINNOH_DEX_BUIZEL 56 +#define SINNOH_DEX_FLOATZEL 57 +#define SINNOH_DEX_CHERUBI 58 +#define SINNOH_DEX_CHERRIM 59 +#define SINNOH_DEX_SHELLOS 60 +#define SINNOH_DEX_GASTRODON 61 +#define SINNOH_DEX_HERACROSS 62 +#define SINNOH_DEX_AIPOM 63 +#define SINNOH_DEX_AMBIPOM 64 +#define SINNOH_DEX_DRIFLOON 65 +#define SINNOH_DEX_DRIFBLIM 66 +#define SINNOH_DEX_BUNEARY 67 +#define SINNOH_DEX_LOPUNNY 68 +#define SINNOH_DEX_GASTLY 69 +#define SINNOH_DEX_HAUNTER 70 +#define SINNOH_DEX_GENGAR 71 +#define SINNOH_DEX_MISDREAVUS 72 +#define SINNOH_DEX_MISMAGIUS 73 +#define SINNOH_DEX_MURKROW 74 +#define SINNOH_DEX_HONCHKROW 75 +#define SINNOH_DEX_GLAMEOW 76 +#define SINNOH_DEX_PURUGLY 77 +#define SINNOH_DEX_GOLDEEN 78 +#define SINNOH_DEX_SEAKING 79 +#define SINNOH_DEX_BARBOACH 80 +#define SINNOH_DEX_WHISCASH 81 +#define SINNOH_DEX_CHINGLING 82 +#define SINNOH_DEX_CHIMECHO 83 +#define SINNOH_DEX_STUNKY 84 +#define SINNOH_DEX_SKUNTANK 85 +#define SINNOH_DEX_MEDITITE 86 +#define SINNOH_DEX_MEDICHAM 87 +#define SINNOH_DEX_BRONZOR 88 +#define SINNOH_DEX_BRONZONG 89 +#define SINNOH_DEX_PONYTA 90 +#define SINNOH_DEX_RAPIDASH 91 +#define SINNOH_DEX_BONSLY 92 +#define SINNOH_DEX_SUDOWOODO 93 +#define SINNOH_DEX_MIME_JR 94 +#define SINNOH_DEX_MR_MIME 95 +#define SINNOH_DEX_HAPPINY 96 +#define SINNOH_DEX_CHANSEY 97 +#define SINNOH_DEX_BLISSEY 98 +#define SINNOH_DEX_CLEFFA 99 +#define SINNOH_DEX_CLEFAIRY 100 +#define SINNOH_DEX_CLEFABLE 101 +#define SINNOH_DEX_CHATOT 102 +#define SINNOH_DEX_PICHU 103 +#define SINNOH_DEX_PIKACHU 104 +#define SINNOH_DEX_RAICHU 105 +#define SINNOH_DEX_HOOTHOOT 106 +#define SINNOH_DEX_NOCTOWL 107 +#define SINNOH_DEX_SPIRITOMB 108 +#define SINNOH_DEX_GIBLE 109 +#define SINNOH_DEX_GABITE 110 +#define SINNOH_DEX_GARCHOMP 111 +#define SINNOH_DEX_MUNCHLAX 112 +#define SINNOH_DEX_SNORLAX 113 +#define SINNOH_DEX_UNOWN 114 +#define SINNOH_DEX_RIOLU 115 +#define SINNOH_DEX_LUCARIO 116 +#define SINNOH_DEX_WOOPER 117 +#define SINNOH_DEX_QUAGSIRE 118 +#define SINNOH_DEX_WINGULL 119 +#define SINNOH_DEX_PELIPPER 120 +#define SINNOH_DEX_GIRAFARIG 121 +#define SINNOH_DEX_HIPPOPOTAS 122 +#define SINNOH_DEX_HIPPOWDON 123 +#define SINNOH_DEX_AZURILL 124 +#define SINNOH_DEX_MARILL 125 +#define SINNOH_DEX_AZUMARILL 126 +#define SINNOH_DEX_SKORUPI 127 +#define SINNOH_DEX_DRAPION 128 +#define SINNOH_DEX_CROAGUNK 129 +#define SINNOH_DEX_TOXICROAK 130 +#define SINNOH_DEX_CARNIVINE 131 +#define SINNOH_DEX_REMORAID 132 +#define SINNOH_DEX_OCTILLERY 133 +#define SINNOH_DEX_FINNEON 134 +#define SINNOH_DEX_LUMINEON 135 +#define SINNOH_DEX_TENTACOOL 136 +#define SINNOH_DEX_TENTACRUEL 137 +#define SINNOH_DEX_FEEBAS 138 +#define SINNOH_DEX_MILOTIC 139 +#define SINNOH_DEX_MANTYKE 140 +#define SINNOH_DEX_MANTINE 141 +#define SINNOH_DEX_SNOVER 142 +#define SINNOH_DEX_ABOMASNOW 143 +#define SINNOH_DEX_SNEASEL 144 +#define SINNOH_DEX_WEAVILE 145 +#define SINNOH_DEX_UXIE 146 +#define SINNOH_DEX_MESPRIT 147 +#define SINNOH_DEX_AZELF 148 +#define SINNOH_DEX_DIALGA 149 +#define SINNOH_DEX_PALKIA 150 +#define SINNOH_DEX_MANAPHY 151 +#define SINNOH_DEX_COUNT SINNOH_DEX_MANAPHY + +#endif //POKEDIAMOND_CONSTANTS_SINNOH_DEX_H diff --git a/include/filesystem.h b/include/filesystem.h index 37f73bb0..6b5a16d6 100644 --- a/include/filesystem.h +++ b/include/filesystem.h @@ -2,6 +2,7 @@ #define POKEDIAMOND_FILESYSTEM_H #include "nitro/types.h" +#include "FS_file.h" typedef struct NARC { diff --git a/include/global.h b/include/global.h index 2f31fa3d..35d0c3aa 100644 --- a/include/global.h +++ b/include/global.h @@ -27,4 +27,9 @@ enum GameLanguage { extern void ErrorHandling(void); +#define GF_ASSERT(expr) do {if (!(expr)) ErrorHandling();} while (0) + +extern const enum GameLanguage gGameLanguage; +extern const enum GameVersion gGameVersion; + #endif //GUARD_GLOBAL_H diff --git a/include/math_util.h b/include/math_util.h new file mode 100644 index 00000000..f7169956 --- /dev/null +++ b/include/math_util.h @@ -0,0 +1,6 @@ +#ifndef POKEDIAMOND_MATH_UTIL_H +#define POKEDIAMOND_MATH_UTIL_H + +u16 rand_LC(void); + +#endif //POKEDIAMOND_MATH_UTIL_H diff --git a/include/move_data.h b/include/move_data.h new file mode 100644 index 00000000..8da864b0 --- /dev/null +++ b/include/move_data.h @@ -0,0 +1,7 @@ +#ifndef POKEDIAMOND_MOVE_DATA_H +#define POKEDIAMOND_MOVE_DATA_H + +int FUN_0206AB30(u16 move, u8 ppUp); +u32 FUN_0206AB18(u16 move, u32 attr); + +#endif //POKEDIAMOND_MOVE_DATA_H diff --git a/include/party.h b/include/party.h new file mode 100644 index 00000000..b6065a3f --- /dev/null +++ b/include/party.h @@ -0,0 +1,19 @@ +#ifndef POKEDIAMOND_PARTY_H +#define POKEDIAMOND_PARTY_H + +#include "pokemon.h" + +#define PARTY_SIZE 6 + +struct PlayerParty +{ + u32 maxCount; + u32 curCount; + struct Pokemon mons[PARTY_SIZE]; +}; + +BOOL PartyHasMon(struct PlayerParty * party_p, u16 species); +int GetPartyCount(struct PlayerParty * party_p); +struct Pokemon * GetPartyMonByIndex(struct PlayerParty * party_p, int idx); + +#endif //POKEDIAMOND_PARTY_H diff --git a/include/pokemon.h b/include/pokemon.h index 68cc0d59..166a1c7e 100644 --- a/include/pokemon.h +++ b/include/pokemon.h @@ -6,11 +6,12 @@ // Enums #include "constants/species.h" +#include "seals.h" #define MON_DATA_PERSONALITY 0 -#define MON_DATA_IS_ENCRYPTED 1 -#define MON_DATA_CONTROL_4_1 2 -#define MON_DATA_CONTROL_4_2 3 +#define MON_DATA_PARTY_LOCK 1 +#define MON_DATA_BOX_LOCK 2 +#define MON_DATA_CHECKSUM_FAILED 3 #define MON_DATA_CHECKSUM 4 #define MON_DATA_SPECIES 5 #define MON_DATA_HELD_ITEM 6 @@ -33,7 +34,34 @@ #define MON_DATA_TOUGH 23 #define MON_DATA_SHEEN 24 #define MON_DATA_SINNOH_CHAMP_RIBBON 25 -// TODO: ribbon flags through 53 +#define MON_DATA_SINNOH_RIBBON_26 26 +#define MON_DATA_SINNOH_RIBBON_27 27 +#define MON_DATA_SINNOH_RIBBON_28 28 +#define MON_DATA_SINNOH_RIBBON_29 29 +#define MON_DATA_SINNOH_RIBBON_30 30 +#define MON_DATA_SINNOH_RIBBON_31 31 +#define MON_DATA_SINNOH_RIBBON_32 32 +#define MON_DATA_SINNOH_RIBBON_33 33 +#define MON_DATA_SINNOH_RIBBON_34 34 +#define MON_DATA_SINNOH_RIBBON_35 35 +#define MON_DATA_SINNOH_RIBBON_36 36 +#define MON_DATA_SINNOH_RIBBON_37 37 +#define MON_DATA_SINNOH_RIBBON_38 38 +#define MON_DATA_SINNOH_RIBBON_39 39 +#define MON_DATA_SINNOH_RIBBON_40 40 +#define MON_DATA_SINNOH_RIBBON_41 41 +#define MON_DATA_SINNOH_RIBBON_42 42 +#define MON_DATA_SINNOH_RIBBON_43 43 +#define MON_DATA_SINNOH_RIBBON_44 44 +#define MON_DATA_SINNOH_RIBBON_45 45 +#define MON_DATA_SINNOH_RIBBON_46 46 +#define MON_DATA_SINNOH_RIBBON_47 47 +#define MON_DATA_SINNOH_RIBBON_48 48 +#define MON_DATA_SINNOH_RIBBON_49 49 +#define MON_DATA_SINNOH_RIBBON_50 50 +#define MON_DATA_SINNOH_RIBBON_51 51 +#define MON_DATA_SINNOH_RIBBON_52 52 +#define MON_DATA_SINNOH_RIBBON_53 53 #define MON_DATA_MOVE1 54 #define MON_DATA_MOVE2 55 #define MON_DATA_MOVE3 56 @@ -59,7 +87,37 @@ #define MON_DATA_IS_EGG 76 #define MON_DATA_HAS_NICKNAME 77 #define MON_DATA_COOL_RIBBON 78 -// TODO: ribbon flags through 109 +#define MON_DATA_HOENN_RIBBON_79 79 +#define MON_DATA_HOENN_RIBBON_80 80 +#define MON_DATA_HOENN_RIBBON_81 81 +#define MON_DATA_HOENN_RIBBON_82 82 +#define MON_DATA_HOENN_RIBBON_83 83 +#define MON_DATA_HOENN_RIBBON_84 84 +#define MON_DATA_HOENN_RIBBON_85 85 +#define MON_DATA_HOENN_RIBBON_86 86 +#define MON_DATA_HOENN_RIBBON_87 87 +#define MON_DATA_HOENN_RIBBON_88 88 +#define MON_DATA_HOENN_RIBBON_89 89 +#define MON_DATA_HOENN_RIBBON_90 90 +#define MON_DATA_HOENN_RIBBON_91 91 +#define MON_DATA_HOENN_RIBBON_92 92 +#define MON_DATA_HOENN_RIBBON_93 93 +#define MON_DATA_HOENN_RIBBON_94 94 +#define MON_DATA_HOENN_RIBBON_95 95 +#define MON_DATA_HOENN_RIBBON_96 96 +#define MON_DATA_HOENN_RIBBON_97 97 +#define MON_DATA_HOENN_RIBBON_98 98 +#define MON_DATA_HOENN_RIBBON_99 99 +#define MON_DATA_HOENN_RIBBON_100 100 +#define MON_DATA_HOENN_RIBBON_101 101 +#define MON_DATA_HOENN_RIBBON_102 102 +#define MON_DATA_HOENN_RIBBON_103 103 +#define MON_DATA_HOENN_RIBBON_104 104 +#define MON_DATA_HOENN_RIBBON_105 105 +#define MON_DATA_HOENN_RIBBON_106 106 +#define MON_DATA_HOENN_RIBBON_107 107 +#define MON_DATA_HOENN_RIBBON_108 108 +#define MON_DATA_HOENN_RIBBON_109 109 #define MON_DATA_FATEFUL_ENCOUNTER 110 #define MON_DATA_GENDER 111 #define MON_DATA_FORME 112 @@ -67,12 +125,32 @@ #define MON_DATA_RESERVED_114 114 // Plat #define MON_DATA_UNUSED_115 115 #define MON_DATA_NICKNAME 116 -#define MON_DATA_UNUSED_117 117 -#define MON_DATA_NICKNAME_2 118 // ??? -#define MON_DATA_NICKNAME_3 119 // ??? +#define MON_DATA_NICKNAME_2 117 +#define MON_DATA_NICKNAME_3 118 // ??? +#define MON_DATA_NICKNAME_4 119 // ??? #define MON_DATA_UNK_120 120 #define MON_DATA_GAME_VERSION 121 -// TODO: ribbon flags 122-142 +#define MON_DATA_SINNOH_RIBBON_122 122 +#define MON_DATA_SINNOH_RIBBON_123 123 +#define MON_DATA_SINNOH_RIBBON_124 124 +#define MON_DATA_SINNOH_RIBBON_125 125 +#define MON_DATA_SINNOH_RIBBON_126 126 +#define MON_DATA_SINNOH_RIBBON_127 127 +#define MON_DATA_SINNOH_RIBBON_128 128 +#define MON_DATA_SINNOH_RIBBON_129 129 +#define MON_DATA_SINNOH_RIBBON_130 130 +#define MON_DATA_SINNOH_RIBBON_131 131 +#define MON_DATA_SINNOH_RIBBON_132 132 +#define MON_DATA_SINNOH_RIBBON_133 133 +#define MON_DATA_SINNOH_RIBBON_134 134 +#define MON_DATA_SINNOH_RIBBON_135 135 +#define MON_DATA_SINNOH_RIBBON_136 136 +#define MON_DATA_SINNOH_RIBBON_137 137 +#define MON_DATA_SINNOH_RIBBON_138 138 +#define MON_DATA_SINNOH_RIBBON_139 139 +#define MON_DATA_SINNOH_RIBBON_140 140 +#define MON_DATA_SINNOH_RIBBON_141 141 +#define MON_DATA_SINNOH_RIBBON_142 142 #define MON_DATA_OT_NAME 143 #define MON_DATA_OT_NAME_2 144 // ??? #define MON_DATA_EGG_MET_YEAR 145 @@ -99,17 +177,31 @@ #define MON_DATA_SPEED 166 #define MON_DATA_SPATK 167 #define MON_DATA_SPDEF 168 -#define MON_DATA_SEAL_TYPES_MAYBE 169 +#define MON_DATA_SEAL_STRUCT 169 #define MON_DATA_SEAL_COORDS 170 #define MON_DATA_SPECIES_EXISTS 171 -#define MON_DATA_SANITY_CHECK_172 172 -#define MON_DATA_SANITY_CHECK_173 173 +#define MON_DATA_SANITY_IS_EGG 172 +#define MON_DATA_SPECIES2 173 #define MON_DATA_IVS_WORD 174 -#define MON_DATA_IS_FEMALE 175 +#define MON_DATA_UNK_175 175 #define MON_DATA_TYPE_1 176 #define MON_DATA_TYPE_2 177 #define MON_DATA_SPECIES_NAME 178 +#define MON_RATIO_MALE 0 +#define MON_RATIO_FEMALE 254 +#define MON_RATIO_UNKNOWN 255 + +#define POKEMON_NAME_LENGTH 10 +#define OT_NAME_LENGTH 7 + +enum MonGender +{ + MON_MALE = 0, + MON_FEMALE = 1, + MON_GENDERLESS = 2 +}; + // TODO: Identify the rest of these enum BaseStat { BASE_HP = 0, @@ -128,11 +220,11 @@ enum BaseStat { BASE_SPEED_YIELD, BASE_SPATK_YIELD, BASE_SPDEF_YIELD, - BASE_ITEM_1 = 16, + BASE_ITEM_1, BASE_ITEM_2, BASE_GENDER_RATIO, BASE_EGG_CYCLES, - BASE_FIRENDSHIP, + BASE_FRIENDSHIP, BASE_GROWTH_RATE, BASE_EGG_GROUP_1, GASE_EGG_GROUP_2, @@ -141,42 +233,45 @@ enum BaseStat { BASE_GREAT_MARSH_RATE, BASE_COLOR, BASE_FLIP, + BASE_UNKNOWN_29, + BASE_UNKNOWN_30, + BASE_UNKNOWN_31, + BASE_UNKNOWN_32, }; struct BaseStats { - u8 hp; - u8 atk; - u8 def; - u8 speed; - u8 spatk; - u8 spdef; - u8 types[2]; - u8 catchRate; - u8 expYield; - u16 hp_yield:2; - u16 atk_yield:2; - u16 def_yield:2; - u16 speed_yield:2; - u16 spatk_yield:2; - u16 spdef_yield:2; - u16 unkB_4:2; - u16 padding_B_6:2; - u16 item1; - u16 item2; - u8 genderRatio; - u8 eggCycles; - u8 friendship; - u8 growthRate; - u8 eggGroups[2]; - u8 abilities[2]; - u8 greatMarshRate; - u8 color:7; - u8 flip:1; - u8 padding_1A[2]; - u32 unk1C; - u32 unk20; - u32 unk24; - u32 unk28; + /* 0x00 */ u8 hp; + /* 0x01 */ u8 atk; + /* 0x02 */ u8 def; + /* 0x03 */ u8 speed; + /* 0x04 */ u8 spatk; + /* 0x05 */ u8 spdef; + /* 0x06 */ u8 types[2]; + /* 0x08 */ u8 catchRate; + /* 0x09 */ u8 expYield; + /* 0x0A */ u16 hp_yield:2; + u16 atk_yield:2; + u16 def_yield:2; + u16 speed_yield:2; + /* 0x0B */ u16 spatk_yield:2; + u16 spdef_yield:2; + u16 padding_B_4:4; + /* 0x0C */ u16 item1; + /* 0x0E */ u16 item2; + /* 0x10 */ u8 genderRatio; + /* 0x11 */ u8 eggCycles; + /* 0x12 */ u8 friendship; + /* 0x13 */ u8 growthRate; + /* 0x14 */ u8 eggGroups[2]; + /* 0x16 */ u8 abilities[2]; + /* 0x18 */ u8 greatMarshRate; + /* 0x19 */ u8 color:7; + u8 flip:1; + u8 padding_1A[2]; + /* 0x1C */ u32 unk1C; + /* 0x20 */ u32 unk20; + /* 0x24 */ u32 unk24; + /* 0x28 */ u32 unk28; }; typedef enum { @@ -202,71 +297,102 @@ typedef enum GameLanguage OriginLanguage; typedef enum { ARCEUS_NORMAL = 0, - ARCEUS_FIST = 8, - ARCEUS_SKY = 16, - ARCEUS_TOXIC = 24, - ARCEUS_EARTH = 32, - ARCEUS_STONE = 40, - ARCEUS_INSECT = 48, - ARCEUS_SPOOKY = 56, - ARCEUS_IRON = 64, - ARCEUS_FLAME = 72, - ARCEUS_SPLASH = 80, - ARCEUS_MEADOW = 88, - ARCEUS_ZAP = 96, - ARCEUS_MIND = 104, - ARCEUS_ICICLE = 112, - ARCEUS_DRACO = 120, - ARCEUS_DREAD = 128, + ARCEUS_FIST = 1, + ARCEUS_SKY = 2, + ARCEUS_TOXIC = 3, + ARCEUS_EARTH = 4, + ARCEUS_STONE = 5, + ARCEUS_INSECT = 6, + ARCEUS_SPOOKY = 7, + ARCEUS_IRON = 8, + ARCEUS_FLAME = 9, + ARCEUS_SPLASH = 10, + ARCEUS_MEADOW = 11, + ARCEUS_ZAP = 12, + ARCEUS_MIND = 13, + ARCEUS_ICICLE = 14, + ARCEUS_DRACO = 15, + ARCEUS_DREAD = 16, BURMY_PLANT = 0, - BURMY_SANDY = 8, - BURMY_TRASH = 16, + BURMY_SANDY = 1, + BURMY_TRASH = 2, DEOXYS_NORMAL = 0, - DEOXYS_ATTACK = 8, - DEOXYS_DEFENSE = 16, - DEOXYS_SPEED = 24, + DEOXYS_ATTACK = 1, + DEOXYS_DEFENSE = 2, + DEOXYS_SPEED = 3, GIRATINA_ALTERED = 0, - GIRATINA_ORIGIN = 8, + GIRATINA_ORIGIN = 1, ROTOM_NORMAL = 0, - ROTOM_HEAT = 8, - ROTOM_WASH = 16, - ROTOM_FROST = 24, - ROTOM_FAN = 32, - ROTOM_MOW = 40, + ROTOM_HEAT = 1, + ROTOM_WASH = 2, + ROTOM_FROST = 3, + ROTOM_FAN = 4, + ROTOM_MOW = 5, SHAYMIN_LAND = 0, - SHAYMIN_SKY = 8, + SHAYMIN_SKY = 1, SHELLOS_WEST = 0, - SHELLOS_EAST = 8, + SHELLOS_EAST = 1, UNOWN_A = 0, - UNOWN_B = 8, - UNOWN_C = 16, - UNOWN_D = 24, - UNOWN_E = 32, - UNOWN_F = 40, - UNOWN_G = 48, - UNOWN_H = 56, - UNOWN_I = 64, - UNOWN_J = 72, - UNOWN_K = 80, - UNOWN_L = 88, - UNOWN_M = 96, - UNOWN_N = 104, - UNOWN_O = 112, - UNOWN_P = 120, - UNOWN_Q = 128, - UNOWN_R = 136, - UNOWN_S = 144, - UNOWN_T = 152, - UNOWN_U = 160, - UNOWN_V = 168, - UNOWN_W = 176, - UNOWN_X = 184, - UNOWN_Y = 192, - UNOWN_Z = 200, - UNOWN_EXCLAMATION_MARK = 208, - UNOWN_QUESTION_MARK = 216 + UNOWN_B = 1, + UNOWN_C = 2, + UNOWN_D = 3, + UNOWN_E = 4, + UNOWN_F = 5, + UNOWN_G = 6, + UNOWN_H = 7, + UNOWN_I = 8, + UNOWN_J = 9, + UNOWN_K = 10, + UNOWN_L = 11, + UNOWN_M = 12, + UNOWN_N = 13, + UNOWN_O = 14, + UNOWN_P = 15, + UNOWN_Q = 16, + UNOWN_R = 17, + UNOWN_S = 18, + UNOWN_T = 19, + UNOWN_U = 20, + UNOWN_V = 21, + UNOWN_W = 22, + UNOWN_X = 23, + UNOWN_Y = 24, + UNOWN_Z = 25, + UNOWN_EXCLAMATION_MARK = 26, + UNOWN_QUESTION_MARK = 27 } AlternateForms; +typedef enum EvoMethod +{ + EVO_NONE = 0, + EVO_FRIENDSHIP, + EVO_FRIENDSHIP_DAY, + EVO_FRIENDSHIP_NIGHT, + EVO_LEVEL, + EVO_TRADE, + EVO_TRADE_ITEM, + EVO_STONE, + EVO_LEVEL_ATK_GT_DEF, + EVO_LEVEL_ATK_EQ_DEF, + EVO_LEVEL_ATK_LT_DEF, + EVO_LEVEL_PID_LO, + EVO_LEVEL_PID_HI, + EVO_LEVEL_NINJASK, + EVO_LEVEL_SHEDINJA, + EVO_BEAUTY, + EVO_STONE_MALE, + EVO_STONE_FEMALE, + EVO_ITEM_DAY, + EVO_ITEM_NIGHT, + EVO_HAS_MOVE, + EVO_OTHER_PARTY_MON, + EVO_LEVEL_MALE, + EVO_LEVEL_FEMALE, + EVO_CORONET, + EVO_ETERNA, + EVO_ROUTE217, +} EvoMethod; + // Structs typedef struct { @@ -305,7 +431,7 @@ typedef struct { /* 0x10 */ u32 hpIV:5, atkIV:5, defIV:5, spdIV:5, spatkIV:5, spdefIV:5, isEgg:1, isNicknamed:1; // TODO: Finish HoennRibbonSet /* 0x14 */ u32 ribbonFlags; // cool, ... - /* 0x18 */ u8 fatefulEncounter:1, female:1, genderless:1, alternateForm:5; + /* 0x18 */ u8 fatefulEncounter:1, gender:2, alternateForm:5; /* 0x19 */ u8 HGSS_shinyLeaves; // TODO: Turn into bitfield /* 0x1A */ u16 Unused; /* 0x1C */ u16 Platinum_EggLocation; @@ -314,10 +440,10 @@ typedef struct { typedef struct { /* 0x00 */ u16 nickname[11]; - /* 0x1A */ u8 Unused; - /* 0x1B */ u8 originGame; + /* 0x16 */ u8 Unused; + /* 0x17 */ u8 originGame; // TODO: Finish SinnohRibbonSet2 - /* 0x1C */ u32 sinnohRibbons2; // cool, ... + /* 0x18 */ u64 sinnohRibbons2; // cool, ... } PokemonDataBlockC; typedef struct { @@ -328,7 +454,8 @@ typedef struct { /* 0x18 */ u16 DP_MetLocation; /* 0x1A */ u8 pokerus; /* 0x1B */ u8 pokeball; - /* 0x1C */ u8 flags; + /* 0x1C */ u8 metLevel:7; + u8 metGender:1; /* 0x1D */ u8 encounterType; /* 0x1E */ u16 HGSS_Pokeball; } PokemonDataBlockD; @@ -341,26 +468,18 @@ typedef union { } PokemonDataBlock; struct BoxPokemon { - /* 0x000 */ u32 personalityValue; - /* 0x004 */ u16 no_encrypt:1; - u16 control_4_1:1; - u16 control_4_2:1; + /* 0x000 */ u32 pid; + /* 0x004 */ u16 party_lock:1; + u16 box_lock:1; + u16 checksum_fail:1; u16 Unused:13; // Might be used for validity checks /* 0x006 */ u16 checksum; // Stored checksum of pokemon - /* 0x008 */ PokemonDataBlock box[4]; + /* 0x008 */ PokemonDataBlock substructs[4]; }; struct PartyPokemon { - /* 0x000 */ struct BoxPokemon box; - /* 0x088 */ u8 slp:3; - u8 psn:1; - u8 brn:1; - u8 frz:1; - u8 prz:1; - u8 tox:1; - /* 0x089 */ u8 unk89; - /* 0x08A */ u8 filler8A[2]; + /* 0x088 */ u32 status; // slp:3, psn:1, brn:1, frz:1, prz:1, tox:1, ... /* 0x08C */ u8 level; /* 0x08D */ u8 capsule; /* 0x08E */ u16 hp; @@ -370,7 +489,7 @@ struct PartyPokemon /* 0x096 */ u16 speed; /* 0x098 */ u16 spatk; /* 0x09A */ u16 spdef; - /* 0x09C */ u8 seal_something[0x38]; // a struct? + /* 0x09C */ struct SealStruct seal_something; // a struct? /* 0x0D4 */ u8 sealCoords[0x18]; // u8 pairs? }; @@ -379,11 +498,100 @@ struct Pokemon { /* 0x088 */ struct PartyPokemon party; }; // size: 0xEC -int GetMonBaseStat_HandleFormeConversion(int species, int form, int stat_id); -int GetMonBaseStat(int species, int stat_id); -int GetMonExpByLevel(int species, int level); -void LoadGrowthTable(int species, int * table); -int GetExpByGrowthRateAndLevel(int rate, int level); -int CalcLevelBySpeciesAndExp(int species, int experience); +struct SomeDrawPokemonStruct +{ + u16 unk0; + u16 unk2; + u16 unk4; + u16 unk6; + u8 unk8; + u8 filler_9[3]; + u32 unkC; +}; + +struct PokeanmSub +{ + s8 unk0; + u8 unk1; +}; + +struct Pokeanm +{ + struct PokeanmSub unk0[4]; + u8 unk8[20]; +}; + +struct UnkStruct_02069038 +{ + u16 unk0; + u16 unk2; + u8 unk4; + u8 padding; + struct Pokeanm anim; +}; + +struct Evolution +{ + u16 method; + u16 param; + u16 target; +}; + +void ZeroMonData(struct Pokemon * pokemon); +void ZeroBoxMonData(struct BoxPokemon * boxmon); +u32 SizeOfStructPokemon(void); +struct Pokemon * AllocMonZeroed(u32 heap_id); +BOOL AcquireMonLock(struct Pokemon * mon); +BOOL ReleaseMonLock(struct Pokemon * mon, BOOL decrypt_result); +BOOL AcquireBoxMonLock(struct BoxPokemon * mon); +BOOL ReleaseBoxMonLock(struct BoxPokemon * mon, BOOL decrypt_result); +void CreateMon(struct Pokemon * pokemon, int species, int level, int fixedIV, int hasFixedPersonality, int fixedPersonality, int otIdType, int fixedOtId); +void CreateBoxMon(struct BoxPokemon * boxPokemon, int species, int level, int fixedIV, int hasFixedPersonality, int fixedPersonality, int otIdType, int fixedOtId); +void CreateMonWithNature(struct Pokemon * pokemon, u16 species, u8 level, u8 fixedIv, u8 nature); +void CreateMonWithGenderNatureLetter(struct Pokemon * pokemon, u16 species, u8 level, u8 fixedIv, u8 gender, u8 nature, u8 letter); +u32 GenPersonalityByGenderAndNature(u16 species, u8 gender, u8 nature); +void CreateMonWithFixedIVs(struct Pokemon * pokemon, int species, int level, int ivs, int personality); +void CalcMonLevelAndStats(struct Pokemon * pokemon); +void CalcMonStats(struct Pokemon * pokemon); +#ifndef IN_POKEMON_C +u32 GetMonData(); +u32 GetBoxMonData(); +#else +u32 GetMonData(struct Pokemon * pokemon, int attr, void * ptr); +u32 GetBoxMonData(struct BoxPokemon * pokemon, int attr, void * ptr); +#endif +void SetMonData(struct Pokemon * pokemon, int attr, void * ptr); +void SetBoxMonData(struct BoxPokemon * pokemon, int attr, void * ptr); +void AddMonData(struct Pokemon * pokemon, int attr, int amount); +struct BaseStats * AllocAndLoadMonPersonal(int species, u32 heap_id); +int GetPersonalAttr(struct BaseStats * baseStats, enum BaseStat attr); +void FreeMonPersonal(struct BaseStats * personal); +int GetMonBaseStat_HandleFormeConversion(int species, int form, enum BaseStat stat_id); +int GetMonBaseStat(int species, enum BaseStat stat_id); +u8 GetPercentProgressTowardsNextLevel(struct Pokemon * pokemon); +u32 CalcMonExpToNextLevel(struct Pokemon * pokemon); +u32 GetMonBaseExperienceAtCurrentLevel(struct Pokemon * pokemon); +u32 GetMonExpBySpeciesAndLevel(int species, int level); +void LoadGrowthTable(int growthRate, u32 * table); +u32 GetExpByGrowthRateAndLevel(int rate, int level); +int CalcMonLevel(struct Pokemon * pokemon); +int CalcBoxMonLevel(struct BoxPokemon * boxmon); +int CalcLevelBySpeciesAndExp(u16 species, u32 experience); +int CalcLevelBySpeciesAndExp_PreloadedPersonal(struct BaseStats * personal, u16 species, u32 experience); +u8 GetBoxMonNature(struct BoxPokemon * boxmon); +u8 GetMonNature(struct Pokemon * mon); +u8 GetNatureFromPersonality(u32 pid); +void MonApplyFriendshipMod(struct Pokemon * pokemon, u32 kind, u32 location); +u8 GetMonGender(struct Pokemon * pokemon); +u8 GetBoxMonGender(struct BoxPokemon * boxmon); +u8 GetGenderBySpeciesAndPersonality(u16 species, u32 pid); +u8 MonIsShiny(struct Pokemon * pokemon); +u32 GenerateShinyPersonality(u32 otid); +void FUN_02068B70(struct SomeDrawPokemonStruct * spC, struct BoxPokemon * boxmon, u8 sp10); +void FUN_02068C00(struct SomeDrawPokemonStruct * spC, int species, u8 gender, u8 sp10, u8 shiny, u8 forme, u32 personality); +u8 FUN_02068E14(struct Pokemon * pokemon, u32 a1); +u8 FUN_02068E1C(struct BoxPokemon * boxmon, u32 a1); +u8 FUN_02068E88(int species, u8 gender, u32 a2, u8 forme, u32 pid); +int FUN_0206AA30(int a0); #endif //POKEDIAMOND_POKEMON_H diff --git a/include/proto.h b/include/proto.h new file mode 100644 index 00000000..d26b7750 --- /dev/null +++ b/include/proto.h @@ -0,0 +1,21 @@ +#ifndef POKEDIAMOND_PROTO_H +#define POKEDIAMOND_PROTO_H + +// For homeless function declarations + +// Declare these here so that we don't have to include pokemon.h +struct UnkStruct_02069038; +struct PlayerParty; + +u16 * FUN_0200AA50(u16 species, u32 heap_id); +void FUN_02021A74(u16 * dest, u16 * src); +void FUN_02021A20(void * ptr); +void FUN_02021E28(u16 * dest, u16 * src); +void FUN_02021EF0(const u16 * src, u16 * dest, u32 count); +u32 FUN_0206E7B8(u16 item, u32 a1, u32 a2); +u32 GetArceusTypeByPlate(u16 plate); +int FUN_02014C3C(u8); +void FUN_02014C54(int, int, struct UnkStruct_02069038 *, u8); +u32 IsNighttime(void); // is day or night + +#endif //POKEDIAMOND_PROTO_H diff --git a/include/seals.h b/include/seals.h new file mode 100644 index 00000000..8fda23b9 --- /dev/null +++ b/include/seals.h @@ -0,0 +1,15 @@ +#ifndef POKEDIAMOND_SEALS_H +#define POKEDIAMOND_SEALS_H + +struct SealStruct +{ + // TODO: define + u8 filler_00[0x38]; +}; + +struct SealStruct * CreateNewSealsObject(u32 heap_id); + +void CopySealsObject(const struct SealStruct *, struct SealStruct *); +void FUN_02029C74(const u8 *, u8 *); + +#endif //POKEDIAMOND_SEALS_H diff --git a/include/string_util.h b/include/string_util.h index 53d4e5f4..e9079229 100644 --- a/include/string_util.h +++ b/include/string_util.h @@ -7,6 +7,9 @@ #include "global.h" +#define EOS 0xFFFF +#define NON_DIGIT 0xE2 + enum PrintingMode { NORMAL, PAD_SPACE, diff --git a/include/text.h b/include/text.h new file mode 100644 index 00000000..cec36a30 --- /dev/null +++ b/include/text.h @@ -0,0 +1,6 @@ +#ifndef POKEDIAMOND_TEXT_H +#define POKEDIAMOND_TEXT_H + +void GetSpeciesName(u16 species, u32 heap_id, u16 * dest); + +#endif //POKEDIAMOND_TEXT_H |