From c8afeea1824f01e8435e5bf1115b366bec65ff82 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Mon, 5 Sep 2022 16:09:45 -0400 Subject: [PATCH 01/15] Generate trainer pic palettes from image --- .../{brendan_back_pic.png => brendan.png} | Bin ...re_brendan_back_pic.png => brendan_rs.png} | Bin .../back_pics/{leaf_back_pic.png => leaf.png} | Bin .../back_pics/{may_back_pic.png => may.png} | Bin ...y_sapphire_may_back_pic.png => may_rs.png} | Bin .../back_pics/{red_back_pic.png => red.png} | Bin .../{steven_back_pic.png => steven.png} | Bin .../{wally_back_pic.png => wally.png} | Bin ...admin_f_front_pic.png => aqua_admin_f.png} | Bin ...admin_m_front_pic.png => aqua_admin_m.png} | Bin ...grunt_f_front_pic.png => aqua_grunt_f.png} | Bin ...grunt_m_front_pic.png => aqua_grunt_m.png} | Bin ...e_front_pic.png => aqua_leader_archie.png} | Bin ...a_front_pic.png => arena_tycoon_greta.png} | Bin ...roma_lady_front_pic.png => aroma_lady.png} | Bin ...tle_girl_front_pic.png => battle_girl.png} | Bin .../{beauty_front_pic.png => beauty.png} | Bin ...d_keeper_front_pic.png => bird_keeper.png} | Bin ...lack_belt_front_pic.png => black_belt.png} | Bin .../{brendan_front_pic.png => brendan.png} | Bin ...e_brendan_front_pic.png => brendan_rs.png} | Bin ..._catcher_front_pic.png => bug_catcher.png} | Bin ...ug_maniac_front_pic.png => bug_maniac.png} | Bin .../{camper_front_pic.png => camper.png} | Bin ...ace_front_pic.png => champion_wallace.png} | Bin ...{collector_front_pic.png => collector.png} | Bin ...iner_f_front_pic.png => cooltrainer_f.png} | Bin ...iner_m_front_pic.png => cooltrainer_m.png} | Bin ...front_pic.png => cycling_triathlete_f.png} | Bin ...front_pic.png => cycling_triathlete_m.png} | Bin ...cker_front_pic.png => dome_ace_tucker.png} | Bin ...n_tamer_front_pic.png => dragon_tamer.png} | Bin ...ake_front_pic.png => elite_four_drake.png} | Bin ...ia_front_pic.png => elite_four_glacia.png} | Bin ...be_front_pic.png => elite_four_phoebe.png} | Bin ...ey_front_pic.png => elite_four_sidney.png} | Bin .../{expert_f_front_pic.png => expert_f.png} | Bin .../{expert_m_front_pic.png => expert_m.png} | Bin ..._front_pic.png => factory_head_noland.png} | Bin ...{fisherman_front_pic.png => fisherman.png} | Bin ...{gentleman_front_pic.png => gentleman.png} | Bin ...{guitarist_front_pic.png => guitarist.png} | Bin ...ex_maniac_front_pic.png => hex_maniac.png} | Bin .../{hiker_front_pic.png => hiker.png} | Bin ...erviewer_front_pic.png => interviewer.png} | Bin .../{kindler_front_pic.png => kindler.png} | Bin .../{lady_front_pic.png => lady.png} | Bin .../{lass_front_pic.png => lass.png} | Bin ...brawly_front_pic.png => leader_brawly.png} | Bin ...nery_front_pic.png => leader_flannery.png} | Bin ...der_juan_front_pic.png => leader_juan.png} | Bin ...norman_front_pic.png => leader_norman.png} | Bin ...xanne_front_pic.png => leader_roxanne.png} | Bin ...front_pic.png => leader_tate_and_liza.png} | Bin ...ttson_front_pic.png => leader_wattson.png} | Bin ...winona_front_pic.png => leader_winona.png} | Bin .../{leaf_front_pic.png => leaf.png} | Bin ...ma_admin_front_pic.png => magma_admin.png} | Bin ...runt_f_front_pic.png => magma_grunt_f.png} | Bin ...runt_m_front_pic.png => magma_grunt_m.png} | Bin ...e_front_pic.png => magma_leader_maxie.png} | Bin .../front_pics/{may_front_pic.png => may.png} | Bin ..._sapphire_may_front_pic.png => may_rs.png} | Bin ...{ninja_boy_front_pic.png => ninja_boy.png} | Bin ...ld_couple_front_pic.png => old_couple.png} | Bin ...front_pic.png => palace_maven_spenser.png} | Bin ...ol_lady_front_pic.png => parasol_lady.png} | Bin ...{picnicker_front_pic.png => picnicker.png} | Bin ...lucy_front_pic.png => pike_queen_lucy.png} | Bin ...{pokefan_f_front_pic.png => pokefan_f.png} | Bin ...{pokefan_m_front_pic.png => pokefan_m.png} | Bin ...okemaniac_front_pic.png => pokemaniac.png} | Bin ..._f_front_pic.png => pokemon_breeder_f.png} | Bin ..._m_front_pic.png => pokemon_breeder_m.png} | Bin ...r_f_front_pic.png => pokemon_ranger_f.png} | Bin ...r_m_front_pic.png => pokemon_ranger_m.png} | Bin ...{psychic_f_front_pic.png => psychic_f.png} | Bin ...{psychic_m_front_pic.png => psychic_m.png} | Bin ...front_pic.png => pyramid_king_brandon.png} | Bin .../front_pics/{red_front_pic.png => red.png} | Bin .../{rich_boy_front_pic.png => rich_boy.png} | Bin ...n_maniac_front_pic.png => ruin_maniac.png} | Bin ...front_pic.png => running_triathlete_f.png} | Bin ...front_pic.png => running_triathlete_m.png} | Bin .../{sailor_front_pic.png => sailor.png} | Bin ..._front_pic.png => salon_maiden_anabel.png} | Bin ...l_kid_f_front_pic.png => school_kid_f.png} | Bin ...l_kid_m_front_pic.png => school_kid_m.png} | Bin ..._and_bro_front_pic.png => sis_and_bro.png} | Bin ...{sr_and_jr_front_pic.png => sr_and_jr.png} | Bin .../{steven_front_pic.png => steven.png} | Bin ...{swimmer_f_front_pic.png => swimmer_f.png} | Bin ...{swimmer_m_front_pic.png => swimmer_m.png} | Bin ...ront_pic.png => swimming_triathlete_f.png} | Bin ...ront_pic.png => swimming_triathlete_m.png} | Bin .../{tuber_f_front_pic.png => tuber_f.png} | Bin .../{tuber_m_front_pic.png => tuber_m.png} | Bin .../{twins_front_pic.png => twins.png} | Bin .../{wally_front_pic.png => wally.png} | Bin ..._couple_front_pic.png => young_couple.png} | Bin ...{youngster_front_pic.png => youngster.png} | Bin graphics/trainers/palettes/aqua_admin_f.pal | 19 - graphics/trainers/palettes/aqua_admin_m.pal | 19 - graphics/trainers/palettes/aqua_grunt_f.pal | 19 - graphics/trainers/palettes/aqua_grunt_m.pal | 19 - .../trainers/palettes/aqua_leader_archie.pal | 19 - .../trainers/palettes/arena_tycoon_greta.pal | 19 - graphics/trainers/palettes/aroma_lady.pal | 19 - graphics/trainers/palettes/battle_girl.pal | 19 - graphics/trainers/palettes/beauty.pal | 19 - graphics/trainers/palettes/bird_keeper.pal | 19 - graphics/trainers/palettes/black_belt.pal | 19 - ...by_sapphire_brendan.pal => brendan_rs.pal} | 0 graphics/trainers/palettes/bug_catcher.pal | 19 - graphics/trainers/palettes/bug_maniac.pal | 19 - graphics/trainers/palettes/camper.pal | 19 - .../trainers/palettes/champion_wallace.pal | 19 - graphics/trainers/palettes/collector.pal | 19 - graphics/trainers/palettes/cooltrainer_f.pal | 19 - graphics/trainers/palettes/cooltrainer_m.pal | 19 - .../palettes/cycling_triathlete_f.pal | 19 - .../palettes/cycling_triathlete_m.pal | 19 - .../trainers/palettes/dome_ace_tucker.pal | 19 - graphics/trainers/palettes/dragon_tamer.pal | 19 - .../trainers/palettes/elite_four_drake.pal | 19 - .../trainers/palettes/elite_four_glacia.pal | 19 - .../trainers/palettes/elite_four_phoebe.pal | 19 - .../trainers/palettes/elite_four_sidney.pal | 19 - graphics/trainers/palettes/expert_f.pal | 19 - graphics/trainers/palettes/expert_m.pal | 19 - .../trainers/palettes/factory_head_noland.pal | 19 - graphics/trainers/palettes/fisherman.pal | 19 - graphics/trainers/palettes/gentleman.pal | 19 - graphics/trainers/palettes/guitarist.pal | 19 - graphics/trainers/palettes/hex_maniac.pal | 19 - graphics/trainers/palettes/hiker.pal | 19 - graphics/trainers/palettes/interviewer.pal | 19 - graphics/trainers/palettes/kindler.pal | 19 - graphics/trainers/palettes/lady.pal | 19 - graphics/trainers/palettes/lass.pal | 19 - graphics/trainers/palettes/leader_brawly.pal | 19 - .../trainers/palettes/leader_flannery.pal | 19 - graphics/trainers/palettes/leader_juan.pal | 19 - graphics/trainers/palettes/leader_norman.pal | 19 - graphics/trainers/palettes/leader_roxanne.pal | 19 - .../palettes/leader_tate_and_liza.pal | 19 - graphics/trainers/palettes/leader_wattson.pal | 19 - graphics/trainers/palettes/leader_winona.pal | 19 - graphics/trainers/palettes/leaf.pal | 19 - graphics/trainers/palettes/leaf_back_pic.pal | 19 - graphics/trainers/palettes/magma_admin.pal | 19 - graphics/trainers/palettes/magma_grunt_f.pal | 19 - graphics/trainers/palettes/magma_grunt_m.pal | 19 - .../trainers/palettes/magma_leader_maxie.pal | 19 - .../{ruby_sapphire_may.pal => may_rs.pal} | 0 graphics/trainers/palettes/ninja_boy.pal | 19 - graphics/trainers/palettes/old_couple.pal | 19 - .../palettes/palace_maven_spenser.pal | 19 - graphics/trainers/palettes/parasol_lady.pal | 19 - graphics/trainers/palettes/picnicker.pal | 19 - .../trainers/palettes/pike_queen_lucy.pal | 19 - graphics/trainers/palettes/pokefan_f.pal | 19 - graphics/trainers/palettes/pokefan_m.pal | 19 - graphics/trainers/palettes/pokemaniac.pal | 19 - .../trainers/palettes/pokemon_breeder_f.pal | 19 - .../trainers/palettes/pokemon_breeder_m.pal | 19 - .../trainers/palettes/pokemon_ranger_f.pal | 19 - .../trainers/palettes/pokemon_ranger_m.pal | 19 - graphics/trainers/palettes/psychic_f.pal | 19 - graphics/trainers/palettes/psychic_m.pal | 19 - .../palettes/pyramid_king_brandon.pal | 19 - graphics/trainers/palettes/red.pal | 19 - graphics/trainers/palettes/red_back_pic.pal | 19 - graphics/trainers/palettes/rich_boy.pal | 19 - graphics/trainers/palettes/ruin_maniac.pal | 19 - .../palettes/running_triathlete_f.pal | 19 - .../palettes/running_triathlete_m.pal | 19 - graphics/trainers/palettes/sailor.pal | 19 - .../trainers/palettes/salon_maiden_anabel.pal | 19 - graphics/trainers/palettes/school_kid_f.pal | 19 - graphics/trainers/palettes/school_kid_m.pal | 19 - graphics/trainers/palettes/sis_and_bro.pal | 19 - graphics/trainers/palettes/sr_and_jr.pal | 19 - graphics/trainers/palettes/swimmer_f.pal | 19 - graphics/trainers/palettes/swimmer_m.pal | 19 - .../palettes/swimming_triathlete_f.pal | 19 - .../palettes/swimming_triathlete_m.pal | 19 - graphics/trainers/palettes/tuber_f.pal | 19 - graphics/trainers/palettes/tuber_m.pal | 19 - graphics/trainers/palettes/twins.pal | 19 - graphics/trainers/palettes/young_couple.pal | 19 - graphics/trainers/palettes/youngster.pal | 19 - src/data/graphics/trainers.h | 386 +++++++++--------- 193 files changed, 193 insertions(+), 1884 deletions(-) rename graphics/trainers/back_pics/{brendan_back_pic.png => brendan.png} (100%) rename graphics/trainers/back_pics/{ruby_sapphire_brendan_back_pic.png => brendan_rs.png} (100%) rename graphics/trainers/back_pics/{leaf_back_pic.png => leaf.png} (100%) rename graphics/trainers/back_pics/{may_back_pic.png => may.png} (100%) rename graphics/trainers/back_pics/{ruby_sapphire_may_back_pic.png => may_rs.png} (100%) rename graphics/trainers/back_pics/{red_back_pic.png => red.png} (100%) rename graphics/trainers/back_pics/{steven_back_pic.png => steven.png} (100%) rename graphics/trainers/back_pics/{wally_back_pic.png => wally.png} (100%) rename graphics/trainers/front_pics/{aqua_admin_f_front_pic.png => aqua_admin_f.png} (100%) rename graphics/trainers/front_pics/{aqua_admin_m_front_pic.png => aqua_admin_m.png} (100%) rename graphics/trainers/front_pics/{aqua_grunt_f_front_pic.png => aqua_grunt_f.png} (100%) rename graphics/trainers/front_pics/{aqua_grunt_m_front_pic.png => aqua_grunt_m.png} (100%) rename graphics/trainers/front_pics/{aqua_leader_archie_front_pic.png => aqua_leader_archie.png} (100%) rename graphics/trainers/front_pics/{arena_tycoon_greta_front_pic.png => arena_tycoon_greta.png} (100%) rename graphics/trainers/front_pics/{aroma_lady_front_pic.png => aroma_lady.png} (100%) rename graphics/trainers/front_pics/{battle_girl_front_pic.png => battle_girl.png} (100%) rename graphics/trainers/front_pics/{beauty_front_pic.png => beauty.png} (100%) rename graphics/trainers/front_pics/{bird_keeper_front_pic.png => bird_keeper.png} (100%) rename graphics/trainers/front_pics/{black_belt_front_pic.png => black_belt.png} (100%) rename graphics/trainers/front_pics/{brendan_front_pic.png => brendan.png} (100%) rename graphics/trainers/front_pics/{ruby_sapphire_brendan_front_pic.png => brendan_rs.png} (100%) rename graphics/trainers/front_pics/{bug_catcher_front_pic.png => bug_catcher.png} (100%) rename graphics/trainers/front_pics/{bug_maniac_front_pic.png => bug_maniac.png} (100%) rename graphics/trainers/front_pics/{camper_front_pic.png => camper.png} (100%) rename graphics/trainers/front_pics/{champion_wallace_front_pic.png => champion_wallace.png} (100%) rename graphics/trainers/front_pics/{collector_front_pic.png => collector.png} (100%) rename graphics/trainers/front_pics/{cooltrainer_f_front_pic.png => cooltrainer_f.png} (100%) rename graphics/trainers/front_pics/{cooltrainer_m_front_pic.png => cooltrainer_m.png} (100%) rename graphics/trainers/front_pics/{cycling_triathlete_f_front_pic.png => cycling_triathlete_f.png} (100%) rename graphics/trainers/front_pics/{cycling_triathlete_m_front_pic.png => cycling_triathlete_m.png} (100%) rename graphics/trainers/front_pics/{dome_ace_tucker_front_pic.png => dome_ace_tucker.png} (100%) rename graphics/trainers/front_pics/{dragon_tamer_front_pic.png => dragon_tamer.png} (100%) rename graphics/trainers/front_pics/{elite_four_drake_front_pic.png => elite_four_drake.png} (100%) rename graphics/trainers/front_pics/{elite_four_glacia_front_pic.png => elite_four_glacia.png} (100%) rename graphics/trainers/front_pics/{elite_four_phoebe_front_pic.png => elite_four_phoebe.png} (100%) rename graphics/trainers/front_pics/{elite_four_sidney_front_pic.png => elite_four_sidney.png} (100%) rename graphics/trainers/front_pics/{expert_f_front_pic.png => expert_f.png} (100%) rename graphics/trainers/front_pics/{expert_m_front_pic.png => expert_m.png} (100%) rename graphics/trainers/front_pics/{factory_head_noland_front_pic.png => factory_head_noland.png} (100%) rename graphics/trainers/front_pics/{fisherman_front_pic.png => fisherman.png} (100%) rename graphics/trainers/front_pics/{gentleman_front_pic.png => gentleman.png} (100%) rename graphics/trainers/front_pics/{guitarist_front_pic.png => guitarist.png} (100%) rename graphics/trainers/front_pics/{hex_maniac_front_pic.png => hex_maniac.png} (100%) rename graphics/trainers/front_pics/{hiker_front_pic.png => hiker.png} (100%) rename graphics/trainers/front_pics/{interviewer_front_pic.png => interviewer.png} (100%) rename graphics/trainers/front_pics/{kindler_front_pic.png => kindler.png} (100%) rename graphics/trainers/front_pics/{lady_front_pic.png => lady.png} (100%) rename graphics/trainers/front_pics/{lass_front_pic.png => lass.png} (100%) rename graphics/trainers/front_pics/{leader_brawly_front_pic.png => leader_brawly.png} (100%) rename graphics/trainers/front_pics/{leader_flannery_front_pic.png => leader_flannery.png} (100%) rename graphics/trainers/front_pics/{leader_juan_front_pic.png => leader_juan.png} (100%) rename graphics/trainers/front_pics/{leader_norman_front_pic.png => leader_norman.png} (100%) rename graphics/trainers/front_pics/{leader_roxanne_front_pic.png => leader_roxanne.png} (100%) rename graphics/trainers/front_pics/{leader_tate_and_liza_front_pic.png => leader_tate_and_liza.png} (100%) rename graphics/trainers/front_pics/{leader_wattson_front_pic.png => leader_wattson.png} (100%) rename graphics/trainers/front_pics/{leader_winona_front_pic.png => leader_winona.png} (100%) rename graphics/trainers/front_pics/{leaf_front_pic.png => leaf.png} (100%) rename graphics/trainers/front_pics/{magma_admin_front_pic.png => magma_admin.png} (100%) rename graphics/trainers/front_pics/{magma_grunt_f_front_pic.png => magma_grunt_f.png} (100%) rename graphics/trainers/front_pics/{magma_grunt_m_front_pic.png => magma_grunt_m.png} (100%) rename graphics/trainers/front_pics/{magma_leader_maxie_front_pic.png => magma_leader_maxie.png} (100%) rename graphics/trainers/front_pics/{may_front_pic.png => may.png} (100%) rename graphics/trainers/front_pics/{ruby_sapphire_may_front_pic.png => may_rs.png} (100%) rename graphics/trainers/front_pics/{ninja_boy_front_pic.png => ninja_boy.png} (100%) rename graphics/trainers/front_pics/{old_couple_front_pic.png => old_couple.png} (100%) rename graphics/trainers/front_pics/{palace_maven_spenser_front_pic.png => palace_maven_spenser.png} (100%) rename graphics/trainers/front_pics/{parasol_lady_front_pic.png => parasol_lady.png} (100%) rename graphics/trainers/front_pics/{picnicker_front_pic.png => picnicker.png} (100%) rename graphics/trainers/front_pics/{pike_queen_lucy_front_pic.png => pike_queen_lucy.png} (100%) rename graphics/trainers/front_pics/{pokefan_f_front_pic.png => pokefan_f.png} (100%) rename graphics/trainers/front_pics/{pokefan_m_front_pic.png => pokefan_m.png} (100%) rename graphics/trainers/front_pics/{pokemaniac_front_pic.png => pokemaniac.png} (100%) rename graphics/trainers/front_pics/{pokemon_breeder_f_front_pic.png => pokemon_breeder_f.png} (100%) rename graphics/trainers/front_pics/{pokemon_breeder_m_front_pic.png => pokemon_breeder_m.png} (100%) rename graphics/trainers/front_pics/{pokemon_ranger_f_front_pic.png => pokemon_ranger_f.png} (100%) rename graphics/trainers/front_pics/{pokemon_ranger_m_front_pic.png => pokemon_ranger_m.png} (100%) rename graphics/trainers/front_pics/{psychic_f_front_pic.png => psychic_f.png} (100%) rename graphics/trainers/front_pics/{psychic_m_front_pic.png => psychic_m.png} (100%) rename graphics/trainers/front_pics/{pyramid_king_brandon_front_pic.png => pyramid_king_brandon.png} (100%) rename graphics/trainers/front_pics/{red_front_pic.png => red.png} (100%) rename graphics/trainers/front_pics/{rich_boy_front_pic.png => rich_boy.png} (100%) rename graphics/trainers/front_pics/{ruin_maniac_front_pic.png => ruin_maniac.png} (100%) rename graphics/trainers/front_pics/{running_triathlete_f_front_pic.png => running_triathlete_f.png} (100%) rename graphics/trainers/front_pics/{running_triathlete_m_front_pic.png => running_triathlete_m.png} (100%) rename graphics/trainers/front_pics/{sailor_front_pic.png => sailor.png} (100%) rename graphics/trainers/front_pics/{salon_maiden_anabel_front_pic.png => salon_maiden_anabel.png} (100%) rename graphics/trainers/front_pics/{school_kid_f_front_pic.png => school_kid_f.png} (100%) rename graphics/trainers/front_pics/{school_kid_m_front_pic.png => school_kid_m.png} (100%) rename graphics/trainers/front_pics/{sis_and_bro_front_pic.png => sis_and_bro.png} (100%) rename graphics/trainers/front_pics/{sr_and_jr_front_pic.png => sr_and_jr.png} (100%) rename graphics/trainers/front_pics/{steven_front_pic.png => steven.png} (100%) rename graphics/trainers/front_pics/{swimmer_f_front_pic.png => swimmer_f.png} (100%) rename graphics/trainers/front_pics/{swimmer_m_front_pic.png => swimmer_m.png} (100%) rename graphics/trainers/front_pics/{swimming_triathlete_f_front_pic.png => swimming_triathlete_f.png} (100%) rename graphics/trainers/front_pics/{swimming_triathlete_m_front_pic.png => swimming_triathlete_m.png} (100%) rename graphics/trainers/front_pics/{tuber_f_front_pic.png => tuber_f.png} (100%) rename graphics/trainers/front_pics/{tuber_m_front_pic.png => tuber_m.png} (100%) rename graphics/trainers/front_pics/{twins_front_pic.png => twins.png} (100%) rename graphics/trainers/front_pics/{wally_front_pic.png => wally.png} (100%) rename graphics/trainers/front_pics/{young_couple_front_pic.png => young_couple.png} (100%) rename graphics/trainers/front_pics/{youngster_front_pic.png => youngster.png} (100%) delete mode 100644 graphics/trainers/palettes/aqua_admin_f.pal delete mode 100644 graphics/trainers/palettes/aqua_admin_m.pal delete mode 100644 graphics/trainers/palettes/aqua_grunt_f.pal delete mode 100644 graphics/trainers/palettes/aqua_grunt_m.pal delete mode 100644 graphics/trainers/palettes/aqua_leader_archie.pal delete mode 100644 graphics/trainers/palettes/arena_tycoon_greta.pal delete mode 100644 graphics/trainers/palettes/aroma_lady.pal delete mode 100644 graphics/trainers/palettes/battle_girl.pal delete mode 100644 graphics/trainers/palettes/beauty.pal delete mode 100644 graphics/trainers/palettes/bird_keeper.pal delete mode 100644 graphics/trainers/palettes/black_belt.pal rename graphics/trainers/palettes/{ruby_sapphire_brendan.pal => brendan_rs.pal} (100%) delete mode 100644 graphics/trainers/palettes/bug_catcher.pal delete mode 100644 graphics/trainers/palettes/bug_maniac.pal delete mode 100644 graphics/trainers/palettes/camper.pal delete mode 100644 graphics/trainers/palettes/champion_wallace.pal delete mode 100644 graphics/trainers/palettes/collector.pal delete mode 100644 graphics/trainers/palettes/cooltrainer_f.pal delete mode 100644 graphics/trainers/palettes/cooltrainer_m.pal delete mode 100644 graphics/trainers/palettes/cycling_triathlete_f.pal delete mode 100644 graphics/trainers/palettes/cycling_triathlete_m.pal delete mode 100644 graphics/trainers/palettes/dome_ace_tucker.pal delete mode 100644 graphics/trainers/palettes/dragon_tamer.pal delete mode 100644 graphics/trainers/palettes/elite_four_drake.pal delete mode 100644 graphics/trainers/palettes/elite_four_glacia.pal delete mode 100644 graphics/trainers/palettes/elite_four_phoebe.pal delete mode 100644 graphics/trainers/palettes/elite_four_sidney.pal delete mode 100644 graphics/trainers/palettes/expert_f.pal delete mode 100644 graphics/trainers/palettes/expert_m.pal delete mode 100644 graphics/trainers/palettes/factory_head_noland.pal delete mode 100644 graphics/trainers/palettes/fisherman.pal delete mode 100644 graphics/trainers/palettes/gentleman.pal delete mode 100644 graphics/trainers/palettes/guitarist.pal delete mode 100644 graphics/trainers/palettes/hex_maniac.pal delete mode 100644 graphics/trainers/palettes/hiker.pal delete mode 100644 graphics/trainers/palettes/interviewer.pal delete mode 100644 graphics/trainers/palettes/kindler.pal delete mode 100644 graphics/trainers/palettes/lady.pal delete mode 100644 graphics/trainers/palettes/lass.pal delete mode 100644 graphics/trainers/palettes/leader_brawly.pal delete mode 100644 graphics/trainers/palettes/leader_flannery.pal delete mode 100644 graphics/trainers/palettes/leader_juan.pal delete mode 100644 graphics/trainers/palettes/leader_norman.pal delete mode 100644 graphics/trainers/palettes/leader_roxanne.pal delete mode 100644 graphics/trainers/palettes/leader_tate_and_liza.pal delete mode 100644 graphics/trainers/palettes/leader_wattson.pal delete mode 100644 graphics/trainers/palettes/leader_winona.pal delete mode 100644 graphics/trainers/palettes/leaf.pal delete mode 100644 graphics/trainers/palettes/leaf_back_pic.pal delete mode 100644 graphics/trainers/palettes/magma_admin.pal delete mode 100644 graphics/trainers/palettes/magma_grunt_f.pal delete mode 100644 graphics/trainers/palettes/magma_grunt_m.pal delete mode 100644 graphics/trainers/palettes/magma_leader_maxie.pal rename graphics/trainers/palettes/{ruby_sapphire_may.pal => may_rs.pal} (100%) delete mode 100644 graphics/trainers/palettes/ninja_boy.pal delete mode 100644 graphics/trainers/palettes/old_couple.pal delete mode 100644 graphics/trainers/palettes/palace_maven_spenser.pal delete mode 100644 graphics/trainers/palettes/parasol_lady.pal delete mode 100644 graphics/trainers/palettes/picnicker.pal delete mode 100644 graphics/trainers/palettes/pike_queen_lucy.pal delete mode 100644 graphics/trainers/palettes/pokefan_f.pal delete mode 100644 graphics/trainers/palettes/pokefan_m.pal delete mode 100644 graphics/trainers/palettes/pokemaniac.pal delete mode 100644 graphics/trainers/palettes/pokemon_breeder_f.pal delete mode 100644 graphics/trainers/palettes/pokemon_breeder_m.pal delete mode 100644 graphics/trainers/palettes/pokemon_ranger_f.pal delete mode 100644 graphics/trainers/palettes/pokemon_ranger_m.pal delete mode 100644 graphics/trainers/palettes/psychic_f.pal delete mode 100644 graphics/trainers/palettes/psychic_m.pal delete mode 100644 graphics/trainers/palettes/pyramid_king_brandon.pal delete mode 100644 graphics/trainers/palettes/red.pal delete mode 100644 graphics/trainers/palettes/red_back_pic.pal delete mode 100644 graphics/trainers/palettes/rich_boy.pal delete mode 100644 graphics/trainers/palettes/ruin_maniac.pal delete mode 100644 graphics/trainers/palettes/running_triathlete_f.pal delete mode 100644 graphics/trainers/palettes/running_triathlete_m.pal delete mode 100644 graphics/trainers/palettes/sailor.pal delete mode 100644 graphics/trainers/palettes/salon_maiden_anabel.pal delete mode 100644 graphics/trainers/palettes/school_kid_f.pal delete mode 100644 graphics/trainers/palettes/school_kid_m.pal delete mode 100644 graphics/trainers/palettes/sis_and_bro.pal delete mode 100644 graphics/trainers/palettes/sr_and_jr.pal delete mode 100644 graphics/trainers/palettes/swimmer_f.pal delete mode 100644 graphics/trainers/palettes/swimmer_m.pal delete mode 100644 graphics/trainers/palettes/swimming_triathlete_f.pal delete mode 100644 graphics/trainers/palettes/swimming_triathlete_m.pal delete mode 100644 graphics/trainers/palettes/tuber_f.pal delete mode 100644 graphics/trainers/palettes/tuber_m.pal delete mode 100644 graphics/trainers/palettes/twins.pal delete mode 100644 graphics/trainers/palettes/young_couple.pal delete mode 100644 graphics/trainers/palettes/youngster.pal diff --git a/graphics/trainers/back_pics/brendan_back_pic.png b/graphics/trainers/back_pics/brendan.png similarity index 100% rename from graphics/trainers/back_pics/brendan_back_pic.png rename to graphics/trainers/back_pics/brendan.png diff --git a/graphics/trainers/back_pics/ruby_sapphire_brendan_back_pic.png b/graphics/trainers/back_pics/brendan_rs.png similarity index 100% rename from graphics/trainers/back_pics/ruby_sapphire_brendan_back_pic.png rename to graphics/trainers/back_pics/brendan_rs.png diff --git a/graphics/trainers/back_pics/leaf_back_pic.png b/graphics/trainers/back_pics/leaf.png similarity index 100% rename from graphics/trainers/back_pics/leaf_back_pic.png rename to graphics/trainers/back_pics/leaf.png diff --git a/graphics/trainers/back_pics/may_back_pic.png b/graphics/trainers/back_pics/may.png similarity index 100% rename from graphics/trainers/back_pics/may_back_pic.png rename to graphics/trainers/back_pics/may.png diff --git a/graphics/trainers/back_pics/ruby_sapphire_may_back_pic.png b/graphics/trainers/back_pics/may_rs.png similarity index 100% rename from graphics/trainers/back_pics/ruby_sapphire_may_back_pic.png rename to graphics/trainers/back_pics/may_rs.png diff --git a/graphics/trainers/back_pics/red_back_pic.png b/graphics/trainers/back_pics/red.png similarity index 100% rename from graphics/trainers/back_pics/red_back_pic.png rename to graphics/trainers/back_pics/red.png diff --git a/graphics/trainers/back_pics/steven_back_pic.png b/graphics/trainers/back_pics/steven.png similarity index 100% rename from graphics/trainers/back_pics/steven_back_pic.png rename to graphics/trainers/back_pics/steven.png diff --git a/graphics/trainers/back_pics/wally_back_pic.png b/graphics/trainers/back_pics/wally.png similarity index 100% rename from graphics/trainers/back_pics/wally_back_pic.png rename to graphics/trainers/back_pics/wally.png diff --git a/graphics/trainers/front_pics/aqua_admin_f_front_pic.png b/graphics/trainers/front_pics/aqua_admin_f.png similarity index 100% rename from graphics/trainers/front_pics/aqua_admin_f_front_pic.png rename to graphics/trainers/front_pics/aqua_admin_f.png diff --git a/graphics/trainers/front_pics/aqua_admin_m_front_pic.png b/graphics/trainers/front_pics/aqua_admin_m.png similarity index 100% rename from graphics/trainers/front_pics/aqua_admin_m_front_pic.png rename to graphics/trainers/front_pics/aqua_admin_m.png diff --git a/graphics/trainers/front_pics/aqua_grunt_f_front_pic.png b/graphics/trainers/front_pics/aqua_grunt_f.png similarity index 100% rename from graphics/trainers/front_pics/aqua_grunt_f_front_pic.png rename to graphics/trainers/front_pics/aqua_grunt_f.png diff --git a/graphics/trainers/front_pics/aqua_grunt_m_front_pic.png b/graphics/trainers/front_pics/aqua_grunt_m.png similarity index 100% rename from graphics/trainers/front_pics/aqua_grunt_m_front_pic.png rename to graphics/trainers/front_pics/aqua_grunt_m.png diff --git a/graphics/trainers/front_pics/aqua_leader_archie_front_pic.png b/graphics/trainers/front_pics/aqua_leader_archie.png similarity index 100% rename from graphics/trainers/front_pics/aqua_leader_archie_front_pic.png rename to graphics/trainers/front_pics/aqua_leader_archie.png diff --git a/graphics/trainers/front_pics/arena_tycoon_greta_front_pic.png b/graphics/trainers/front_pics/arena_tycoon_greta.png similarity index 100% rename from graphics/trainers/front_pics/arena_tycoon_greta_front_pic.png rename to graphics/trainers/front_pics/arena_tycoon_greta.png diff --git a/graphics/trainers/front_pics/aroma_lady_front_pic.png b/graphics/trainers/front_pics/aroma_lady.png similarity index 100% rename from graphics/trainers/front_pics/aroma_lady_front_pic.png rename to graphics/trainers/front_pics/aroma_lady.png diff --git a/graphics/trainers/front_pics/battle_girl_front_pic.png b/graphics/trainers/front_pics/battle_girl.png similarity index 100% rename from graphics/trainers/front_pics/battle_girl_front_pic.png rename to graphics/trainers/front_pics/battle_girl.png diff --git a/graphics/trainers/front_pics/beauty_front_pic.png b/graphics/trainers/front_pics/beauty.png similarity index 100% rename from graphics/trainers/front_pics/beauty_front_pic.png rename to graphics/trainers/front_pics/beauty.png diff --git a/graphics/trainers/front_pics/bird_keeper_front_pic.png b/graphics/trainers/front_pics/bird_keeper.png similarity index 100% rename from graphics/trainers/front_pics/bird_keeper_front_pic.png rename to graphics/trainers/front_pics/bird_keeper.png diff --git a/graphics/trainers/front_pics/black_belt_front_pic.png b/graphics/trainers/front_pics/black_belt.png similarity index 100% rename from graphics/trainers/front_pics/black_belt_front_pic.png rename to graphics/trainers/front_pics/black_belt.png diff --git a/graphics/trainers/front_pics/brendan_front_pic.png b/graphics/trainers/front_pics/brendan.png similarity index 100% rename from graphics/trainers/front_pics/brendan_front_pic.png rename to graphics/trainers/front_pics/brendan.png diff --git a/graphics/trainers/front_pics/ruby_sapphire_brendan_front_pic.png b/graphics/trainers/front_pics/brendan_rs.png similarity index 100% rename from graphics/trainers/front_pics/ruby_sapphire_brendan_front_pic.png rename to graphics/trainers/front_pics/brendan_rs.png diff --git a/graphics/trainers/front_pics/bug_catcher_front_pic.png b/graphics/trainers/front_pics/bug_catcher.png similarity index 100% rename from graphics/trainers/front_pics/bug_catcher_front_pic.png rename to graphics/trainers/front_pics/bug_catcher.png diff --git a/graphics/trainers/front_pics/bug_maniac_front_pic.png b/graphics/trainers/front_pics/bug_maniac.png similarity index 100% rename from graphics/trainers/front_pics/bug_maniac_front_pic.png rename to graphics/trainers/front_pics/bug_maniac.png diff --git a/graphics/trainers/front_pics/camper_front_pic.png b/graphics/trainers/front_pics/camper.png similarity index 100% rename from graphics/trainers/front_pics/camper_front_pic.png rename to graphics/trainers/front_pics/camper.png diff --git a/graphics/trainers/front_pics/champion_wallace_front_pic.png b/graphics/trainers/front_pics/champion_wallace.png similarity index 100% rename from graphics/trainers/front_pics/champion_wallace_front_pic.png rename to graphics/trainers/front_pics/champion_wallace.png diff --git a/graphics/trainers/front_pics/collector_front_pic.png b/graphics/trainers/front_pics/collector.png similarity index 100% rename from graphics/trainers/front_pics/collector_front_pic.png rename to graphics/trainers/front_pics/collector.png diff --git a/graphics/trainers/front_pics/cooltrainer_f_front_pic.png b/graphics/trainers/front_pics/cooltrainer_f.png similarity index 100% rename from graphics/trainers/front_pics/cooltrainer_f_front_pic.png rename to graphics/trainers/front_pics/cooltrainer_f.png diff --git a/graphics/trainers/front_pics/cooltrainer_m_front_pic.png b/graphics/trainers/front_pics/cooltrainer_m.png similarity index 100% rename from graphics/trainers/front_pics/cooltrainer_m_front_pic.png rename to graphics/trainers/front_pics/cooltrainer_m.png diff --git a/graphics/trainers/front_pics/cycling_triathlete_f_front_pic.png b/graphics/trainers/front_pics/cycling_triathlete_f.png similarity index 100% rename from graphics/trainers/front_pics/cycling_triathlete_f_front_pic.png rename to graphics/trainers/front_pics/cycling_triathlete_f.png diff --git a/graphics/trainers/front_pics/cycling_triathlete_m_front_pic.png b/graphics/trainers/front_pics/cycling_triathlete_m.png similarity index 100% rename from graphics/trainers/front_pics/cycling_triathlete_m_front_pic.png rename to graphics/trainers/front_pics/cycling_triathlete_m.png diff --git a/graphics/trainers/front_pics/dome_ace_tucker_front_pic.png b/graphics/trainers/front_pics/dome_ace_tucker.png similarity index 100% rename from graphics/trainers/front_pics/dome_ace_tucker_front_pic.png rename to graphics/trainers/front_pics/dome_ace_tucker.png diff --git a/graphics/trainers/front_pics/dragon_tamer_front_pic.png b/graphics/trainers/front_pics/dragon_tamer.png similarity index 100% rename from graphics/trainers/front_pics/dragon_tamer_front_pic.png rename to graphics/trainers/front_pics/dragon_tamer.png diff --git a/graphics/trainers/front_pics/elite_four_drake_front_pic.png b/graphics/trainers/front_pics/elite_four_drake.png similarity index 100% rename from graphics/trainers/front_pics/elite_four_drake_front_pic.png rename to graphics/trainers/front_pics/elite_four_drake.png diff --git a/graphics/trainers/front_pics/elite_four_glacia_front_pic.png b/graphics/trainers/front_pics/elite_four_glacia.png similarity index 100% rename from graphics/trainers/front_pics/elite_four_glacia_front_pic.png rename to graphics/trainers/front_pics/elite_four_glacia.png diff --git a/graphics/trainers/front_pics/elite_four_phoebe_front_pic.png b/graphics/trainers/front_pics/elite_four_phoebe.png similarity index 100% rename from graphics/trainers/front_pics/elite_four_phoebe_front_pic.png rename to graphics/trainers/front_pics/elite_four_phoebe.png diff --git a/graphics/trainers/front_pics/elite_four_sidney_front_pic.png b/graphics/trainers/front_pics/elite_four_sidney.png similarity index 100% rename from graphics/trainers/front_pics/elite_four_sidney_front_pic.png rename to graphics/trainers/front_pics/elite_four_sidney.png diff --git a/graphics/trainers/front_pics/expert_f_front_pic.png b/graphics/trainers/front_pics/expert_f.png similarity index 100% rename from graphics/trainers/front_pics/expert_f_front_pic.png rename to graphics/trainers/front_pics/expert_f.png diff --git a/graphics/trainers/front_pics/expert_m_front_pic.png b/graphics/trainers/front_pics/expert_m.png similarity index 100% rename from graphics/trainers/front_pics/expert_m_front_pic.png rename to graphics/trainers/front_pics/expert_m.png diff --git a/graphics/trainers/front_pics/factory_head_noland_front_pic.png b/graphics/trainers/front_pics/factory_head_noland.png similarity index 100% rename from graphics/trainers/front_pics/factory_head_noland_front_pic.png rename to graphics/trainers/front_pics/factory_head_noland.png diff --git a/graphics/trainers/front_pics/fisherman_front_pic.png b/graphics/trainers/front_pics/fisherman.png similarity index 100% rename from graphics/trainers/front_pics/fisherman_front_pic.png rename to graphics/trainers/front_pics/fisherman.png diff --git a/graphics/trainers/front_pics/gentleman_front_pic.png b/graphics/trainers/front_pics/gentleman.png similarity index 100% rename from graphics/trainers/front_pics/gentleman_front_pic.png rename to graphics/trainers/front_pics/gentleman.png diff --git a/graphics/trainers/front_pics/guitarist_front_pic.png b/graphics/trainers/front_pics/guitarist.png similarity index 100% rename from graphics/trainers/front_pics/guitarist_front_pic.png rename to graphics/trainers/front_pics/guitarist.png diff --git a/graphics/trainers/front_pics/hex_maniac_front_pic.png b/graphics/trainers/front_pics/hex_maniac.png similarity index 100% rename from graphics/trainers/front_pics/hex_maniac_front_pic.png rename to graphics/trainers/front_pics/hex_maniac.png diff --git a/graphics/trainers/front_pics/hiker_front_pic.png b/graphics/trainers/front_pics/hiker.png similarity index 100% rename from graphics/trainers/front_pics/hiker_front_pic.png rename to graphics/trainers/front_pics/hiker.png diff --git a/graphics/trainers/front_pics/interviewer_front_pic.png b/graphics/trainers/front_pics/interviewer.png similarity index 100% rename from graphics/trainers/front_pics/interviewer_front_pic.png rename to graphics/trainers/front_pics/interviewer.png diff --git a/graphics/trainers/front_pics/kindler_front_pic.png b/graphics/trainers/front_pics/kindler.png similarity index 100% rename from graphics/trainers/front_pics/kindler_front_pic.png rename to graphics/trainers/front_pics/kindler.png diff --git a/graphics/trainers/front_pics/lady_front_pic.png b/graphics/trainers/front_pics/lady.png similarity index 100% rename from graphics/trainers/front_pics/lady_front_pic.png rename to graphics/trainers/front_pics/lady.png diff --git a/graphics/trainers/front_pics/lass_front_pic.png b/graphics/trainers/front_pics/lass.png similarity index 100% rename from graphics/trainers/front_pics/lass_front_pic.png rename to graphics/trainers/front_pics/lass.png diff --git a/graphics/trainers/front_pics/leader_brawly_front_pic.png b/graphics/trainers/front_pics/leader_brawly.png similarity index 100% rename from graphics/trainers/front_pics/leader_brawly_front_pic.png rename to graphics/trainers/front_pics/leader_brawly.png diff --git a/graphics/trainers/front_pics/leader_flannery_front_pic.png b/graphics/trainers/front_pics/leader_flannery.png similarity index 100% rename from graphics/trainers/front_pics/leader_flannery_front_pic.png rename to graphics/trainers/front_pics/leader_flannery.png diff --git a/graphics/trainers/front_pics/leader_juan_front_pic.png b/graphics/trainers/front_pics/leader_juan.png similarity index 100% rename from graphics/trainers/front_pics/leader_juan_front_pic.png rename to graphics/trainers/front_pics/leader_juan.png diff --git a/graphics/trainers/front_pics/leader_norman_front_pic.png b/graphics/trainers/front_pics/leader_norman.png similarity index 100% rename from graphics/trainers/front_pics/leader_norman_front_pic.png rename to graphics/trainers/front_pics/leader_norman.png diff --git a/graphics/trainers/front_pics/leader_roxanne_front_pic.png b/graphics/trainers/front_pics/leader_roxanne.png similarity index 100% rename from graphics/trainers/front_pics/leader_roxanne_front_pic.png rename to graphics/trainers/front_pics/leader_roxanne.png diff --git a/graphics/trainers/front_pics/leader_tate_and_liza_front_pic.png b/graphics/trainers/front_pics/leader_tate_and_liza.png similarity index 100% rename from graphics/trainers/front_pics/leader_tate_and_liza_front_pic.png rename to graphics/trainers/front_pics/leader_tate_and_liza.png diff --git a/graphics/trainers/front_pics/leader_wattson_front_pic.png b/graphics/trainers/front_pics/leader_wattson.png similarity index 100% rename from graphics/trainers/front_pics/leader_wattson_front_pic.png rename to graphics/trainers/front_pics/leader_wattson.png diff --git a/graphics/trainers/front_pics/leader_winona_front_pic.png b/graphics/trainers/front_pics/leader_winona.png similarity index 100% rename from graphics/trainers/front_pics/leader_winona_front_pic.png rename to graphics/trainers/front_pics/leader_winona.png diff --git a/graphics/trainers/front_pics/leaf_front_pic.png b/graphics/trainers/front_pics/leaf.png similarity index 100% rename from graphics/trainers/front_pics/leaf_front_pic.png rename to graphics/trainers/front_pics/leaf.png diff --git a/graphics/trainers/front_pics/magma_admin_front_pic.png b/graphics/trainers/front_pics/magma_admin.png similarity index 100% rename from graphics/trainers/front_pics/magma_admin_front_pic.png rename to graphics/trainers/front_pics/magma_admin.png diff --git a/graphics/trainers/front_pics/magma_grunt_f_front_pic.png b/graphics/trainers/front_pics/magma_grunt_f.png similarity index 100% rename from graphics/trainers/front_pics/magma_grunt_f_front_pic.png rename to graphics/trainers/front_pics/magma_grunt_f.png diff --git a/graphics/trainers/front_pics/magma_grunt_m_front_pic.png b/graphics/trainers/front_pics/magma_grunt_m.png similarity index 100% rename from graphics/trainers/front_pics/magma_grunt_m_front_pic.png rename to graphics/trainers/front_pics/magma_grunt_m.png diff --git a/graphics/trainers/front_pics/magma_leader_maxie_front_pic.png b/graphics/trainers/front_pics/magma_leader_maxie.png similarity index 100% rename from graphics/trainers/front_pics/magma_leader_maxie_front_pic.png rename to graphics/trainers/front_pics/magma_leader_maxie.png diff --git a/graphics/trainers/front_pics/may_front_pic.png b/graphics/trainers/front_pics/may.png similarity index 100% rename from graphics/trainers/front_pics/may_front_pic.png rename to graphics/trainers/front_pics/may.png diff --git a/graphics/trainers/front_pics/ruby_sapphire_may_front_pic.png b/graphics/trainers/front_pics/may_rs.png similarity index 100% rename from graphics/trainers/front_pics/ruby_sapphire_may_front_pic.png rename to graphics/trainers/front_pics/may_rs.png diff --git a/graphics/trainers/front_pics/ninja_boy_front_pic.png b/graphics/trainers/front_pics/ninja_boy.png similarity index 100% rename from graphics/trainers/front_pics/ninja_boy_front_pic.png rename to graphics/trainers/front_pics/ninja_boy.png diff --git a/graphics/trainers/front_pics/old_couple_front_pic.png b/graphics/trainers/front_pics/old_couple.png similarity index 100% rename from graphics/trainers/front_pics/old_couple_front_pic.png rename to graphics/trainers/front_pics/old_couple.png diff --git a/graphics/trainers/front_pics/palace_maven_spenser_front_pic.png b/graphics/trainers/front_pics/palace_maven_spenser.png similarity index 100% rename from graphics/trainers/front_pics/palace_maven_spenser_front_pic.png rename to graphics/trainers/front_pics/palace_maven_spenser.png diff --git a/graphics/trainers/front_pics/parasol_lady_front_pic.png b/graphics/trainers/front_pics/parasol_lady.png similarity index 100% rename from graphics/trainers/front_pics/parasol_lady_front_pic.png rename to graphics/trainers/front_pics/parasol_lady.png diff --git a/graphics/trainers/front_pics/picnicker_front_pic.png b/graphics/trainers/front_pics/picnicker.png similarity index 100% rename from graphics/trainers/front_pics/picnicker_front_pic.png rename to graphics/trainers/front_pics/picnicker.png diff --git a/graphics/trainers/front_pics/pike_queen_lucy_front_pic.png b/graphics/trainers/front_pics/pike_queen_lucy.png similarity index 100% rename from graphics/trainers/front_pics/pike_queen_lucy_front_pic.png rename to graphics/trainers/front_pics/pike_queen_lucy.png diff --git a/graphics/trainers/front_pics/pokefan_f_front_pic.png b/graphics/trainers/front_pics/pokefan_f.png similarity index 100% rename from graphics/trainers/front_pics/pokefan_f_front_pic.png rename to graphics/trainers/front_pics/pokefan_f.png diff --git a/graphics/trainers/front_pics/pokefan_m_front_pic.png b/graphics/trainers/front_pics/pokefan_m.png similarity index 100% rename from graphics/trainers/front_pics/pokefan_m_front_pic.png rename to graphics/trainers/front_pics/pokefan_m.png diff --git a/graphics/trainers/front_pics/pokemaniac_front_pic.png b/graphics/trainers/front_pics/pokemaniac.png similarity index 100% rename from graphics/trainers/front_pics/pokemaniac_front_pic.png rename to graphics/trainers/front_pics/pokemaniac.png diff --git a/graphics/trainers/front_pics/pokemon_breeder_f_front_pic.png b/graphics/trainers/front_pics/pokemon_breeder_f.png similarity index 100% rename from graphics/trainers/front_pics/pokemon_breeder_f_front_pic.png rename to graphics/trainers/front_pics/pokemon_breeder_f.png diff --git a/graphics/trainers/front_pics/pokemon_breeder_m_front_pic.png b/graphics/trainers/front_pics/pokemon_breeder_m.png similarity index 100% rename from graphics/trainers/front_pics/pokemon_breeder_m_front_pic.png rename to graphics/trainers/front_pics/pokemon_breeder_m.png diff --git a/graphics/trainers/front_pics/pokemon_ranger_f_front_pic.png b/graphics/trainers/front_pics/pokemon_ranger_f.png similarity index 100% rename from graphics/trainers/front_pics/pokemon_ranger_f_front_pic.png rename to graphics/trainers/front_pics/pokemon_ranger_f.png diff --git a/graphics/trainers/front_pics/pokemon_ranger_m_front_pic.png b/graphics/trainers/front_pics/pokemon_ranger_m.png similarity index 100% rename from graphics/trainers/front_pics/pokemon_ranger_m_front_pic.png rename to graphics/trainers/front_pics/pokemon_ranger_m.png diff --git a/graphics/trainers/front_pics/psychic_f_front_pic.png b/graphics/trainers/front_pics/psychic_f.png similarity index 100% rename from graphics/trainers/front_pics/psychic_f_front_pic.png rename to graphics/trainers/front_pics/psychic_f.png diff --git a/graphics/trainers/front_pics/psychic_m_front_pic.png b/graphics/trainers/front_pics/psychic_m.png similarity index 100% rename from graphics/trainers/front_pics/psychic_m_front_pic.png rename to graphics/trainers/front_pics/psychic_m.png diff --git a/graphics/trainers/front_pics/pyramid_king_brandon_front_pic.png b/graphics/trainers/front_pics/pyramid_king_brandon.png similarity index 100% rename from graphics/trainers/front_pics/pyramid_king_brandon_front_pic.png rename to graphics/trainers/front_pics/pyramid_king_brandon.png diff --git a/graphics/trainers/front_pics/red_front_pic.png b/graphics/trainers/front_pics/red.png similarity index 100% rename from graphics/trainers/front_pics/red_front_pic.png rename to graphics/trainers/front_pics/red.png diff --git a/graphics/trainers/front_pics/rich_boy_front_pic.png b/graphics/trainers/front_pics/rich_boy.png similarity index 100% rename from graphics/trainers/front_pics/rich_boy_front_pic.png rename to graphics/trainers/front_pics/rich_boy.png diff --git a/graphics/trainers/front_pics/ruin_maniac_front_pic.png b/graphics/trainers/front_pics/ruin_maniac.png similarity index 100% rename from graphics/trainers/front_pics/ruin_maniac_front_pic.png rename to graphics/trainers/front_pics/ruin_maniac.png diff --git a/graphics/trainers/front_pics/running_triathlete_f_front_pic.png b/graphics/trainers/front_pics/running_triathlete_f.png similarity index 100% rename from graphics/trainers/front_pics/running_triathlete_f_front_pic.png rename to graphics/trainers/front_pics/running_triathlete_f.png diff --git a/graphics/trainers/front_pics/running_triathlete_m_front_pic.png b/graphics/trainers/front_pics/running_triathlete_m.png similarity index 100% rename from graphics/trainers/front_pics/running_triathlete_m_front_pic.png rename to graphics/trainers/front_pics/running_triathlete_m.png diff --git a/graphics/trainers/front_pics/sailor_front_pic.png b/graphics/trainers/front_pics/sailor.png similarity index 100% rename from graphics/trainers/front_pics/sailor_front_pic.png rename to graphics/trainers/front_pics/sailor.png diff --git a/graphics/trainers/front_pics/salon_maiden_anabel_front_pic.png b/graphics/trainers/front_pics/salon_maiden_anabel.png similarity index 100% rename from graphics/trainers/front_pics/salon_maiden_anabel_front_pic.png rename to graphics/trainers/front_pics/salon_maiden_anabel.png diff --git a/graphics/trainers/front_pics/school_kid_f_front_pic.png b/graphics/trainers/front_pics/school_kid_f.png similarity index 100% rename from graphics/trainers/front_pics/school_kid_f_front_pic.png rename to graphics/trainers/front_pics/school_kid_f.png diff --git a/graphics/trainers/front_pics/school_kid_m_front_pic.png b/graphics/trainers/front_pics/school_kid_m.png similarity index 100% rename from graphics/trainers/front_pics/school_kid_m_front_pic.png rename to graphics/trainers/front_pics/school_kid_m.png diff --git a/graphics/trainers/front_pics/sis_and_bro_front_pic.png b/graphics/trainers/front_pics/sis_and_bro.png similarity index 100% rename from graphics/trainers/front_pics/sis_and_bro_front_pic.png rename to graphics/trainers/front_pics/sis_and_bro.png diff --git a/graphics/trainers/front_pics/sr_and_jr_front_pic.png b/graphics/trainers/front_pics/sr_and_jr.png similarity index 100% rename from graphics/trainers/front_pics/sr_and_jr_front_pic.png rename to graphics/trainers/front_pics/sr_and_jr.png diff --git a/graphics/trainers/front_pics/steven_front_pic.png b/graphics/trainers/front_pics/steven.png similarity index 100% rename from graphics/trainers/front_pics/steven_front_pic.png rename to graphics/trainers/front_pics/steven.png diff --git a/graphics/trainers/front_pics/swimmer_f_front_pic.png b/graphics/trainers/front_pics/swimmer_f.png similarity index 100% rename from graphics/trainers/front_pics/swimmer_f_front_pic.png rename to graphics/trainers/front_pics/swimmer_f.png diff --git a/graphics/trainers/front_pics/swimmer_m_front_pic.png b/graphics/trainers/front_pics/swimmer_m.png similarity index 100% rename from graphics/trainers/front_pics/swimmer_m_front_pic.png rename to graphics/trainers/front_pics/swimmer_m.png diff --git a/graphics/trainers/front_pics/swimming_triathlete_f_front_pic.png b/graphics/trainers/front_pics/swimming_triathlete_f.png similarity index 100% rename from graphics/trainers/front_pics/swimming_triathlete_f_front_pic.png rename to graphics/trainers/front_pics/swimming_triathlete_f.png diff --git a/graphics/trainers/front_pics/swimming_triathlete_m_front_pic.png b/graphics/trainers/front_pics/swimming_triathlete_m.png similarity index 100% rename from graphics/trainers/front_pics/swimming_triathlete_m_front_pic.png rename to graphics/trainers/front_pics/swimming_triathlete_m.png diff --git a/graphics/trainers/front_pics/tuber_f_front_pic.png b/graphics/trainers/front_pics/tuber_f.png similarity index 100% rename from graphics/trainers/front_pics/tuber_f_front_pic.png rename to graphics/trainers/front_pics/tuber_f.png diff --git a/graphics/trainers/front_pics/tuber_m_front_pic.png b/graphics/trainers/front_pics/tuber_m.png similarity index 100% rename from graphics/trainers/front_pics/tuber_m_front_pic.png rename to graphics/trainers/front_pics/tuber_m.png diff --git a/graphics/trainers/front_pics/twins_front_pic.png b/graphics/trainers/front_pics/twins.png similarity index 100% rename from graphics/trainers/front_pics/twins_front_pic.png rename to graphics/trainers/front_pics/twins.png diff --git a/graphics/trainers/front_pics/wally_front_pic.png b/graphics/trainers/front_pics/wally.png similarity index 100% rename from graphics/trainers/front_pics/wally_front_pic.png rename to graphics/trainers/front_pics/wally.png diff --git a/graphics/trainers/front_pics/young_couple_front_pic.png b/graphics/trainers/front_pics/young_couple.png similarity index 100% rename from graphics/trainers/front_pics/young_couple_front_pic.png rename to graphics/trainers/front_pics/young_couple.png diff --git a/graphics/trainers/front_pics/youngster_front_pic.png b/graphics/trainers/front_pics/youngster.png similarity index 100% rename from graphics/trainers/front_pics/youngster_front_pic.png rename to graphics/trainers/front_pics/youngster.png diff --git a/graphics/trainers/palettes/aqua_admin_f.pal b/graphics/trainers/palettes/aqua_admin_f.pal deleted file mode 100644 index 4bad68770..000000000 --- a/graphics/trainers/palettes/aqua_admin_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 131 41 -189 156 90 -238 98 41 -180 65 41 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/aqua_admin_m.pal b/graphics/trainers/palettes/aqua_admin_m.pal deleted file mode 100644 index 2a7a46d46..000000000 --- a/graphics/trainers/palettes/aqua_admin_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 131 41 -189 156 90 -222 82 24 -164 49 24 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/aqua_grunt_f.pal b/graphics/trainers/palettes/aqua_grunt_f.pal deleted file mode 100644 index 4563eba48..000000000 --- a/graphics/trainers/palettes/aqua_grunt_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -164 74 65 -189 156 90 -255 106 98 -205 82 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/aqua_grunt_m.pal b/graphics/trainers/palettes/aqua_grunt_m.pal deleted file mode 100644 index c2b28ead9..000000000 --- a/graphics/trainers/palettes/aqua_grunt_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 164 197 -189 156 90 -255 115 148 -213 82 115 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/aqua_leader_archie.pal b/graphics/trainers/palettes/aqua_leader_archie.pal deleted file mode 100644 index a778ea6bb..000000000 --- a/graphics/trainers/palettes/aqua_leader_archie.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -131 156 180 -106 123 148 -82 90 115 -57 65 98 -213 213 222 -82 90 156 -24 32 49 -148 156 222 -106 115 213 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/arena_tycoon_greta.pal b/graphics/trainers/palettes/arena_tycoon_greta.pal deleted file mode 100644 index 60c45e8e9..000000000 --- a/graphics/trainers/palettes/arena_tycoon_greta.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -255 230 106 -213 189 90 -213 222 230 -65 82 123 -189 156 90 -255 115 148 -213 82 115 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/aroma_lady.pal b/graphics/trainers/palettes/aroma_lady.pal deleted file mode 100644 index eb9f3dfd4..000000000 --- a/graphics/trainers/palettes/aroma_lady.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 213 172 -238 197 148 -205 156 115 -115 82 65 -238 230 255 -205 197 213 -156 164 205 -106 98 148 -74 222 148 -172 115 41 -115 65 24 -238 90 131 -189 65 90 -106 255 156 -0 0 0 diff --git a/graphics/trainers/palettes/battle_girl.pal b/graphics/trainers/palettes/battle_girl.pal deleted file mode 100644 index 7f172b169..000000000 --- a/graphics/trainers/palettes/battle_girl.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -255 164 82 -230 106 0 -197 65 65 -156 106 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/beauty.pal b/graphics/trainers/palettes/beauty.pal deleted file mode 100644 index ab549df20..000000000 --- a/graphics/trainers/palettes/beauty.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 172 131 -205 131 115 -123 82 74 -148 131 139 -255 205 106 -213 172 74 -164 123 82 -115 90 115 -74 49 74 -255 82 57 -180 82 74 -131 74 65 -255 255 255 -0 0 24 diff --git a/graphics/trainers/palettes/bird_keeper.pal b/graphics/trainers/palettes/bird_keeper.pal deleted file mode 100644 index 87194c84a..000000000 --- a/graphics/trainers/palettes/bird_keeper.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -164 180 197 -131 139 156 -90 98 115 -57 65 82 -213 213 222 -131 16 41 -24 32 49 -213 82 90 -180 41 57 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/black_belt.pal b/graphics/trainers/palettes/black_belt.pal deleted file mode 100644 index 869e5d8df..000000000 --- a/graphics/trainers/palettes/black_belt.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -246 205 189 -222 172 148 -172 131 106 -90 65 49 -148 131 123 -106 90 82 -82 90 115 -49 57 82 -205 189 189 -189 164 164 -156 139 139 -255 98 90 -197 65 65 -246 230 230 -0 0 0 diff --git a/graphics/trainers/palettes/ruby_sapphire_brendan.pal b/graphics/trainers/palettes/brendan_rs.pal similarity index 100% rename from graphics/trainers/palettes/ruby_sapphire_brendan.pal rename to graphics/trainers/palettes/brendan_rs.pal diff --git a/graphics/trainers/palettes/bug_catcher.pal b/graphics/trainers/palettes/bug_catcher.pal deleted file mode 100644 index c68f56690..000000000 --- a/graphics/trainers/palettes/bug_catcher.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 180 148 -213 148 115 -123 90 82 -222 222 164 -197 197 139 -156 139 74 -41 57 98 -197 197 238 -246 238 213 -189 49 57 -98 164 222 -49 123 156 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/bug_maniac.pal b/graphics/trainers/palettes/bug_maniac.pal deleted file mode 100644 index 2aa329179..000000000 --- a/graphics/trainers/palettes/bug_maniac.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -49 123 156 -49 65 131 -65 74 74 -222 222 164 -197 197 139 -205 213 213 -156 139 74 -98 164 222 -106 115 115 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/camper.pal b/graphics/trainers/palettes/camper.pal deleted file mode 100644 index e5c224fd2..000000000 --- a/graphics/trainers/palettes/camper.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -230 189 156 -205 156 115 -115 82 65 -131 213 205 -82 164 148 -180 189 222 -57 90 74 -24 49 90 -98 115 230 -57 82 131 -255 98 41 -189 74 41 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/champion_wallace.pal b/graphics/trainers/palettes/champion_wallace.pal deleted file mode 100644 index eaaed070f..000000000 --- a/graphics/trainers/palettes/champion_wallace.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -222 180 148 -189 139 106 -98 57 65 -189 131 255 -148 106 172 -115 131 255 -82 106 180 -197 197 213 -57 74 115 -139 139 164 -57 41 57 -98 57 98 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/collector.pal b/graphics/trainers/palettes/collector.pal deleted file mode 100644 index d4d9221e2..000000000 --- a/graphics/trainers/palettes/collector.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 180 148 -197 139 115 -123 90 82 -106 139 189 -65 98 148 -32 74 123 -255 98 90 -197 65 65 -213 222 230 -131 74 65 -115 123 131 -164 172 180 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/cooltrainer_f.pal b/graphics/trainers/palettes/cooltrainer_f.pal deleted file mode 100644 index 292d0fc78..000000000 --- a/graphics/trainers/palettes/cooltrainer_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -238 197 156 -205 156 115 -115 82 65 -238 156 115 -205 90 74 -0 189 222 -123 41 24 -180 230 139 -139 180 57 -74 90 32 -255 246 189 -213 205 131 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/cooltrainer_m.pal b/graphics/trainers/palettes/cooltrainer_m.pal deleted file mode 100644 index 52a32e925..000000000 --- a/graphics/trainers/palettes/cooltrainer_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -246 205 156 -205 156 115 -115 82 65 -238 156 115 -230 98 82 -180 90 74 -131 49 32 -57 90 41 -164 180 106 -98 123 57 -255 246 189 -213 205 131 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/cycling_triathlete_f.pal b/graphics/trainers/palettes/cycling_triathlete_f.pal deleted file mode 100644 index b72bb3011..000000000 --- a/graphics/trainers/palettes/cycling_triathlete_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -57 41 57 -57 74 106 -131 131 156 -139 156 238 -115 131 205 -98 106 172 -205 197 255 -230 90 65 -189 74 41 -139 74 82 -255 255 255 -0 0 24 diff --git a/graphics/trainers/palettes/cycling_triathlete_m.pal b/graphics/trainers/palettes/cycling_triathlete_m.pal deleted file mode 100644 index 9255a4a94..000000000 --- a/graphics/trainers/palettes/cycling_triathlete_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -238 189 139 -189 148 115 -139 106 82 -57 41 57 -115 90 106 -156 131 156 -156 213 255 -106 164 222 -82 131 197 -205 197 255 -230 90 65 -189 74 41 -139 74 82 -255 255 255 -0 0 24 diff --git a/graphics/trainers/palettes/dome_ace_tucker.pal b/graphics/trainers/palettes/dome_ace_tucker.pal deleted file mode 100644 index 33bb1aa68..000000000 --- a/graphics/trainers/palettes/dome_ace_tucker.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -246 148 230 -230 115 213 -189 90 172 -139 74 115 -213 205 246 -230 213 106 -156 148 197 -238 238 139 -213 180 98 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/dragon_tamer.pal b/graphics/trainers/palettes/dragon_tamer.pal deleted file mode 100644 index 545c55b74..000000000 --- a/graphics/trainers/palettes/dragon_tamer.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -74 57 49 -164 57 246 -123 49 172 -131 139 148 -255 98 90 -197 65 65 -213 222 230 -74 74 65 -255 205 106 -213 172 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/elite_four_drake.pal b/graphics/trainers/palettes/elite_four_drake.pal deleted file mode 100644 index 6ab0bae73..000000000 --- a/graphics/trainers/palettes/elite_four_drake.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -222 172 148 -164 131 106 -98 57 65 -139 131 164 -106 98 123 -41 49 57 -57 65 82 -197 197 213 -255 222 106 -189 156 90 -106 131 238 -65 106 172 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/elite_four_glacia.pal b/graphics/trainers/palettes/elite_four_glacia.pal deleted file mode 100644 index 75b5eb108..000000000 --- a/graphics/trainers/palettes/elite_four_glacia.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -115 82 65 -148 148 164 -148 90 164 -115 65 123 -82 41 82 -255 255 164 -213 197 90 -156 148 90 -222 230 238 -189 197 205 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/elite_four_phoebe.pal b/graphics/trainers/palettes/elite_four_phoebe.pal deleted file mode 100644 index 8c07c0d5b..000000000 --- a/graphics/trainers/palettes/elite_four_phoebe.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -115 82 65 -57 131 255 -32 106 230 -16 82 205 -41 49 123 -164 205 255 -115 98 106 -74 57 65 -255 82 156 -197 65 90 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/elite_four_sidney.pal b/graphics/trainers/palettes/elite_four_sidney.pal deleted file mode 100644 index d778e0ed6..000000000 --- a/graphics/trainers/palettes/elite_four_sidney.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -222 180 148 -189 139 106 -98 57 65 -131 106 74 -106 98 123 -41 49 57 -57 65 82 -197 197 213 -238 213 139 -197 164 106 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/expert_f.pal b/graphics/trainers/palettes/expert_f.pal deleted file mode 100644 index 2fa5f5202..000000000 --- a/graphics/trainers/palettes/expert_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 180 172 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -139 139 131 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/expert_m.pal b/graphics/trainers/palettes/expert_m.pal deleted file mode 100644 index 2fa5f5202..000000000 --- a/graphics/trainers/palettes/expert_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 180 172 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -139 139 131 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/factory_head_noland.pal b/graphics/trainers/palettes/factory_head_noland.pal deleted file mode 100644 index 03bce8c77..000000000 --- a/graphics/trainers/palettes/factory_head_noland.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -172 172 189 -131 131 164 -98 98 123 -65 65 90 -222 213 246 -238 213 106 -246 131 123 -213 90 90 -180 57 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/fisherman.pal b/graphics/trainers/palettes/fisherman.pal deleted file mode 100644 index 3c18e8f1f..000000000 --- a/graphics/trainers/palettes/fisherman.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 213 189 -222 172 148 -180 131 115 -82 57 57 -123 98 106 -82 82 123 -213 172 82 -180 139 82 -205 205 222 -123 82 49 -49 49 74 -246 123 49 -189 106 49 -238 238 255 -0 0 24 diff --git a/graphics/trainers/palettes/gentleman.pal b/graphics/trainers/palettes/gentleman.pal deleted file mode 100644 index ef021d026..000000000 --- a/graphics/trainers/palettes/gentleman.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -180 148 115 -148 115 82 -123 90 57 -65 49 41 -255 238 156 -213 213 205 -180 180 172 -90 106 172 -57 74 123 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/guitarist.pal b/graphics/trainers/palettes/guitarist.pal deleted file mode 100644 index 74e59e819..000000000 --- a/graphics/trainers/palettes/guitarist.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -172 172 164 -139 131 131 -106 98 98 -65 57 57 -255 238 156 -255 197 90 -205 180 148 -255 98 90 -189 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/hex_maniac.pal b/graphics/trainers/palettes/hex_maniac.pal deleted file mode 100644 index 549d7fac9..000000000 --- a/graphics/trainers/palettes/hex_maniac.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -164 123 156 -139 90 131 -106 65 106 -74 41 74 -213 222 230 -189 205 213 -205 57 82 -115 41 65 -180 49 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/hiker.pal b/graphics/trainers/palettes/hiker.pal deleted file mode 100644 index cb8fce7f6..000000000 --- a/graphics/trainers/palettes/hiker.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -222 164 148 -205 131 115 -74 65 57 -123 189 90 -115 148 90 -213 180 98 -172 148 98 -205 205 222 -148 148 148 -123 115 74 -230 98 90 -164 74 74 -255 255 255 -0 0 24 diff --git a/graphics/trainers/palettes/interviewer.pal b/graphics/trainers/palettes/interviewer.pal deleted file mode 100644 index 61ace1935..000000000 --- a/graphics/trainers/palettes/interviewer.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -148 148 172 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -98 197 255 -90 156 189 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/kindler.pal b/graphics/trainers/palettes/kindler.pal deleted file mode 100644 index af6adf7e8..000000000 --- a/graphics/trainers/palettes/kindler.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -115 82 65 -246 246 230 -222 222 189 -180 180 139 -123 115 74 -172 213 246 -115 180 205 -57 123 139 -255 82 57 -255 156 90 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/lady.pal b/graphics/trainers/palettes/lady.pal deleted file mode 100644 index b70873111..000000000 --- a/graphics/trainers/palettes/lady.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 222 -238 180 180 -156 123 106 -172 106 74 -82 82 32 -213 222 230 -255 230 106 -213 172 90 -222 98 123 -148 164 180 -180 238 106 -148 213 82 -123 189 65 -255 255 255 -0 0 24 diff --git a/graphics/trainers/palettes/lass.pal b/graphics/trainers/palettes/lass.pal deleted file mode 100644 index 89e78d683..000000000 --- a/graphics/trainers/palettes/lass.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -222 148 115 -123 90 82 -164 172 197 -90 98 148 -49 57 82 -41 57 98 -222 230 238 -255 197 90 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_brawly.pal b/graphics/trainers/palettes/leader_brawly.pal deleted file mode 100644 index 5a5a482f2..000000000 --- a/graphics/trainers/palettes/leader_brawly.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -49 49 74 -213 213 222 -255 164 197 -115 115 115 -255 139 65 -213 98 24 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_flannery.pal b/graphics/trainers/palettes/leader_flannery.pal deleted file mode 100644 index 20f2f8579..000000000 --- a/graphics/trainers/palettes/leader_flannery.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 197 230 -90 156 213 -65 115 164 -49 49 74 -213 213 222 -131 74 16 -115 115 115 -255 139 65 -197 98 32 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_juan.pal b/graphics/trainers/palettes/leader_juan.pal deleted file mode 100644 index 96467bdc3..000000000 --- a/graphics/trainers/palettes/leader_juan.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -222 180 148 -180 131 98 -123 90 82 -213 115 222 -148 65 180 -106 148 255 -82 106 189 -74 74 148 -164 180 189 -98 115 123 -98 49 90 -213 213 222 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_norman.pal b/graphics/trainers/palettes/leader_norman.pal deleted file mode 100644 index e53c16837..000000000 --- a/graphics/trainers/palettes/leader_norman.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 197 230 -139 156 172 -74 98 123 -49 65 82 -213 213 222 -131 16 41 -115 115 115 -213 82 90 -180 41 57 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_roxanne.pal b/graphics/trainers/palettes/leader_roxanne.pal deleted file mode 100644 index c2b28ead9..000000000 --- a/graphics/trainers/palettes/leader_roxanne.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 164 197 -189 156 90 -255 115 148 -213 82 115 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_tate_and_liza.pal b/graphics/trainers/palettes/leader_tate_and_liza.pal deleted file mode 100644 index ab64e9bea..000000000 --- a/graphics/trainers/palettes/leader_tate_and_liza.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 172 65 -255 222 205 -238 180 148 -180 131 106 -106 74 74 -189 189 197 -123 123 131 -74 82 98 -41 49 65 -255 98 90 -164 49 57 -255 197 90 -106 189 255 -90 139 197 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_wattson.pal b/graphics/trainers/palettes/leader_wattson.pal deleted file mode 100644 index c8a4e1420..000000000 --- a/graphics/trainers/palettes/leader_wattson.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -123 90 82 -164 139 90 -131 106 74 -139 131 106 -82 65 74 -213 213 222 -255 197 90 -189 156 90 -57 41 49 -222 115 131 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leader_winona.pal b/graphics/trainers/palettes/leader_winona.pal deleted file mode 100644 index 62783523b..000000000 --- a/graphics/trainers/palettes/leader_winona.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -172 189 213 -139 156 205 -74 98 148 -49 65 82 -205 213 222 -115 57 123 -255 197 90 -189 123 222 -148 90 172 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leaf.pal b/graphics/trainers/palettes/leaf.pal deleted file mode 100644 index 30e2cdde0..000000000 --- a/graphics/trainers/palettes/leaf.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 180 -230 189 156 -205 148 115 -123 90 82 -123 189 222 -82 139 180 -49 106 139 -24 41 82 -213 213 222 -255 197 90 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/leaf_back_pic.pal b/graphics/trainers/palettes/leaf_back_pic.pal deleted file mode 100644 index 27436be92..000000000 --- a/graphics/trainers/palettes/leaf_back_pic.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -172 123 65 -255 197 148 -222 148 115 -123 65 65 -65 65 213 -57 57 123 -115 164 197 -106 41 41 -238 238 255 -180 180 213 -255 106 74 -197 57 57 -255 222 90 -189 156 57 -0 0 0 diff --git a/graphics/trainers/palettes/magma_admin.pal b/graphics/trainers/palettes/magma_admin.pal deleted file mode 100644 index a987cdbc1..000000000 --- a/graphics/trainers/palettes/magma_admin.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -123 123 123 -90 90 90 -82 98 148 -57 57 65 -65 74 115 -139 49 65 -189 189 180 -222 82 98 -189 57 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/magma_grunt_f.pal b/graphics/trainers/palettes/magma_grunt_f.pal deleted file mode 100644 index a987cdbc1..000000000 --- a/graphics/trainers/palettes/magma_grunt_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -123 123 123 -90 90 90 -82 98 148 -57 57 65 -65 74 115 -139 49 65 -189 189 180 -222 82 98 -189 57 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/magma_grunt_m.pal b/graphics/trainers/palettes/magma_grunt_m.pal deleted file mode 100644 index a987cdbc1..000000000 --- a/graphics/trainers/palettes/magma_grunt_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -123 123 123 -90 90 90 -82 98 148 -57 57 65 -65 74 115 -139 49 65 -189 189 180 -222 82 98 -189 57 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/magma_leader_maxie.pal b/graphics/trainers/palettes/magma_leader_maxie.pal deleted file mode 100644 index 151bf6d5b..000000000 --- a/graphics/trainers/palettes/magma_leader_maxie.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -164 180 197 -115 123 139 -74 82 98 -49 57 82 -213 213 222 -131 16 41 -24 32 49 -213 82 90 -180 41 57 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/ruby_sapphire_may.pal b/graphics/trainers/palettes/may_rs.pal similarity index 100% rename from graphics/trainers/palettes/ruby_sapphire_may.pal rename to graphics/trainers/palettes/may_rs.pal diff --git a/graphics/trainers/palettes/ninja_boy.pal b/graphics/trainers/palettes/ninja_boy.pal deleted file mode 100644 index 524d3f4ba..000000000 --- a/graphics/trainers/palettes/ninja_boy.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 180 148 -213 148 115 -123 90 82 -164 180 197 -131 139 156 -82 98 115 -49 57 82 -213 213 222 -131 16 41 -255 172 32 -213 82 90 -180 41 57 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/old_couple.pal b/graphics/trainers/palettes/old_couple.pal deleted file mode 100644 index 2fa5f5202..000000000 --- a/graphics/trainers/palettes/old_couple.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 180 172 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -139 139 131 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/palace_maven_spenser.pal b/graphics/trainers/palettes/palace_maven_spenser.pal deleted file mode 100644 index 40a634974..000000000 --- a/graphics/trainers/palettes/palace_maven_spenser.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -230 205 156 -189 164 115 -164 131 82 -106 74 74 -172 172 213 -123 131 189 -90 98 148 -57 65 90 -222 213 246 -238 213 106 -246 230 180 -230 115 74 -222 180 98 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/parasol_lady.pal b/graphics/trainers/palettes/parasol_lady.pal deleted file mode 100644 index dc5c6f67f..000000000 --- a/graphics/trainers/palettes/parasol_lady.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -123 82 65 -90 131 189 -65 90 139 -41 65 98 -255 98 90 -197 65 65 -255 156 106 -131 74 65 -255 205 106 -213 172 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/picnicker.pal b/graphics/trainers/palettes/picnicker.pal deleted file mode 100644 index acd90e943..000000000 --- a/graphics/trainers/palettes/picnicker.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -246 205 156 -205 156 115 -115 82 65 -131 213 205 -82 164 148 -180 189 222 -57 90 74 -24 49 90 -98 115 230 -57 82 131 -255 98 41 -189 74 41 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pike_queen_lucy.pal b/graphics/trainers/palettes/pike_queen_lucy.pal deleted file mode 100644 index fd3b46b8b..000000000 --- a/graphics/trainers/palettes/pike_queen_lucy.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -205 123 213 -148 90 148 -115 57 106 -57 57 57 -213 222 230 -172 65 65 -255 197 90 -115 106 123 -213 82 115 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokefan_f.pal b/graphics/trainers/palettes/pokefan_f.pal deleted file mode 100644 index 09728f005..000000000 --- a/graphics/trainers/palettes/pokefan_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 172 189 -65 123 180 -255 0 255 -32 57 82 -197 205 213 -180 139 90 -131 90 41 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokefan_m.pal b/graphics/trainers/palettes/pokefan_m.pal deleted file mode 100644 index 1d1f48875..000000000 --- a/graphics/trainers/palettes/pokefan_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -222 189 148 -197 156 115 -156 123 82 -49 57 49 -230 90 41 -131 172 222 -172 49 32 -82 123 172 -255 238 74 -213 189 41 -205 205 213 -98 98 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokemaniac.pal b/graphics/trainers/palettes/pokemaniac.pal deleted file mode 100644 index 3ede03b14..000000000 --- a/graphics/trainers/palettes/pokemaniac.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -246 205 156 -205 156 115 -115 82 65 -246 189 115 -213 123 74 -180 82 74 -139 57 41 -74 74 49 -255 230 57 -98 123 106 -230 82 24 -213 205 230 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokemon_breeder_f.pal b/graphics/trainers/palettes/pokemon_breeder_f.pal deleted file mode 100644 index b15f5db8a..000000000 --- a/graphics/trainers/palettes/pokemon_breeder_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -255 98 90 -164 49 65 -255 148 131 -49 49 74 -213 222 230 -205 74 74 -115 148 197 -49 74 123 -57 115 164 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokemon_breeder_m.pal b/graphics/trainers/palettes/pokemon_breeder_m.pal deleted file mode 100644 index 6551f8482..000000000 --- a/graphics/trainers/palettes/pokemon_breeder_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -131 90 74 -255 98 90 -156 65 74 -255 148 131 -49 49 74 -213 222 230 -205 74 74 -115 148 197 -49 74 123 -57 115 164 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokemon_ranger_f.pal b/graphics/trainers/palettes/pokemon_ranger_f.pal deleted file mode 100644 index 93220f5cb..000000000 --- a/graphics/trainers/palettes/pokemon_ranger_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -131 90 65 -82 49 49 -131 139 156 -82 90 115 -49 57 82 -213 213 222 -255 205 65 -255 131 74 -205 98 74 -156 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pokemon_ranger_m.pal b/graphics/trainers/palettes/pokemon_ranger_m.pal deleted file mode 100644 index 2f16ca0cb..000000000 --- a/graphics/trainers/palettes/pokemon_ranger_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -139 106 82 -82 49 49 -131 139 156 -90 98 115 -49 57 82 -213 213 222 -255 205 65 -238 139 82 -197 82 74 -115 57 49 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/psychic_f.pal b/graphics/trainers/palettes/psychic_f.pal deleted file mode 100644 index 232cfd755..000000000 --- a/graphics/trainers/palettes/psychic_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -246 205 156 -205 156 115 -115 82 65 -98 123 180 -32 98 131 -255 0 246 -41 57 90 -213 131 255 -156 115 180 -115 82 148 -246 139 90 -197 90 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/psychic_m.pal b/graphics/trainers/palettes/psychic_m.pal deleted file mode 100644 index 0ddd2894b..000000000 --- a/graphics/trainers/palettes/psychic_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -230 189 148 -205 156 115 -115 82 65 -98 123 180 -32 98 131 -0 255 0 -41 57 90 -213 131 255 -131 106 172 -90 74 131 -246 139 90 -197 90 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/pyramid_king_brandon.pal b/graphics/trainers/palettes/pyramid_king_brandon.pal deleted file mode 100644 index 77b5483b8..000000000 --- a/graphics/trainers/palettes/pyramid_king_brandon.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -164 213 90 -123 172 65 -82 115 41 -57 82 41 -213 205 213 -172 123 90 -139 139 123 -131 98 65 -213 106 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/red.pal b/graphics/trainers/palettes/red.pal deleted file mode 100644 index 30e2cdde0..000000000 --- a/graphics/trainers/palettes/red.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 180 -230 189 156 -205 148 115 -123 90 82 -123 189 222 -82 139 180 -49 106 139 -24 41 82 -213 213 222 -255 197 90 -189 156 90 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/red_back_pic.pal b/graphics/trainers/palettes/red_back_pic.pal deleted file mode 100644 index 3097a6556..000000000 --- a/graphics/trainers/palettes/red_back_pic.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -131 123 164 -172 123 65 -255 197 148 -222 148 115 -123 65 65 -65 65 213 -57 57 123 -115 164 197 -106 41 41 -238 238 255 -180 180 213 -255 106 74 -197 57 57 -255 222 90 -189 156 57 -0 0 0 diff --git a/graphics/trainers/palettes/rich_boy.pal b/graphics/trainers/palettes/rich_boy.pal deleted file mode 100644 index 1ebb77204..000000000 --- a/graphics/trainers/palettes/rich_boy.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -213 222 230 -255 230 98 -222 180 90 -156 123 115 -115 82 90 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/ruin_maniac.pal b/graphics/trainers/palettes/ruin_maniac.pal deleted file mode 100644 index bbc342a06..000000000 --- a/graphics/trainers/palettes/ruin_maniac.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -255 238 106 -246 246 230 -222 222 189 -180 180 139 -115 106 65 -222 213 246 -115 131 205 -222 189 8 -213 115 139 -172 74 90 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/running_triathlete_f.pal b/graphics/trainers/palettes/running_triathlete_f.pal deleted file mode 100644 index 671c1593f..000000000 --- a/graphics/trainers/palettes/running_triathlete_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -180 139 90 -139 65 65 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/running_triathlete_m.pal b/graphics/trainers/palettes/running_triathlete_m.pal deleted file mode 100644 index 13a56a556..000000000 --- a/graphics/trainers/palettes/running_triathlete_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -246 205 180 -230 180 148 -180 139 106 -115 82 65 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -180 139 90 -139 65 65 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/sailor.pal b/graphics/trainers/palettes/sailor.pal deleted file mode 100644 index 3b6248576..000000000 --- a/graphics/trainers/palettes/sailor.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -180 180 172 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -139 139 131 -131 180 230 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/salon_maiden_anabel.pal b/graphics/trainers/palettes/salon_maiden_anabel.pal deleted file mode 100644 index 91776562f..000000000 --- a/graphics/trainers/palettes/salon_maiden_anabel.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -230 139 255 -189 115 213 -148 90 172 -123 74 139 -213 205 246 -255 197 90 -156 148 197 -255 222 115 -213 106 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/school_kid_f.pal b/graphics/trainers/palettes/school_kid_f.pal deleted file mode 100644 index ce758377a..000000000 --- a/graphics/trainers/palettes/school_kid_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 230 205 -238 189 156 -205 148 115 -106 74 57 -255 139 164 -213 82 131 -131 139 255 -98 115 180 -57 74 131 -246 189 123 -197 131 65 -230 82 41 -139 90 32 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/school_kid_m.pal b/graphics/trainers/palettes/school_kid_m.pal deleted file mode 100644 index dc4298ea0..000000000 --- a/graphics/trainers/palettes/school_kid_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 180 148 -213 148 115 -123 90 82 -172 164 115 -65 90 148 -49 57 82 -131 123 82 -197 197 238 -255 222 65 -205 189 123 -98 164 222 -49 123 156 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/sis_and_bro.pal b/graphics/trainers/palettes/sis_and_bro.pal deleted file mode 100644 index 823ef66ef..000000000 --- a/graphics/trainers/palettes/sis_and_bro.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -246 205 189 -222 164 148 -164 123 98 -74 57 49 -255 139 90 -230 82 74 -180 65 65 -90 65 82 -197 65 65 -213 222 230 -255 230 205 -139 172 213 -90 131 189 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/sr_and_jr.pal b/graphics/trainers/palettes/sr_and_jr.pal deleted file mode 100644 index 72238881f..000000000 --- a/graphics/trainers/palettes/sr_and_jr.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -180 139 90 -131 90 41 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/swimmer_f.pal b/graphics/trainers/palettes/swimmer_f.pal deleted file mode 100644 index 823ef66ef..000000000 --- a/graphics/trainers/palettes/swimmer_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -246 205 189 -222 164 148 -164 123 98 -74 57 49 -255 139 90 -230 82 74 -180 65 65 -90 65 82 -197 65 65 -213 222 230 -255 230 205 -139 172 213 -90 131 189 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/swimmer_m.pal b/graphics/trainers/palettes/swimmer_m.pal deleted file mode 100644 index 259a53b9a..000000000 --- a/graphics/trainers/palettes/swimmer_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -230 197 172 -213 172 148 -172 123 106 -115 82 65 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -172 172 180 -139 65 65 -222 238 238 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/swimming_triathlete_f.pal b/graphics/trainers/palettes/swimming_triathlete_f.pal deleted file mode 100644 index 671c1593f..000000000 --- a/graphics/trainers/palettes/swimming_triathlete_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -180 139 90 -139 65 65 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/swimming_triathlete_m.pal b/graphics/trainers/palettes/swimming_triathlete_m.pal deleted file mode 100644 index 671c1593f..000000000 --- a/graphics/trainers/palettes/swimming_triathlete_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -90 131 189 -65 90 139 -41 65 98 -49 41 65 -205 213 222 -180 139 90 -139 65 65 -255 98 90 -197 65 65 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/tuber_f.pal b/graphics/trainers/palettes/tuber_f.pal deleted file mode 100644 index b5cb0047a..000000000 --- a/graphics/trainers/palettes/tuber_f.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 230 74 -205 57 82 -238 180 57 -189 131 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/tuber_m.pal b/graphics/trainers/palettes/tuber_m.pal deleted file mode 100644 index b5cb0047a..000000000 --- a/graphics/trainers/palettes/tuber_m.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 230 74 -205 57 82 -238 180 57 -189 131 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/twins.pal b/graphics/trainers/palettes/twins.pal deleted file mode 100644 index 3b162de25..000000000 --- a/graphics/trainers/palettes/twins.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -106 74 74 -139 172 213 -90 131 189 -65 90 139 -57 57 57 -213 222 230 -255 230 74 -180 82 98 -238 180 57 -189 131 74 -255 255 255 -0 0 0 diff --git a/graphics/trainers/palettes/young_couple.pal b/graphics/trainers/palettes/young_couple.pal deleted file mode 100644 index bba95c19a..000000000 --- a/graphics/trainers/palettes/young_couple.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -238 180 148 -197 139 106 -98 65 57 -148 164 172 -82 123 164 -57 82 106 -32 49 74 -205 213 222 -123 197 156 -90 164 131 -255 98 90 -197 65 65 -106 106 139 -0 0 0 diff --git a/graphics/trainers/palettes/youngster.pal b/graphics/trainers/palettes/youngster.pal deleted file mode 100644 index f91520d9b..000000000 --- a/graphics/trainers/palettes/youngster.pal +++ /dev/null @@ -1,19 +0,0 @@ -JASC-PAL -0100 -16 -115 197 164 -255 222 205 -230 180 148 -213 148 115 -123 90 82 -139 197 222 -65 90 148 -49 57 82 -41 57 98 -197 197 238 -255 222 65 -222 172 90 -98 164 222 -49 123 156 -255 255 255 -0 0 0 diff --git a/src/data/graphics/trainers.h b/src/data/graphics/trainers.h index 206d73a88..fbdea7472 100644 --- a/src/data/graphics/trainers.h +++ b/src/data/graphics/trainers.h @@ -1,290 +1,290 @@ -const u32 gTrainerFrontPic_Hiker[] = INCBIN_U32("graphics/trainers/front_pics/hiker_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Hiker[] = INCBIN_U32("graphics/trainers/palettes/hiker.gbapal.lz"); +const u32 gTrainerFrontPic_Hiker[] = INCBIN_U32("graphics/trainers/front_pics/hiker.4bpp.lz"); +const u32 gTrainerPalette_Hiker[] = INCBIN_U32("graphics/trainers/front_pics/hiker.gbapal.lz"); -const u32 gTrainerFrontPic_AquaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AquaGruntM[] = INCBIN_U32("graphics/trainers/palettes/aqua_grunt_m.gbapal.lz"); +const u32 gTrainerFrontPic_AquaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_m.4bpp.lz"); +const u32 gTrainerPalette_AquaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_m.gbapal.lz"); -const u32 gTrainerFrontPic_PokemonBreederF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokemonBreederF[] = INCBIN_U32("graphics/trainers/palettes/pokemon_breeder_f.gbapal.lz"); +const u32 gTrainerFrontPic_PokemonBreederF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_f.4bpp.lz"); +const u32 gTrainerPalette_PokemonBreederF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_f.gbapal.lz"); -const u32 gTrainerFrontPic_CoolTrainerM[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_CoolTrainerM[] = INCBIN_U32("graphics/trainers/palettes/cooltrainer_m.gbapal.lz"); +const u32 gTrainerFrontPic_CoolTrainerM[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_m.4bpp.lz"); +const u32 gTrainerPalette_CoolTrainerM[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_m.gbapal.lz"); -const u32 gTrainerFrontPic_BirdKeeper[] = INCBIN_U32("graphics/trainers/front_pics/bird_keeper_front_pic.4bpp.lz"); -const u32 gTrainerPalette_BirdKeeper[] = INCBIN_U32("graphics/trainers/palettes/bird_keeper.gbapal.lz"); +const u32 gTrainerFrontPic_BirdKeeper[] = INCBIN_U32("graphics/trainers/front_pics/bird_keeper.4bpp.lz"); +const u32 gTrainerPalette_BirdKeeper[] = INCBIN_U32("graphics/trainers/front_pics/bird_keeper.gbapal.lz"); -const u32 gTrainerFrontPic_Collector[] = INCBIN_U32("graphics/trainers/front_pics/collector_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Collector[] = INCBIN_U32("graphics/trainers/palettes/collector.gbapal.lz"); +const u32 gTrainerFrontPic_Collector[] = INCBIN_U32("graphics/trainers/front_pics/collector.4bpp.lz"); +const u32 gTrainerPalette_Collector[] = INCBIN_U32("graphics/trainers/front_pics/collector.gbapal.lz"); -const u32 gTrainerFrontPic_AquaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AquaGruntF[] = INCBIN_U32("graphics/trainers/palettes/aqua_grunt_f.gbapal.lz"); +const u32 gTrainerFrontPic_AquaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_f.4bpp.lz"); +const u32 gTrainerPalette_AquaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_grunt_f.gbapal.lz"); -const u32 gTrainerFrontPic_SwimmerM[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SwimmerM[] = INCBIN_U32("graphics/trainers/palettes/swimmer_m.gbapal.lz"); +const u32 gTrainerFrontPic_SwimmerM[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_m.4bpp.lz"); +const u32 gTrainerPalette_SwimmerM[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_m.gbapal.lz"); -const u32 gTrainerFrontPic_MagmaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_MagmaGruntM[] = INCBIN_U32("graphics/trainers/palettes/magma_grunt_m.gbapal.lz"); +const u32 gTrainerFrontPic_MagmaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_m.4bpp.lz"); +const u32 gTrainerPalette_MagmaGruntM[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_m.gbapal.lz"); -const u32 gTrainerFrontPic_ExpertM[] = INCBIN_U32("graphics/trainers/front_pics/expert_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_ExpertM[] = INCBIN_U32("graphics/trainers/palettes/expert_m.gbapal.lz"); +const u32 gTrainerFrontPic_ExpertM[] = INCBIN_U32("graphics/trainers/front_pics/expert_m.4bpp.lz"); +const u32 gTrainerPalette_ExpertM[] = INCBIN_U32("graphics/trainers/front_pics/expert_m.gbapal.lz"); -const u32 gTrainerFrontPic_AquaAdminM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AquaAdminM[] = INCBIN_U32("graphics/trainers/palettes/aqua_admin_m.gbapal.lz"); +const u32 gTrainerFrontPic_AquaAdminM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_m.4bpp.lz"); +const u32 gTrainerPalette_AquaAdminM[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_m.gbapal.lz"); -const u32 gTrainerFrontPic_BlackBelt[] = INCBIN_U32("graphics/trainers/front_pics/black_belt_front_pic.4bpp.lz"); -const u32 gTrainerPalette_BlackBelt[] = INCBIN_U32("graphics/trainers/palettes/black_belt.gbapal.lz"); +const u32 gTrainerFrontPic_BlackBelt[] = INCBIN_U32("graphics/trainers/front_pics/black_belt.4bpp.lz"); +const u32 gTrainerPalette_BlackBelt[] = INCBIN_U32("graphics/trainers/front_pics/black_belt.gbapal.lz"); -const u32 gTrainerFrontPic_AquaAdminF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AquaAdminF[] = INCBIN_U32("graphics/trainers/palettes/aqua_admin_f.gbapal.lz"); +const u32 gTrainerFrontPic_AquaAdminF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_f.4bpp.lz"); +const u32 gTrainerPalette_AquaAdminF[] = INCBIN_U32("graphics/trainers/front_pics/aqua_admin_f.gbapal.lz"); -const u32 gTrainerFrontPic_AquaLeaderArchie[] = INCBIN_U32("graphics/trainers/front_pics/aqua_leader_archie_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AquaLeaderArchie[] = INCBIN_U32("graphics/trainers/palettes/aqua_leader_archie.gbapal.lz"); +const u32 gTrainerFrontPic_AquaLeaderArchie[] = INCBIN_U32("graphics/trainers/front_pics/aqua_leader_archie.4bpp.lz"); +const u32 gTrainerPalette_AquaLeaderArchie[] = INCBIN_U32("graphics/trainers/front_pics/aqua_leader_archie.gbapal.lz"); -const u32 gTrainerFrontPic_HexManiac[] = INCBIN_U32("graphics/trainers/front_pics/hex_maniac_front_pic.4bpp.lz"); -const u32 gTrainerPalette_HexManiac[] = INCBIN_U32("graphics/trainers/palettes/hex_maniac.gbapal.lz"); +const u32 gTrainerFrontPic_HexManiac[] = INCBIN_U32("graphics/trainers/front_pics/hex_maniac.4bpp.lz"); +const u32 gTrainerPalette_HexManiac[] = INCBIN_U32("graphics/trainers/front_pics/hex_maniac.gbapal.lz"); -const u32 gTrainerFrontPic_AromaLady[] = INCBIN_U32("graphics/trainers/front_pics/aroma_lady_front_pic.4bpp.lz"); -const u32 gTrainerPalette_AromaLady[] = INCBIN_U32("graphics/trainers/palettes/aroma_lady.gbapal.lz"); +const u32 gTrainerFrontPic_AromaLady[] = INCBIN_U32("graphics/trainers/front_pics/aroma_lady.4bpp.lz"); +const u32 gTrainerPalette_AromaLady[] = INCBIN_U32("graphics/trainers/front_pics/aroma_lady.gbapal.lz"); -const u32 gTrainerFrontPic_RuinManiac[] = INCBIN_U32("graphics/trainers/front_pics/ruin_maniac_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RuinManiac[] = INCBIN_U32("graphics/trainers/palettes/ruin_maniac.gbapal.lz"); +const u32 gTrainerFrontPic_RuinManiac[] = INCBIN_U32("graphics/trainers/front_pics/ruin_maniac.4bpp.lz"); +const u32 gTrainerPalette_RuinManiac[] = INCBIN_U32("graphics/trainers/front_pics/ruin_maniac.gbapal.lz"); -const u32 gTrainerFrontPic_Interviewer[] = INCBIN_U32("graphics/trainers/front_pics/interviewer_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Interviewer[] = INCBIN_U32("graphics/trainers/palettes/interviewer.gbapal.lz"); +const u32 gTrainerFrontPic_Interviewer[] = INCBIN_U32("graphics/trainers/front_pics/interviewer.4bpp.lz"); +const u32 gTrainerPalette_Interviewer[] = INCBIN_U32("graphics/trainers/front_pics/interviewer.gbapal.lz"); -const u32 gTrainerFrontPic_TuberF[] = INCBIN_U32("graphics/trainers/front_pics/tuber_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_TuberF[] = INCBIN_U32("graphics/trainers/palettes/tuber_f.gbapal.lz"); +const u32 gTrainerFrontPic_TuberF[] = INCBIN_U32("graphics/trainers/front_pics/tuber_f.4bpp.lz"); +const u32 gTrainerPalette_TuberF[] = INCBIN_U32("graphics/trainers/front_pics/tuber_f.gbapal.lz"); -const u32 gTrainerFrontPic_TuberM[] = INCBIN_U32("graphics/trainers/front_pics/tuber_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_TuberM[] = INCBIN_U32("graphics/trainers/palettes/tuber_m.gbapal.lz"); +const u32 gTrainerFrontPic_TuberM[] = INCBIN_U32("graphics/trainers/front_pics/tuber_m.4bpp.lz"); +const u32 gTrainerPalette_TuberM[] = INCBIN_U32("graphics/trainers/front_pics/tuber_m.gbapal.lz"); -const u32 gTrainerFrontPic_CoolTrainerF[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_CoolTrainerF[] = INCBIN_U32("graphics/trainers/palettes/cooltrainer_f.gbapal.lz"); +const u32 gTrainerFrontPic_CoolTrainerF[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_f.4bpp.lz"); +const u32 gTrainerPalette_CoolTrainerF[] = INCBIN_U32("graphics/trainers/front_pics/cooltrainer_f.gbapal.lz"); -const u32 gTrainerFrontPic_Lady[] = INCBIN_U32("graphics/trainers/front_pics/lady_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Lady[] = INCBIN_U32("graphics/trainers/palettes/lady.gbapal.lz"); +const u32 gTrainerFrontPic_Lady[] = INCBIN_U32("graphics/trainers/front_pics/lady.4bpp.lz"); +const u32 gTrainerPalette_Lady[] = INCBIN_U32("graphics/trainers/front_pics/lady.gbapal.lz"); -const u32 gTrainerFrontPic_Beauty[] = INCBIN_U32("graphics/trainers/front_pics/beauty_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Beauty[] = INCBIN_U32("graphics/trainers/palettes/beauty.gbapal.lz"); +const u32 gTrainerFrontPic_Beauty[] = INCBIN_U32("graphics/trainers/front_pics/beauty.4bpp.lz"); +const u32 gTrainerPalette_Beauty[] = INCBIN_U32("graphics/trainers/front_pics/beauty.gbapal.lz"); -const u32 gTrainerFrontPic_RichBoy[] = INCBIN_U32("graphics/trainers/front_pics/rich_boy_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RichBoy[] = INCBIN_U32("graphics/trainers/palettes/rich_boy.gbapal.lz"); +const u32 gTrainerFrontPic_RichBoy[] = INCBIN_U32("graphics/trainers/front_pics/rich_boy.4bpp.lz"); +const u32 gTrainerPalette_RichBoy[] = INCBIN_U32("graphics/trainers/front_pics/rich_boy.gbapal.lz"); -const u32 gTrainerFrontPic_ExpertF[] = INCBIN_U32("graphics/trainers/front_pics/expert_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_ExpertF[] = INCBIN_U32("graphics/trainers/palettes/expert_f.gbapal.lz"); +const u32 gTrainerFrontPic_ExpertF[] = INCBIN_U32("graphics/trainers/front_pics/expert_f.4bpp.lz"); +const u32 gTrainerPalette_ExpertF[] = INCBIN_U32("graphics/trainers/front_pics/expert_f.gbapal.lz"); -const u32 gTrainerFrontPic_Pokemaniac[] = INCBIN_U32("graphics/trainers/front_pics/pokemaniac_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Pokemaniac[] = INCBIN_U32("graphics/trainers/palettes/pokemaniac.gbapal.lz"); +const u32 gTrainerFrontPic_Pokemaniac[] = INCBIN_U32("graphics/trainers/front_pics/pokemaniac.4bpp.lz"); +const u32 gTrainerPalette_Pokemaniac[] = INCBIN_U32("graphics/trainers/front_pics/pokemaniac.gbapal.lz"); -const u32 gTrainerFrontPic_MagmaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_MagmaGruntF[] = INCBIN_U32("graphics/trainers/palettes/magma_grunt_f.gbapal.lz"); +const u32 gTrainerFrontPic_MagmaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_f.4bpp.lz"); +const u32 gTrainerPalette_MagmaGruntF[] = INCBIN_U32("graphics/trainers/front_pics/magma_grunt_f.gbapal.lz"); -const u32 gTrainerFrontPic_Guitarist[] = INCBIN_U32("graphics/trainers/front_pics/guitarist_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Guitarist[] = INCBIN_U32("graphics/trainers/palettes/guitarist.gbapal.lz"); +const u32 gTrainerFrontPic_Guitarist[] = INCBIN_U32("graphics/trainers/front_pics/guitarist.4bpp.lz"); +const u32 gTrainerPalette_Guitarist[] = INCBIN_U32("graphics/trainers/front_pics/guitarist.gbapal.lz"); -const u32 gTrainerFrontPic_Kindler[] = INCBIN_U32("graphics/trainers/front_pics/kindler_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Kindler[] = INCBIN_U32("graphics/trainers/palettes/kindler.gbapal.lz"); +const u32 gTrainerFrontPic_Kindler[] = INCBIN_U32("graphics/trainers/front_pics/kindler.4bpp.lz"); +const u32 gTrainerPalette_Kindler[] = INCBIN_U32("graphics/trainers/front_pics/kindler.gbapal.lz"); -const u32 gTrainerFrontPic_Camper[] = INCBIN_U32("graphics/trainers/front_pics/camper_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Camper[] = INCBIN_U32("graphics/trainers/palettes/camper.gbapal.lz"); +const u32 gTrainerFrontPic_Camper[] = INCBIN_U32("graphics/trainers/front_pics/camper.4bpp.lz"); +const u32 gTrainerPalette_Camper[] = INCBIN_U32("graphics/trainers/front_pics/camper.gbapal.lz"); -const u32 gTrainerFrontPic_Picnicker[] = INCBIN_U32("graphics/trainers/front_pics/picnicker_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Picnicker[] = INCBIN_U32("graphics/trainers/palettes/picnicker.gbapal.lz"); +const u32 gTrainerFrontPic_Picnicker[] = INCBIN_U32("graphics/trainers/front_pics/picnicker.4bpp.lz"); +const u32 gTrainerPalette_Picnicker[] = INCBIN_U32("graphics/trainers/front_pics/picnicker.gbapal.lz"); -const u32 gTrainerFrontPic_BugManiac[] = INCBIN_U32("graphics/trainers/front_pics/bug_maniac_front_pic.4bpp.lz"); -const u32 gTrainerPalette_BugManiac[] = INCBIN_U32("graphics/trainers/palettes/bug_maniac.gbapal.lz"); +const u32 gTrainerFrontPic_BugManiac[] = INCBIN_U32("graphics/trainers/front_pics/bug_maniac.4bpp.lz"); +const u32 gTrainerPalette_BugManiac[] = INCBIN_U32("graphics/trainers/front_pics/bug_maniac.gbapal.lz"); -const u32 gTrainerFrontPic_PokemonBreederM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokemonBreederM[] = INCBIN_U32("graphics/trainers/palettes/pokemon_breeder_m.gbapal.lz"); +const u32 gTrainerFrontPic_PokemonBreederM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_m.4bpp.lz"); +const u32 gTrainerPalette_PokemonBreederM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_breeder_m.gbapal.lz"); -const u32 gTrainerFrontPic_PsychicM[] = INCBIN_U32("graphics/trainers/front_pics/psychic_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PsychicM[] = INCBIN_U32("graphics/trainers/palettes/psychic_m.gbapal.lz"); +const u32 gTrainerFrontPic_PsychicM[] = INCBIN_U32("graphics/trainers/front_pics/psychic_m.4bpp.lz"); +const u32 gTrainerPalette_PsychicM[] = INCBIN_U32("graphics/trainers/front_pics/psychic_m.gbapal.lz"); -const u32 gTrainerFrontPic_PsychicF[] = INCBIN_U32("graphics/trainers/front_pics/psychic_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PsychicF[] = INCBIN_U32("graphics/trainers/palettes/psychic_f.gbapal.lz"); +const u32 gTrainerFrontPic_PsychicF[] = INCBIN_U32("graphics/trainers/front_pics/psychic_f.4bpp.lz"); +const u32 gTrainerPalette_PsychicF[] = INCBIN_U32("graphics/trainers/front_pics/psychic_f.gbapal.lz"); -const u32 gTrainerFrontPic_Gentleman[] = INCBIN_U32("graphics/trainers/front_pics/gentleman_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Gentleman[] = INCBIN_U32("graphics/trainers/palettes/gentleman.gbapal.lz"); +const u32 gTrainerFrontPic_Gentleman[] = INCBIN_U32("graphics/trainers/front_pics/gentleman.4bpp.lz"); +const u32 gTrainerPalette_Gentleman[] = INCBIN_U32("graphics/trainers/front_pics/gentleman.gbapal.lz"); -const u32 gTrainerFrontPic_EliteFourSidney[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_sidney_front_pic.4bpp.lz"); -const u32 gTrainerPalette_EliteFourSidney[] = INCBIN_U32("graphics/trainers/palettes/elite_four_sidney.gbapal.lz"); +const u32 gTrainerFrontPic_EliteFourSidney[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_sidney.4bpp.lz"); +const u32 gTrainerPalette_EliteFourSidney[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_sidney.gbapal.lz"); -const u32 gTrainerFrontPic_EliteFourPhoebe[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_phoebe_front_pic.4bpp.lz"); -const u32 gTrainerPalette_EliteFourPhoebe[] = INCBIN_U32("graphics/trainers/palettes/elite_four_phoebe.gbapal.lz"); +const u32 gTrainerFrontPic_EliteFourPhoebe[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_phoebe.4bpp.lz"); +const u32 gTrainerPalette_EliteFourPhoebe[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_phoebe.gbapal.lz"); -const u32 gTrainerFrontPic_EliteFourGlacia[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_glacia_front_pic.4bpp.lz"); -const u32 gTrainerPalette_EliteFourGlacia[] = INCBIN_U32("graphics/trainers/palettes/elite_four_glacia.gbapal.lz"); +const u32 gTrainerFrontPic_EliteFourGlacia[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_glacia.4bpp.lz"); +const u32 gTrainerPalette_EliteFourGlacia[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_glacia.gbapal.lz"); -const u32 gTrainerFrontPic_EliteFourDrake[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_drake_front_pic.4bpp.lz"); -const u32 gTrainerPalette_EliteFourDrake[] = INCBIN_U32("graphics/trainers/palettes/elite_four_drake.gbapal.lz"); +const u32 gTrainerFrontPic_EliteFourDrake[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_drake.4bpp.lz"); +const u32 gTrainerPalette_EliteFourDrake[] = INCBIN_U32("graphics/trainers/front_pics/elite_four_drake.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderRoxanne[] = INCBIN_U32("graphics/trainers/front_pics/leader_roxanne_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderRoxanne[] = INCBIN_U32("graphics/trainers/palettes/leader_roxanne.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderRoxanne[] = INCBIN_U32("graphics/trainers/front_pics/leader_roxanne.4bpp.lz"); +const u32 gTrainerPalette_LeaderRoxanne[] = INCBIN_U32("graphics/trainers/front_pics/leader_roxanne.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderBrawly[] = INCBIN_U32("graphics/trainers/front_pics/leader_brawly_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderBrawly[] = INCBIN_U32("graphics/trainers/palettes/leader_brawly.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderBrawly[] = INCBIN_U32("graphics/trainers/front_pics/leader_brawly.4bpp.lz"); +const u32 gTrainerPalette_LeaderBrawly[] = INCBIN_U32("graphics/trainers/front_pics/leader_brawly.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderWattson[] = INCBIN_U32("graphics/trainers/front_pics/leader_wattson_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderWattson[] = INCBIN_U32("graphics/trainers/palettes/leader_wattson.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderWattson[] = INCBIN_U32("graphics/trainers/front_pics/leader_wattson.4bpp.lz"); +const u32 gTrainerPalette_LeaderWattson[] = INCBIN_U32("graphics/trainers/front_pics/leader_wattson.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderFlannery[] = INCBIN_U32("graphics/trainers/front_pics/leader_flannery_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderFlannery[] = INCBIN_U32("graphics/trainers/palettes/leader_flannery.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderFlannery[] = INCBIN_U32("graphics/trainers/front_pics/leader_flannery.4bpp.lz"); +const u32 gTrainerPalette_LeaderFlannery[] = INCBIN_U32("graphics/trainers/front_pics/leader_flannery.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderNorman[] = INCBIN_U32("graphics/trainers/front_pics/leader_norman_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderNorman[] = INCBIN_U32("graphics/trainers/palettes/leader_norman.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderNorman[] = INCBIN_U32("graphics/trainers/front_pics/leader_norman.4bpp.lz"); +const u32 gTrainerPalette_LeaderNorman[] = INCBIN_U32("graphics/trainers/front_pics/leader_norman.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderWinona[] = INCBIN_U32("graphics/trainers/front_pics/leader_winona_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderWinona[] = INCBIN_U32("graphics/trainers/palettes/leader_winona.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderWinona[] = INCBIN_U32("graphics/trainers/front_pics/leader_winona.4bpp.lz"); +const u32 gTrainerPalette_LeaderWinona[] = INCBIN_U32("graphics/trainers/front_pics/leader_winona.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderTateAndLiza[] = INCBIN_U32("graphics/trainers/front_pics/leader_tate_and_liza_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderTateAndLiza[] = INCBIN_U32("graphics/trainers/palettes/leader_tate_and_liza.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderTateAndLiza[] = INCBIN_U32("graphics/trainers/front_pics/leader_tate_and_liza.4bpp.lz"); +const u32 gTrainerPalette_LeaderTateAndLiza[] = INCBIN_U32("graphics/trainers/front_pics/leader_tate_and_liza.gbapal.lz"); -const u32 gTrainerFrontPic_LeaderJuan[] = INCBIN_U32("graphics/trainers/front_pics/leader_juan_front_pic.4bpp.lz"); -const u32 gTrainerPalette_LeaderJuan[] = INCBIN_U32("graphics/trainers/palettes/leader_juan.gbapal.lz"); +const u32 gTrainerFrontPic_LeaderJuan[] = INCBIN_U32("graphics/trainers/front_pics/leader_juan.4bpp.lz"); +const u32 gTrainerPalette_LeaderJuan[] = INCBIN_U32("graphics/trainers/front_pics/leader_juan.gbapal.lz"); -const u32 gTrainerFrontPic_SchoolKidM[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SchoolKidM[] = INCBIN_U32("graphics/trainers/palettes/school_kid_m.gbapal.lz"); +const u32 gTrainerFrontPic_SchoolKidM[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_m.4bpp.lz"); +const u32 gTrainerPalette_SchoolKidM[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_m.gbapal.lz"); -const u32 gTrainerFrontPic_SchoolKidF[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SchoolKidF[] = INCBIN_U32("graphics/trainers/palettes/school_kid_f.gbapal.lz"); +const u32 gTrainerFrontPic_SchoolKidF[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_f.4bpp.lz"); +const u32 gTrainerPalette_SchoolKidF[] = INCBIN_U32("graphics/trainers/front_pics/school_kid_f.gbapal.lz"); -const u32 gTrainerFrontPic_SrAndJr[] = INCBIN_U32("graphics/trainers/front_pics/sr_and_jr_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SrAndJr[] = INCBIN_U32("graphics/trainers/palettes/sr_and_jr.gbapal.lz"); +const u32 gTrainerFrontPic_SrAndJr[] = INCBIN_U32("graphics/trainers/front_pics/sr_and_jr.4bpp.lz"); +const u32 gTrainerPalette_SrAndJr[] = INCBIN_U32("graphics/trainers/front_pics/sr_and_jr.gbapal.lz"); -const u32 gTrainerFrontPic_PokefanM[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokefanM[] = INCBIN_U32("graphics/trainers/palettes/pokefan_m.gbapal.lz"); +const u32 gTrainerFrontPic_PokefanM[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_m.4bpp.lz"); +const u32 gTrainerPalette_PokefanM[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_m.gbapal.lz"); -const u32 gTrainerFrontPic_PokefanF[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokefanF[] = INCBIN_U32("graphics/trainers/palettes/pokefan_f.gbapal.lz"); +const u32 gTrainerFrontPic_PokefanF[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_f.4bpp.lz"); +const u32 gTrainerPalette_PokefanF[] = INCBIN_U32("graphics/trainers/front_pics/pokefan_f.gbapal.lz"); -const u32 gTrainerFrontPic_Youngster[] = INCBIN_U32("graphics/trainers/front_pics/youngster_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Youngster[] = INCBIN_U32("graphics/trainers/palettes/youngster.gbapal.lz"); +const u32 gTrainerFrontPic_Youngster[] = INCBIN_U32("graphics/trainers/front_pics/youngster.4bpp.lz"); +const u32 gTrainerPalette_Youngster[] = INCBIN_U32("graphics/trainers/front_pics/youngster.gbapal.lz"); -const u32 gTrainerFrontPic_ChampionWallace[] = INCBIN_U32("graphics/trainers/front_pics/champion_wallace_front_pic.4bpp.lz"); -const u32 gTrainerPalette_ChampionWallace[] = INCBIN_U32("graphics/trainers/palettes/champion_wallace.gbapal.lz"); +const u32 gTrainerFrontPic_ChampionWallace[] = INCBIN_U32("graphics/trainers/front_pics/champion_wallace.4bpp.lz"); +const u32 gTrainerPalette_ChampionWallace[] = INCBIN_U32("graphics/trainers/front_pics/champion_wallace.gbapal.lz"); -const u32 gTrainerFrontPic_Fisherman[] = INCBIN_U32("graphics/trainers/front_pics/fisherman_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Fisherman[] = INCBIN_U32("graphics/trainers/palettes/fisherman.gbapal.lz"); +const u32 gTrainerFrontPic_Fisherman[] = INCBIN_U32("graphics/trainers/front_pics/fisherman.4bpp.lz"); +const u32 gTrainerPalette_Fisherman[] = INCBIN_U32("graphics/trainers/front_pics/fisherman.gbapal.lz"); -const u32 gTrainerFrontPic_CyclingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_CyclingTriathleteM[] = INCBIN_U32("graphics/trainers/palettes/cycling_triathlete_m.gbapal.lz"); +const u32 gTrainerFrontPic_CyclingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_m.4bpp.lz"); +const u32 gTrainerPalette_CyclingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_m.gbapal.lz"); -const u32 gTrainerFrontPic_CyclingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_CyclingTriathleteF[] = INCBIN_U32("graphics/trainers/palettes/cycling_triathlete_f.gbapal.lz"); +const u32 gTrainerFrontPic_CyclingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_f.4bpp.lz"); +const u32 gTrainerPalette_CyclingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/cycling_triathlete_f.gbapal.lz"); -const u32 gTrainerFrontPic_RunningTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RunningTriathleteM[] = INCBIN_U32("graphics/trainers/palettes/running_triathlete_m.gbapal.lz"); +const u32 gTrainerFrontPic_RunningTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_m.4bpp.lz"); +const u32 gTrainerPalette_RunningTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_m.gbapal.lz"); -const u32 gTrainerFrontPic_RunningTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RunningTriathleteF[] = INCBIN_U32("graphics/trainers/palettes/running_triathlete_f.gbapal.lz"); +const u32 gTrainerFrontPic_RunningTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_f.4bpp.lz"); +const u32 gTrainerPalette_RunningTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/running_triathlete_f.gbapal.lz"); -const u32 gTrainerFrontPic_SwimmingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SwimmingTriathleteM[] = INCBIN_U32("graphics/trainers/palettes/swimming_triathlete_m.gbapal.lz"); +const u32 gTrainerFrontPic_SwimmingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_m.4bpp.lz"); +const u32 gTrainerPalette_SwimmingTriathleteM[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_m.gbapal.lz"); -const u32 gTrainerFrontPic_SwimmingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SwimmingTriathleteF[] = INCBIN_U32("graphics/trainers/palettes/swimming_triathlete_f.gbapal.lz"); +const u32 gTrainerFrontPic_SwimmingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_f.4bpp.lz"); +const u32 gTrainerPalette_SwimmingTriathleteF[] = INCBIN_U32("graphics/trainers/front_pics/swimming_triathlete_f.gbapal.lz"); -const u32 gTrainerFrontPic_DragonTamer[] = INCBIN_U32("graphics/trainers/front_pics/dragon_tamer_front_pic.4bpp.lz"); -const u32 gTrainerPalette_DragonTamer[] = INCBIN_U32("graphics/trainers/palettes/dragon_tamer.gbapal.lz"); +const u32 gTrainerFrontPic_DragonTamer[] = INCBIN_U32("graphics/trainers/front_pics/dragon_tamer.4bpp.lz"); +const u32 gTrainerPalette_DragonTamer[] = INCBIN_U32("graphics/trainers/front_pics/dragon_tamer.gbapal.lz"); -const u32 gTrainerFrontPic_NinjaBoy[] = INCBIN_U32("graphics/trainers/front_pics/ninja_boy_front_pic.4bpp.lz"); -const u32 gTrainerPalette_NinjaBoy[] = INCBIN_U32("graphics/trainers/palettes/ninja_boy.gbapal.lz"); +const u32 gTrainerFrontPic_NinjaBoy[] = INCBIN_U32("graphics/trainers/front_pics/ninja_boy.4bpp.lz"); +const u32 gTrainerPalette_NinjaBoy[] = INCBIN_U32("graphics/trainers/front_pics/ninja_boy.gbapal.lz"); -const u32 gTrainerFrontPic_BattleGirl[] = INCBIN_U32("graphics/trainers/front_pics/battle_girl_front_pic.4bpp.lz"); -const u32 gTrainerPalette_BattleGirl[] = INCBIN_U32("graphics/trainers/palettes/battle_girl.gbapal.lz"); +const u32 gTrainerFrontPic_BattleGirl[] = INCBIN_U32("graphics/trainers/front_pics/battle_girl.4bpp.lz"); +const u32 gTrainerPalette_BattleGirl[] = INCBIN_U32("graphics/trainers/front_pics/battle_girl.gbapal.lz"); -const u32 gTrainerFrontPic_ParasolLady[] = INCBIN_U32("graphics/trainers/front_pics/parasol_lady_front_pic.4bpp.lz"); -const u32 gTrainerPalette_ParasolLady[] = INCBIN_U32("graphics/trainers/palettes/parasol_lady.gbapal.lz"); +const u32 gTrainerFrontPic_ParasolLady[] = INCBIN_U32("graphics/trainers/front_pics/parasol_lady.4bpp.lz"); +const u32 gTrainerPalette_ParasolLady[] = INCBIN_U32("graphics/trainers/front_pics/parasol_lady.gbapal.lz"); -const u32 gTrainerFrontPic_SwimmerF[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SwimmerF[] = INCBIN_U32("graphics/trainers/palettes/swimmer_f.gbapal.lz"); +const u32 gTrainerFrontPic_SwimmerF[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_f.4bpp.lz"); +const u32 gTrainerPalette_SwimmerF[] = INCBIN_U32("graphics/trainers/front_pics/swimmer_f.gbapal.lz"); -const u32 gTrainerFrontPic_Twins[] = INCBIN_U32("graphics/trainers/front_pics/twins_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Twins[] = INCBIN_U32("graphics/trainers/palettes/twins.gbapal.lz"); +const u32 gTrainerFrontPic_Twins[] = INCBIN_U32("graphics/trainers/front_pics/twins.4bpp.lz"); +const u32 gTrainerPalette_Twins[] = INCBIN_U32("graphics/trainers/front_pics/twins.gbapal.lz"); -const u32 gTrainerFrontPic_Sailor[] = INCBIN_U32("graphics/trainers/front_pics/sailor_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Sailor[] = INCBIN_U32("graphics/trainers/palettes/sailor.gbapal.lz"); +const u32 gTrainerFrontPic_Sailor[] = INCBIN_U32("graphics/trainers/front_pics/sailor.4bpp.lz"); +const u32 gTrainerPalette_Sailor[] = INCBIN_U32("graphics/trainers/front_pics/sailor.gbapal.lz"); -const u32 gTrainerFrontPic_MagmaAdmin[] = INCBIN_U32("graphics/trainers/front_pics/magma_admin_front_pic.4bpp.lz"); -const u32 gTrainerPalette_MagmaAdmin[] = INCBIN_U32("graphics/trainers/palettes/magma_admin.gbapal.lz"); +const u32 gTrainerFrontPic_MagmaAdmin[] = INCBIN_U32("graphics/trainers/front_pics/magma_admin.4bpp.lz"); +const u32 gTrainerPalette_MagmaAdmin[] = INCBIN_U32("graphics/trainers/front_pics/magma_admin.gbapal.lz"); -const u32 gTrainerFrontPic_Wally[] = INCBIN_U32("graphics/trainers/front_pics/wally_front_pic.4bpp.lz"); +const u32 gTrainerFrontPic_Wally[] = INCBIN_U32("graphics/trainers/front_pics/wally.4bpp.lz"); const u32 gTrainerPalette_Wally[] = INCBIN_U32("graphics/trainers/palettes/wally.gbapal.lz"); -const u32 gTrainerFrontPic_Brendan[] = INCBIN_U32("graphics/trainers/front_pics/brendan_front_pic.4bpp.lz"); +const u32 gTrainerFrontPic_Brendan[] = INCBIN_U32("graphics/trainers/front_pics/brendan.4bpp.lz"); const u32 gTrainerPalette_Brendan[] = INCBIN_U32("graphics/trainers/palettes/brendan.gbapal.lz"); -const u32 gTrainerFrontPic_May[] = INCBIN_U32("graphics/trainers/front_pics/may_front_pic.4bpp.lz"); +const u32 gTrainerFrontPic_May[] = INCBIN_U32("graphics/trainers/front_pics/may.4bpp.lz"); const u32 gTrainerPalette_May[] = INCBIN_U32("graphics/trainers/palettes/may.gbapal.lz"); -const u32 gTrainerFrontPic_BugCatcher[] = INCBIN_U32("graphics/trainers/front_pics/bug_catcher_front_pic.4bpp.lz"); -const u32 gTrainerPalette_BugCatcher[] = INCBIN_U32("graphics/trainers/palettes/bug_catcher.gbapal.lz"); +const u32 gTrainerFrontPic_BugCatcher[] = INCBIN_U32("graphics/trainers/front_pics/bug_catcher.4bpp.lz"); +const u32 gTrainerPalette_BugCatcher[] = INCBIN_U32("graphics/trainers/front_pics/bug_catcher.gbapal.lz"); -const u32 gTrainerFrontPic_PokemonRangerM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_m_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokemonRangerM[] = INCBIN_U32("graphics/trainers/palettes/pokemon_ranger_m.gbapal.lz"); +const u32 gTrainerFrontPic_PokemonRangerM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_m.4bpp.lz"); +const u32 gTrainerPalette_PokemonRangerM[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_m.gbapal.lz"); -const u32 gTrainerFrontPic_PokemonRangerF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_f_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PokemonRangerF[] = INCBIN_U32("graphics/trainers/palettes/pokemon_ranger_f.gbapal.lz"); +const u32 gTrainerFrontPic_PokemonRangerF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_f.4bpp.lz"); +const u32 gTrainerPalette_PokemonRangerF[] = INCBIN_U32("graphics/trainers/front_pics/pokemon_ranger_f.gbapal.lz"); -const u32 gTrainerFrontPic_MagmaLeaderMaxie[] = INCBIN_U32("graphics/trainers/front_pics/magma_leader_maxie_front_pic.4bpp.lz"); -const u32 gTrainerPalette_MagmaLeaderMaxie[] = INCBIN_U32("graphics/trainers/palettes/magma_leader_maxie.gbapal.lz"); +const u32 gTrainerFrontPic_MagmaLeaderMaxie[] = INCBIN_U32("graphics/trainers/front_pics/magma_leader_maxie.4bpp.lz"); +const u32 gTrainerPalette_MagmaLeaderMaxie[] = INCBIN_U32("graphics/trainers/front_pics/magma_leader_maxie.gbapal.lz"); -const u32 gTrainerFrontPic_Lass[] = INCBIN_U32("graphics/trainers/front_pics/lass_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Lass[] = INCBIN_U32("graphics/trainers/palettes/lass.gbapal.lz"); +const u32 gTrainerFrontPic_Lass[] = INCBIN_U32("graphics/trainers/front_pics/lass.4bpp.lz"); +const u32 gTrainerPalette_Lass[] = INCBIN_U32("graphics/trainers/front_pics/lass.gbapal.lz"); -const u32 gTrainerFrontPic_YoungCouple[] = INCBIN_U32("graphics/trainers/front_pics/young_couple_front_pic.4bpp.lz"); -const u32 gTrainerPalette_YoungCouple[] = INCBIN_U32("graphics/trainers/palettes/young_couple.gbapal.lz"); +const u32 gTrainerFrontPic_YoungCouple[] = INCBIN_U32("graphics/trainers/front_pics/young_couple.4bpp.lz"); +const u32 gTrainerPalette_YoungCouple[] = INCBIN_U32("graphics/trainers/front_pics/young_couple.gbapal.lz"); -const u32 gTrainerFrontPic_OldCouple[] = INCBIN_U32("graphics/trainers/front_pics/old_couple_front_pic.4bpp.lz"); -const u32 gTrainerPalette_OldCouple[] = INCBIN_U32("graphics/trainers/palettes/old_couple.gbapal.lz"); +const u32 gTrainerFrontPic_OldCouple[] = INCBIN_U32("graphics/trainers/front_pics/old_couple.4bpp.lz"); +const u32 gTrainerPalette_OldCouple[] = INCBIN_U32("graphics/trainers/front_pics/old_couple.gbapal.lz"); -const u32 gTrainerFrontPic_SisAndBro[] = INCBIN_U32("graphics/trainers/front_pics/sis_and_bro_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SisAndBro[] = INCBIN_U32("graphics/trainers/palettes/sis_and_bro.gbapal.lz"); +const u32 gTrainerFrontPic_SisAndBro[] = INCBIN_U32("graphics/trainers/front_pics/sis_and_bro.4bpp.lz"); +const u32 gTrainerPalette_SisAndBro[] = INCBIN_U32("graphics/trainers/front_pics/sis_and_bro.gbapal.lz"); -const u32 gTrainerFrontPic_Steven[] = INCBIN_U32("graphics/trainers/front_pics/steven_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Steven[] = INCBIN_U32("graphics/trainers/palettes/steven.gbapal.lz"); +const u32 gTrainerFrontPic_Steven[] = INCBIN_U32("graphics/trainers/front_pics/steven.4bpp.lz"); +const u32 gTrainerPalette_Steven[] = INCBIN_U32("graphics/trainers/front_pics/steven.gbapal.lz"); -const u32 gTrainerFrontPic_SalonMaidenAnabel[] = INCBIN_U32("graphics/trainers/front_pics/salon_maiden_anabel_front_pic.4bpp.lz"); -const u32 gTrainerPalette_SalonMaidenAnabel[] = INCBIN_U32("graphics/trainers/palettes/salon_maiden_anabel.gbapal.lz"); +const u32 gTrainerFrontPic_SalonMaidenAnabel[] = INCBIN_U32("graphics/trainers/front_pics/salon_maiden_anabel.4bpp.lz"); +const u32 gTrainerPalette_SalonMaidenAnabel[] = INCBIN_U32("graphics/trainers/front_pics/salon_maiden_anabel.gbapal.lz"); -const u32 gTrainerFrontPic_DomeAceTucker[] = INCBIN_U32("graphics/trainers/front_pics/dome_ace_tucker_front_pic.4bpp.lz"); -const u32 gTrainerPalette_DomeAceTucker[] = INCBIN_U32("graphics/trainers/palettes/dome_ace_tucker.gbapal.lz"); +const u32 gTrainerFrontPic_DomeAceTucker[] = INCBIN_U32("graphics/trainers/front_pics/dome_ace_tucker.4bpp.lz"); +const u32 gTrainerPalette_DomeAceTucker[] = INCBIN_U32("graphics/trainers/front_pics/dome_ace_tucker.gbapal.lz"); -const u32 gTrainerFrontPic_PalaceMavenSpenser[] = INCBIN_U32("graphics/trainers/front_pics/palace_maven_spenser_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PalaceMavenSpenser[] = INCBIN_U32("graphics/trainers/palettes/palace_maven_spenser.gbapal.lz"); +const u32 gTrainerFrontPic_PalaceMavenSpenser[] = INCBIN_U32("graphics/trainers/front_pics/palace_maven_spenser.4bpp.lz"); +const u32 gTrainerPalette_PalaceMavenSpenser[] = INCBIN_U32("graphics/trainers/front_pics/palace_maven_spenser.gbapal.lz"); -const u32 gTrainerFrontPic_ArenaTycoonGreta[] = INCBIN_U32("graphics/trainers/front_pics/arena_tycoon_greta_front_pic.4bpp.lz"); -const u32 gTrainerPalette_ArenaTycoonGreta[] = INCBIN_U32("graphics/trainers/palettes/arena_tycoon_greta.gbapal.lz"); +const u32 gTrainerFrontPic_ArenaTycoonGreta[] = INCBIN_U32("graphics/trainers/front_pics/arena_tycoon_greta.4bpp.lz"); +const u32 gTrainerPalette_ArenaTycoonGreta[] = INCBIN_U32("graphics/trainers/front_pics/arena_tycoon_greta.gbapal.lz"); -const u32 gTrainerFrontPic_FactoryHeadNoland[] = INCBIN_U32("graphics/trainers/front_pics/factory_head_noland_front_pic.4bpp.lz"); -const u32 gTrainerPalette_FactoryHeadNoland[] = INCBIN_U32("graphics/trainers/palettes/factory_head_noland.gbapal.lz"); +const u32 gTrainerFrontPic_FactoryHeadNoland[] = INCBIN_U32("graphics/trainers/front_pics/factory_head_noland.4bpp.lz"); +const u32 gTrainerPalette_FactoryHeadNoland[] = INCBIN_U32("graphics/trainers/front_pics/factory_head_noland.gbapal.lz"); -const u32 gTrainerFrontPic_PikeQueenLucy[] = INCBIN_U32("graphics/trainers/front_pics/pike_queen_lucy_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PikeQueenLucy[] = INCBIN_U32("graphics/trainers/palettes/pike_queen_lucy.gbapal.lz"); +const u32 gTrainerFrontPic_PikeQueenLucy[] = INCBIN_U32("graphics/trainers/front_pics/pike_queen_lucy.4bpp.lz"); +const u32 gTrainerPalette_PikeQueenLucy[] = INCBIN_U32("graphics/trainers/front_pics/pike_queen_lucy.gbapal.lz"); -const u32 gTrainerFrontPic_PyramidKingBrandon[] = INCBIN_U32("graphics/trainers/front_pics/pyramid_king_brandon_front_pic.4bpp.lz"); -const u32 gTrainerPalette_PyramidKingBrandon[] = INCBIN_U32("graphics/trainers/palettes/pyramid_king_brandon.gbapal.lz"); +const u32 gTrainerFrontPic_PyramidKingBrandon[] = INCBIN_U32("graphics/trainers/front_pics/pyramid_king_brandon.4bpp.lz"); +const u32 gTrainerPalette_PyramidKingBrandon[] = INCBIN_U32("graphics/trainers/front_pics/pyramid_king_brandon.gbapal.lz"); -const u32 gTrainerFrontPic_Red[] = INCBIN_U32("graphics/trainers/front_pics/red_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Red[] = INCBIN_U32("graphics/trainers/palettes/red.gbapal.lz"); +const u32 gTrainerFrontPic_Red[] = INCBIN_U32("graphics/trainers/front_pics/red.4bpp.lz"); +const u32 gTrainerPalette_Red[] = INCBIN_U32("graphics/trainers/front_pics/red.gbapal.lz"); -const u32 gTrainerFrontPic_Leaf[] = INCBIN_U32("graphics/trainers/front_pics/leaf_front_pic.4bpp.lz"); -const u32 gTrainerPalette_Leaf[] = INCBIN_U32("graphics/trainers/palettes/leaf.gbapal.lz"); +const u32 gTrainerFrontPic_Leaf[] = INCBIN_U32("graphics/trainers/front_pics/leaf.4bpp.lz"); +const u32 gTrainerPalette_Leaf[] = INCBIN_U32("graphics/trainers/front_pics/leaf.gbapal.lz"); -const u32 gTrainerFrontPic_RubySapphireBrendan[] = INCBIN_U32("graphics/trainers/front_pics/ruby_sapphire_brendan_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RubySapphireBrendan[] = INCBIN_U32("graphics/trainers/palettes/ruby_sapphire_brendan.gbapal.lz"); +const u32 gTrainerFrontPic_RubySapphireBrendan[] = INCBIN_U32("graphics/trainers/front_pics/brendan_rs.4bpp.lz"); +const u32 gTrainerPalette_RubySapphireBrendan[] = INCBIN_U32("graphics/trainers/palettes/brendan_rs.gbapal.lz"); -const u32 gTrainerFrontPic_RubySapphireMay[] = INCBIN_U32("graphics/trainers/front_pics/ruby_sapphire_may_front_pic.4bpp.lz"); -const u32 gTrainerPalette_RubySapphireMay[] = INCBIN_U32("graphics/trainers/palettes/ruby_sapphire_may.gbapal.lz"); +const u32 gTrainerFrontPic_RubySapphireMay[] = INCBIN_U32("graphics/trainers/front_pics/may_rs.4bpp.lz"); +const u32 gTrainerPalette_RubySapphireMay[] = INCBIN_U32("graphics/trainers/palettes/may_rs.gbapal.lz"); -const u8 gTrainerBackPic_Brendan[] = INCBIN_U8("graphics/trainers/back_pics/brendan_back_pic.4bpp"); -const u8 gTrainerBackPic_May[] = INCBIN_U8("graphics/trainers/back_pics/may_back_pic.4bpp"); -const u8 gTrainerBackPic_Red[] = INCBIN_U8("graphics/trainers/back_pics/red_back_pic.4bpp"); -const u8 gTrainerBackPic_Leaf[] = INCBIN_U8("graphics/trainers/back_pics/leaf_back_pic.4bpp"); -const u8 gTrainerBackPic_RubySapphireBrendan[] = INCBIN_U8("graphics/trainers/back_pics/ruby_sapphire_brendan_back_pic.4bpp"); -const u8 gTrainerBackPic_RubySapphireMay[] = INCBIN_U8("graphics/trainers/back_pics/ruby_sapphire_may_back_pic.4bpp"); -const u8 gTrainerBackPic_Wally[] = INCBIN_U8("graphics/trainers/back_pics/wally_back_pic.4bpp"); -const u8 gTrainerBackPic_Steven[] = INCBIN_U8("graphics/trainers/back_pics/steven_back_pic.4bpp"); +const u8 gTrainerBackPic_Brendan[] = INCBIN_U8("graphics/trainers/back_pics/brendan.4bpp"); +const u8 gTrainerBackPic_May[] = INCBIN_U8("graphics/trainers/back_pics/may.4bpp"); +const u8 gTrainerBackPic_Red[] = INCBIN_U8("graphics/trainers/back_pics/red.4bpp"); +const u8 gTrainerBackPic_Leaf[] = INCBIN_U8("graphics/trainers/back_pics/leaf.4bpp"); +const u8 gTrainerBackPic_RubySapphireBrendan[] = INCBIN_U8("graphics/trainers/back_pics/brendan_rs.4bpp"); +const u8 gTrainerBackPic_RubySapphireMay[] = INCBIN_U8("graphics/trainers/back_pics/may_rs.4bpp"); +const u8 gTrainerBackPic_Wally[] = INCBIN_U8("graphics/trainers/back_pics/wally.4bpp"); +const u8 gTrainerBackPic_Steven[] = INCBIN_U8("graphics/trainers/back_pics/steven.4bpp"); -const u32 gTrainerBackPicPalette_Red[] = INCBIN_U32("graphics/trainers/palettes/red_back_pic.gbapal.lz"); -const u32 gTrainerBackPicPalette_Leaf[] = INCBIN_U32("graphics/trainers/palettes/leaf_back_pic.gbapal.lz"); +const u32 gTrainerBackPicPalette_Red[] = INCBIN_U32("graphics/trainers/back_pics/red.gbapal.lz"); +const u32 gTrainerBackPicPalette_Leaf[] = INCBIN_U32("graphics/trainers/back_pics/leaf.gbapal.lz"); From 584bfe022192f6e68ae202c40febc1dc7839db4e Mon Sep 17 00:00:00 2001 From: sbird Date: Tue, 6 Sep 2022 13:40:29 +0200 Subject: [PATCH 02/15] [debug] add support for mgba printf * adds support for mgba printf debugging as well as adding support for switching between debugging configuration * adds `mini_printf` as an alternative to libc printf as well as switches to choose a pretty printing handler * adds a pretty printing format to `mini_printf` to print preproc encoded strings --- include/config.h | 29 +++- include/gba/isagbprint.h | 72 ++++---- include/mini_printf.h | 52 ++++++ src/libisagbprn.c | 134 ++++++++++++++- src/main.c | 7 + src/mini_printf.c | 353 +++++++++++++++++++++++++++++++++++++++ 6 files changed, 605 insertions(+), 42 deletions(-) create mode 100644 include/mini_printf.h create mode 100644 src/mini_printf.c diff --git a/include/config.h b/include/config.h index 5f2fa4d2c..4e2ee21bd 100644 --- a/include/config.h +++ b/include/config.h @@ -8,12 +8,31 @@ // Ruby's actual debug build does not use the AGBPrint features. #define NDEBUG -// To enable print debugging, comment out "#define NDEBUG". This allows +// To enable printf debugging, comment out "#define NDEBUG". This allows // the various AGBPrint functions to be used. (See include/gba/isagbprint.h). -// Some emulators support a debug console window: uncomment NoCashGBAPrint() -// and NoCashGBAPrintf() in libisagbprn.c to use no$gba's own proprietary -// printing system. Use NoCashGBAPrint() and NoCashGBAPrintf() like you -// would normally use AGBPrint() and AGBPrintf(). +// See below for enabling different pretty printing versions. + +#ifndef NDEBUG + +#define PRETTY_PRINT_MINI_PRINTF (0) +#define PRETTY_PRINT_LIBC (1) + +#define LOG_HANDLER_AGB_PRINT (0) +#define LOG_HANDLER_NOCASH_PRINT (1) +#define LOG_HANDLER_MGBA_PRINT (2) + +// Use this switch to choose a handler for pretty printing. +// NOTE: mini_printf supports a custom pretty printing formatter to display preproc encoded strings. (%S) +// some libc distributions (especially dkp arm-libc) will fail to link pretty printing. +#define PRETTY_PRINT_HANDLER (PRETTY_PRINT_MINI_PRINTF) + +// Use this switch to choose a handler for printf output. +// NOTE: These will only work on the respective emulators and should not be used in a productive environment. +// Some emulators or real hardware might (and is allowed to) crash if they are used. +// AGB_PRINT is supported on respective debug units. + +#define LOG_HANDLER (LOG_HANDLER_MGBA_PRINT) +#endif #define ENGLISH diff --git a/include/gba/isagbprint.h b/include/gba/isagbprint.h index 13687825e..abe7fb210 100644 --- a/include/gba/isagbprint.h +++ b/include/gba/isagbprint.h @@ -1,36 +1,50 @@ #ifndef GUARD_GBA_ISAGBPRINT_H #define GUARD_GBA_ISAGBPRINT_H -#ifdef NDEBUG -#define AGBPrintInit() -#define AGBPutc(cChr) -#define AGBPrint(pBuf) -#define AGBPrintf(pBuf, ...) -#define AGBPrintFlush1Block() -#define AGBPrintFlush() -#define AGBAssert(pFile, nLine, pExpression, nStopProgram) -#else -void AGBPrintInit(void); -void AGBPutc(const char cChr); -void AGBPrint(const char *pBuf); -void AGBPrintf(const char *pBuf, ...); -void AGBPrintFlush1Block(void); -void AGBPrintFlush(void); -void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopProgram); -#endif +#include "gba/types.h" -#undef AGB_ASSERT #ifdef NDEBUG +#define DebugPrintf(pBuf, ...) +#define MgbaOpen() +#define MgbaClose() #define AGB_ASSERT(exp) -#else -#define AGB_ASSERT(exp) (exp) ? ((void *)0) : AGBAssert(__FILE__, __LINE__, #exp, 1); -#endif - -#undef AGB_WARNING -#ifdef NDEBUG #define AGB_WARNING(exp) +#define AGBPrintInit() #else -#define AGB_WARNING(exp) (exp) ? ((void *)0) : AGBAssert(__FILE__, __LINE__, #exp, 0); +#if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) +bool32 MgbaOpen(void); +void MgbaClose(void); +void MgbaPrintf(const char *pBuf, ...); +void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); +#define DebugPrintf(pBuf, ...) MgbaPrintf(pBuf, __VA_ARGS__) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, 1) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, 0) + +// Not used in this configuration +#define AGBPrintfInit() +#elif (LOG_HANDLER == LOG_HANDLER_NOCASH_PRINT) +void NoCashGBAPrintf(const char *pBuf, ...) +void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) +#define DebugPrintf(pBuf, ...) NoCashGBAPrintf(pBuf, __VA_ARGS__) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 1); +#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 0) + +// Not used in this configuration +#define MgbaOpen() +#define MgbaClose() +#define AGBPrintInit() +#else // Default to AGBPrint +void AGBPrintf(const char *pBuf, ...); +void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopProgram); +void AGBPrintInit(void); +#define DebugPrintf(pBuf, ...) AGBPrintf(const char *pBuf, ...) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, 1) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 0) + +// Not used in this configuration +#define MgbaOpen() +#define MgbaClose() +#endif #endif // for matching purposes @@ -38,13 +52,7 @@ void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopP #ifdef NDEBUG #define AGB_ASSERT_EX(exp, file, line) #else -#define AGB_ASSERT_EX(exp, file, line) (exp) ? ((void *)0) : AGBAssert(file, line, #exp, 1); -#endif - -#ifdef NDEBUG -#define AGB_WARNING_EX(exp, file, line) -#else -#define AGB_WARNING_EX(exp, file, line) (exp) ? ((void *)0) : AGBAssert(file, line, #exp, 0); +#define AGB_ASSERT_EX(exp, file, line) AGB_ASSERT(exp); #endif #endif // GUARD_GBA_ISAGBPRINT_H diff --git a/include/mini_printf.h b/include/mini_printf.h new file mode 100644 index 000000000..a891327cc --- /dev/null +++ b/include/mini_printf.h @@ -0,0 +1,52 @@ +/* + * The Minimal snprintf() implementation + * + * Copyright (c) 2013 Michal Ludvig + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * * Neither the name of the auhor nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * Courtey of https://github.com/mludvig/mini-printf + * stripped to reduce file size for agb needs + */ + +#ifndef __MINI_PRINTF__ +#define __MINI_PRINTF__ + +#include +#include "gba/types.h" + +#ifdef NDEBUG + +#define mini_vsnprintf(buffer, buffer_len, fmt, va) +#define mini_vpprintf(buf, fmt, va) + +#else + +s32 mini_vsnprintf(char* buffer, u32 buffer_len, const char *fmt, va_list va); +s32 mini_vpprintf(void* buf, const char *fmt, va_list va); + +#endif +#endif diff --git a/src/libisagbprn.c b/src/libisagbprn.c index 6fb9d5ec0..0dbaec157 100644 --- a/src/libisagbprn.c +++ b/src/libisagbprn.c @@ -2,6 +2,8 @@ #include #include "gba/gba.h" #include "config.h" +#include "malloc.h" +#include "mini_printf.h" #define AGB_PRINT_FLUSH_ADDR 0x9FE209D #define AGB_PRINT_STRUCT_ADDR 0x9FE20F8 @@ -14,6 +16,11 @@ #define NOCASHGBAPRINTADDR1 0x4FFFA10 // automatically adds a newline after the string has finished #define NOCASHGBAPRINTADDR2 0x4FFFA14 // does not automatically add the newline. by default, NOCASHGBAPRINTADDR2 is used. this is used to keep strings consistent between no$gba and VBA-RR, but a user can choose to forgo this. +// hardware extensions for LOG_HANDLER_MGBA_PRINT +#define REG_DEBUG_ENABLE ((vu16*) (0x4FFF780)) // handshake: (w)[0xC0DE] -> (r)[0x1DEA] +#define REG_DEBUG_FLAGS ((vu16*) (0x4FFF700)) +#define REG_DEBUG_STRING ((char*) (0x4FFF600)) + struct AGBPrintStruct { u16 m_nRequest; @@ -26,6 +33,8 @@ typedef void (*LPFN_PRINT_FLUSH)(void); #ifndef NDEBUG +// AGBPrint print functions +#if (LOG_HANDLER == LOG_HANDLER_AGB_PRINT) void AGBPrintFlush1Block(void); void AGBPrintInit(void) @@ -87,7 +96,13 @@ void AGBPrintf(const char *pBuf, ...) char bufPrint[0x100]; va_list vArgv; va_start(vArgv, pBuf); - vsprintf(bufPrint, pBuf, vArgv); + #if (PRETTY_PRINT_HANDLER == PRETTY_PRINT_MINI_PRINTF) + mini_vsnprintf(bufPrint, 0x100, pBuf, vArgv); + #elif (PRETTY_PRINT_HANDLER == PRETTY_PRINT_LIBC) + vsnprintf(bufPrint, 0x100, pBuf, vArgv); + #else + #error "unspecified pretty printing handler." + #endif va_end(vArgv); AGBPrint(bufPrint); } @@ -155,9 +170,10 @@ void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopP AGBPrintf("WARING FILE=[%s] LINE=[%d] EXP=[%s] \n", pFile, nLine, pExpression); } } +#endif -// no$gba print functions, uncomment to use -/* +// no$gba print functions +#if (LOG_HANDLER == LOG_HANDLER_NOCASH_PRINT) void NoCashGBAPrint(const char *pBuf) { *(volatile u32 *)NOCASHGBAPRINTADDR2 = (u32)pBuf; @@ -168,10 +184,118 @@ void NoCashGBAPrintf(const char *pBuf, ...) char bufPrint[0x100]; va_list vArgv; va_start(vArgv, pBuf); - vsprintf(bufPrint, pBuf, vArgv); + #if (PRETTY_PRINT_HANDLER == PRETTY_PRINT_MINI_PRINTF) + mini_vsnprintf(bufPrint, 0x100, pBuf, vArgv); + #elif (PRETTY_PRINT_HANDLER == PRETTY_PRINT_LIBC) + vsnprintf(bufPrint, 0x100, pBuf, vArgv); + #else + #error "unspecified pretty printing handler." + #endif va_end(vArgv); NoCashGBAPrint(bufPrint); } -*/ +void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) +{ + if (nStopProgram) + { + NoCashGBAPrintf("ASSERTION FAILED FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + asm(".hword 0xEFFF"); + } + else + { + NoCashGBAPrintf("WARING FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + } +} +#endif + +// mgba print functions +#if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) +#define MGBA_PRINTF_BUFFER_SIZE (4096) + +#define MGBA_LOG_FATAL (0) +#define MGBA_LOG_ERROR (1) +#define MGBA_LOG_WARN (2) +#define MGBA_LOG_INFO (3) +#define MGBA_LOG_DEBUG (4) + +#define MGBA_REG_DEBUG_MAX (256) + +bool32 MgbaOpen(void) +{ + *REG_DEBUG_ENABLE = 0xC0DE; + return *REG_DEBUG_ENABLE == 0x1DEA; +} + +void MgbaClose(void) +{ + *REG_DEBUG_ENABLE = 0; +} + +static void MgbaPrintfBounded(s32 level, const char* ptr, ...) +{ + va_list args; + + level &= 0x7; + va_start(args, ptr); + #if (PRETTY_PRINT_HANDLER == PRETTY_PRINT_MINI_PRINTF) + mini_vsnprintf(REG_DEBUG_STRING, MGBA_REG_DEBUG_MAX, ptr, args); + #elif (PRETTY_PRINT_HANDLER == PRETTY_PRINT_LIBC) + vsnprintf(REG_DEBUG_STRING, MGBA_REG_DEBUG_MAX, ptr, args); + #else + #error "unspecified pretty printing handler." + #endif + va_end(args); + *REG_DEBUG_FLAGS = level | 0x100; +} + +void MgbaPrintf(const char* ptr, ...) +{ + va_list args; + u32 offset = 0; + u32 n = 0; + u32 i; + char *buffer = Alloc(MGBA_PRINTF_BUFFER_SIZE); + AGB_ASSERT(buffer != NULL); + + va_start(args, ptr); + #if (PRETTY_PRINT_HANDLER == PRETTY_PRINT_MINI_PRINTF) + n = mini_vsnprintf(buffer, MGBA_PRINTF_BUFFER_SIZE, ptr, args); + #elif (PRETTY_PRINT_HANDLER == PRETTY_PRINT_LIBC) + n = vsnprintf(buffer, MGBA_PRINTF_BUFFER_SIZE, ptr, args); + #else + #error "unspecified pretty printing handler." + #endif + va_end(args); + + AGB_ASSERT(n < MGBA_PRINTF_BUFFER_SIZE); + + do + { + for (i = 0; i < MGBA_REG_DEBUG_MAX; ++i) + { + REG_DEBUG_STRING[i] = buffer[offset + i]; + if (buffer[offset + i] == 0) + break; + } + offset += i; + *REG_DEBUG_FLAGS = MGBA_LOG_INFO | 0x100; + } while ((i == MGBA_REG_DEBUG_MAX) && (buffer[offset] != '\0')); + + Free(buffer); +} + +void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) +{ + if (nStopProgram) + { + MgbaPrintfBounded(MGBA_LOG_ERROR, "ASSERTION FAILED FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + asm(".hword 0xEFFF"); + } + else + { + MgbaPrintfBounded(MGBA_LOG_WARN, "WARING FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + } +} +#endif #endif diff --git a/src/main.c b/src/main.c index 5fd236447..a0ff6452a 100644 --- a/src/main.c +++ b/src/main.c @@ -119,6 +119,13 @@ void AgbMain() gLinkTransferringData = FALSE; sUnusedVar = 0xFC0; +#ifndef NDEBUG +#if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) + (void) MgbaOpen(); +#elif (LOG_HANDLER == LOG_HANDLER_AGB_PRINT) + AGBPrintfInit(); +#endif +#endif for (;;) { ReadKeys(); diff --git a/src/mini_printf.c b/src/mini_printf.c new file mode 100644 index 000000000..8345a3935 --- /dev/null +++ b/src/mini_printf.c @@ -0,0 +1,353 @@ +/* + * The Minimal snprintf() implementation + * + * Copyright (c) 2013,2014 Michal Ludvig + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * * Neither the name of the auhor nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * mini-printf courtesy of https://github.com/mludvig/mini-printf + * stripped to reduce file size for agb needs + */ + +#include "mini_printf.h" +#include "gba/types.h" +#include "gba/defines.h" +#include "config.h" +#include "characters.h" +#include "string_util.h" + +#ifndef NDEBUG + +struct mini_buff +{ + char *buffer, *pbuffer; + u32 buffer_len; +}; + +static inline char mini_pchar_decode(char encoded) +{ + char ret = '?'; + if (encoded >= CHAR_a && encoded <= CHAR_z) + ret = encoded-(CHAR_a-'a'); // lower-case characters + else if (encoded >= CHAR_A && encoded <= CHAR_Z) + ret = encoded-(CHAR_A-'A'); // upper-case characters + else if (encoded >= CHAR_0 && encoded <= CHAR_9) + ret = encoded-(CHAR_0-'0'); // numbers + else if (encoded == CHAR_SPACE) + ret = ' '; // space + else if (encoded == CHAR_EXCL_MARK) + ret = '!'; // exclamation point + else if (encoded == CHAR_QUESTION_MARK) + ret = '?'; // question mark + else if (encoded == CHAR_PERIOD) + ret = '.'; // period + else if (encoded == CHAR_DBL_QUOTE_LEFT || encoded == CHAR_DBL_QUOTE_RIGHT) + ret = '"'; // double quote + else if (encoded == CHAR_SGL_QUOTE_LEFT || encoded == CHAR_SGL_QUOTE_RIGHT) + ret = '\''; // single quote + else if (encoded == CHAR_CURRENCY) + ret = '$'; // currency mark (pokemonies in game, dollar sign in logs) + else if (encoded == CHAR_COMMA) + ret = ','; // comma + else if (encoded == CHAR_MULT_SIGN) + ret = '#'; // pound, hashtag, octothorpe, whatever + else if (encoded == CHAR_SLASH) + ret = '/'; // slash + else if (encoded == CHAR_LESS_THAN) + ret = '<'; // less than sign + else if (encoded == CHAR_GREATER_THAN) + ret = '>'; // greater than sign + else if (encoded == CHAR_PERCENT) + ret = '%'; // percentage + else if (encoded == CHAR_LEFT_PAREN) + ret = '('; // opening parentheses + else if (encoded == CHAR_RIGHT_PAREN) + ret = ')'; // closing parentheses + return ret; +} + +static s32 _putsAscii(char *s, s32 len, void *buf) +{ + char *p0; + s32 i; + struct mini_buff *b; + + if (!buf) + return len; + + b = buf; + p0 = b->buffer; + + /* Copy to buffer */ + for (i = 0; i < len; i++) { + if(b->pbuffer == b->buffer + b->buffer_len - 1) { + break; + } + *(b->pbuffer ++) = s[i]; + } + *(b->pbuffer) = 0; + return b->pbuffer - p0; +} + +static s32 _putsEncoded(char *s, s32 len, void *buf) +{ + char *p0; + s32 i; + struct mini_buff *b; + + if (!buf) + return len; + + b = buf; + p0 = b->buffer; + + /* Copy to buffer */ + for (i = 0; i < len; i++) { + if(b->pbuffer == b->buffer + b->buffer_len - 1) { + break; + } + *(b->pbuffer ++) = mini_pchar_decode(s[i]); + } + *(b->pbuffer) = 0; + return b->pbuffer - p0; +} + +static s32 mini_strlen(const char *s) +{ + s32 len = 0; + while (s[len] != '\0') len++; + return len; +} + +static s32 mini_itoa(u32 value, u32 radix, s32 uppercase, bool32 unsig, char *buffer) +{ + char *pbuffer = buffer; + s32 negative = 0; + s32 i, len; + + /* No support for unusual radixes. */ + if (radix > 16) + return 0; + + if (value < 0 && !unsig) + { + negative = 1; + value = -value; + } + + /* This builds the string back to front ... */ + do + { + s32 digit = value % radix; + *(pbuffer++) = (digit < 10 ? '0' + digit : (uppercase ? 'A' : 'a') + digit - 10); + value /= radix; + } while (value > 0); + + if (negative) + *(pbuffer++) = '-'; + + *(pbuffer) = '\0'; + + /* ... now we reverse it (could do it recursively but will + * conserve the stack space) */ + len = (pbuffer - buffer); + for (i = 0; i < len / 2; i++) + { + char j = buffer[i]; + buffer[i] = buffer[len-i-1]; + buffer[len-i-1] = j; + } + + return len; +} + +static s32 mini_pad(char* ptr, s32 len, char pad_char, s32 pad_to, char *buffer) +{ + s32 i; + bool32 overflow = FALSE; + char * pbuffer = buffer; + if(pad_to == 0) + pad_to = len; + if (len > pad_to) { + len = pad_to; + overflow = TRUE; + } + for(i = pad_to - len; i > 0; i --) + { + *(pbuffer++) = pad_char; + } + for(i = len; i > 0; i --) + { + *(pbuffer++) = *(ptr++); + } + len = pbuffer - buffer; + if(overflow) + { + for (i = 0; i < 3 && pbuffer > buffer; i ++) + { + *(pbuffer-- - 1) = '*'; + } + } + return len; +} + +s32 mini_vsnprintf(char *buffer, u32 buffer_len, const char *fmt, va_list va) +{ + struct mini_buff b; + s32 n; + b.buffer = buffer; + b.pbuffer = buffer; + b.buffer_len = buffer_len; + if (buffer_len == 0) + buffer = NULL; + n = mini_vpprintf((buffer != NULL) ? &b : NULL, fmt, va); + if (buffer == NULL) + return n; + return b.pbuffer - b.buffer; +} + +s32 mini_vpprintf(void* buf, const char *fmt, va_list va) +{ + char bf[24]; + char bf2[24]; + char ch; + s32 n; + n = 0; + while ((ch=*(fmt++))) + { + s32 len; + if (ch != '%') + { + len = 1; + len = _putsAscii(&ch, len, buf); + } else + { + char pad_char = ' '; + s32 pad_to = 0; + char l = 0; + char *ptr; + + ch=*(fmt++); + + /* Zero padding requested */ + if (ch == '0') + pad_char = '0'; + while (ch >= '0' && ch <= '9') + { + pad_to = pad_to * 10 + (ch - '0'); + ch= *(fmt++); + } + if(pad_to > (s32) sizeof(bf)) + { + pad_to = sizeof(bf); + } + if (ch == 'l') + { + l = 1; + ch=*(fmt++); + } + + switch (ch) + { + case 0: + goto end; + case 'u': + case 'd': + if(l) + { + len = mini_itoa(va_arg(va, u32), 10, 0, (ch=='u'), bf2); + } else + { + if(ch == 'u') + { + len = mini_itoa((u32) va_arg(va, u32), 10, 0, 1, bf2); + } + else + { + len = mini_itoa((s32) va_arg(va, s32), 10, 0, 0, bf2); + } + } + len = mini_pad(bf2, len, pad_char, pad_to, bf); + len = _putsAscii(bf, len, buf); + break; + + case 'x': + case 'X': + if(l) + { + len = mini_itoa(va_arg(va, u32), 16, (ch=='X'), 1, bf2); + } + else + { + len = mini_itoa((u32) va_arg(va, u32), 16, (ch=='X'), 1, bf2); + } + len = mini_pad(bf2, len, pad_char, pad_to, bf); + len = _putsAscii(bf, len, buf); + break; + + case 'c' : + ch = (char)(va_arg(va, s32)); + len = mini_pad(&ch, 1, pad_char, pad_to, bf); + len = _putsAscii(bf, len, buf); + break; + + case 's' : + ptr = va_arg(va, char*); + len = mini_strlen(ptr); + if (pad_to > 0) + { + len = mini_pad(ptr, len, pad_char, pad_to, bf); + len = _putsAscii(bf, len, buf); + } else + { + len = _putsAscii(ptr, len, buf); + } + break; + case 'S' : // preproc encoded string handler + ptr = va_arg(va, char*); + len = StringLength(ptr); + if (pad_to > 0) + { + len = mini_pad(ptr, len, pad_char, pad_to, bf); + len = _putsEncoded(bf, len, buf); + } else + { + len = _putsEncoded(ptr, len, buf); + } + break; + default: + len = 1; + len = _putsAscii(&ch, len, buf); + break; + } + } + n = n + len; + } +end: + return n; +} + +#endif From 041870672ac07c98f4cab39c25737201740728ea Mon Sep 17 00:00:00 2001 From: GriffinR Date: Mon, 12 Sep 2022 15:11:58 -0400 Subject: [PATCH 03/15] Add misc constant usage to field_weather_effect --- src/field_weather_effect.c | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/src/field_weather_effect.c b/src/field_weather_effect.c index 820628ff8..f5769cc23 100644 --- a/src/field_weather_effect.c +++ b/src/field_weather_effect.c @@ -596,8 +596,8 @@ static void UpdateRainSprite(struct Sprite *sprite) sprite->y = sprite->tPosY >> 4; if (sprite->tActive - && (sprite->x >= -8 && sprite->x <= 248) - && sprite->y >= -16 && sprite->y <= 176) + && (sprite->x >= -8 && sprite->x <= DISPLAY_WIDTH + 8) + && sprite->y >= -16 && sprite->y <= DISPLAY_HEIGHT + 16) sprite->invisible = FALSE; else sprite->invisible = TRUE; @@ -1442,9 +1442,9 @@ static void FogHorizontalSpriteCallback(struct Sprite *sprite) { sprite->y2 = (u8)gSpriteCoordOffsetY; sprite->x = gWeatherPtr->fogHScrollPosX + 32 + sprite->tSpriteColumn * 64; - if (sprite->x > 271) + if (sprite->x >= DISPLAY_WIDTH + 32) { - sprite->x = 480 + gWeatherPtr->fogHScrollPosX - (4 - sprite->tSpriteColumn) * 64; + sprite->x = (DISPLAY_WIDTH * 2) + gWeatherPtr->fogHScrollPosX - (4 - sprite->tSpriteColumn) * 64; sprite->x &= 0x1FF; } } @@ -1701,9 +1701,9 @@ static void UpdateAshSprite(struct Sprite *sprite) sprite->y = gSpriteCoordOffsetY + sprite->tOffsetY; sprite->x = gWeatherPtr->ashBaseSpritesX + 32 + sprite->tSpriteColumn * 64; - if (sprite->x > 271) + if (sprite->x >= DISPLAY_WIDTH + 32) { - sprite->x = gWeatherPtr->ashBaseSpritesX + 480 - (4 - sprite->tSpriteColumn) * 64; + sprite->x = gWeatherPtr->ashBaseSpritesX + (DISPLAY_WIDTH * 2) - (4 - sprite->tSpriteColumn) * 64; sprite->x &= 0x1FF; } } @@ -1911,9 +1911,9 @@ static void UpdateFogDiagonalSprite(struct Sprite *sprite) { sprite->y2 = gWeatherPtr->fogDPosY; sprite->x = gWeatherPtr->fogDBaseSpritesX + 32 + sprite->tSpriteColumn * 64; - if (sprite->x > 271) + if (sprite->x >= DISPLAY_WIDTH + 32) { - sprite->x = gWeatherPtr->fogDBaseSpritesX + 480 - (4 - sprite->tSpriteColumn) * 64; + sprite->x = gWeatherPtr->fogDBaseSpritesX + (DISPLAY_WIDTH * 2) - (4 - sprite->tSpriteColumn) * 64; sprite->x &= 0x1FF; } } @@ -2187,9 +2187,9 @@ static void UpdateSandstormSprite(struct Sprite *sprite) { sprite->y2 = gWeatherPtr->sandstormPosY; sprite->x = gWeatherPtr->sandstormBaseSpritesX + 32 + sprite->tSpriteColumn * 64; - if (sprite->x > 271) + if (sprite->x >= DISPLAY_WIDTH + 32) { - sprite->x = gWeatherPtr->sandstormBaseSpritesX + 480 - (4 - sprite->tSpriteColumn) * 64; + sprite->x = gWeatherPtr->sandstormBaseSpritesX + (DISPLAY_WIDTH * 2) - (4 - sprite->tSpriteColumn) * 64; sprite->x &= 0x1FF; } } @@ -2206,7 +2206,7 @@ static void UpdateSandstormSwirlSprite(struct Sprite *sprite) if (--sprite->y < -48) { - sprite->y = 208; + sprite->y = DISPLAY_HEIGHT + 48; sprite->tRadius = 4; } @@ -2567,14 +2567,16 @@ void ResumePausedWeather(void) SetCurrentAndNextWeather(weather); } -static const u8 sWeatherCycleRoute119[] = +#define WEATHER_CYCLE_LENGTH 4 + +static const u8 sWeatherCycleRoute119[WEATHER_CYCLE_LENGTH] = { WEATHER_SUNNY, WEATHER_RAIN, WEATHER_RAIN_THUNDERSTORM, WEATHER_RAIN, }; -static const u8 sWeatherCycleRoute123[] = +static const u8 sWeatherCycleRoute123[WEATHER_CYCLE_LENGTH] = { WEATHER_SUNNY, WEATHER_SUNNY, @@ -2611,7 +2613,7 @@ static u8 TranslateWeatherNum(u8 weather) void UpdateWeatherPerDay(u16 increment) { u16 weatherStage = gSaveBlock1Ptr->weatherCycleStage + increment; - weatherStage %= 4; + weatherStage %= WEATHER_CYCLE_LENGTH; gSaveBlock1Ptr->weatherCycleStage = weatherStage; } From 492380bd24912a80be4e7a14e8e4bf8355c277fd Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Wed, 14 Sep 2022 12:20:59 -0300 Subject: [PATCH 04/15] gReservedSpritePaletteCount using MAX_BATTLERS_COUNT for battles --- src/battle_main.c | 6 +++--- src/reshow_battle_screen.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/battle_main.c b/src/battle_main.c index 52a100598..903588fe7 100644 --- a/src/battle_main.c +++ b/src/battle_main.c @@ -665,7 +665,7 @@ static void CB2_InitBattleInternal(void) ResetTasks(); DrawBattleEntryBackground(); FreeAllSpritePalettes(); - gReservedSpritePaletteCount = 4; + gReservedSpritePaletteCount = MAX_BATTLERS_COUNT; SetVBlankCallback(VBlankCB_Battle); SetUpBattleVarsAndBirchZigzagoon(); @@ -2221,7 +2221,7 @@ void CB2_InitEndLinkBattle(void) DrawBattleEntryBackground(); SetGpuReg(REG_OFFSET_WINOUT, WINOUT_WIN01_BG0 | WINOUT_WIN01_BG1 | WINOUT_WIN01_BG2 | WINOUT_WIN01_OBJ | WINOUT_WIN01_CLR); FreeAllSpritePalettes(); - gReservedSpritePaletteCount = 4; + gReservedSpritePaletteCount = MAX_BATTLERS_COUNT; SetVBlankCallback(VBlankCB_Battle); // Show end Vs screen with battle results @@ -2425,7 +2425,7 @@ static void CB2_InitAskRecordBattle(void) ResetSpriteData(); ResetTasks(); FreeAllSpritePalettes(); - gReservedSpritePaletteCount = 4; + gReservedSpritePaletteCount = MAX_BATTLERS_COUNT; SetVBlankCallback(VBlankCB_Battle); SetMainCallback2(CB2_AskRecordBattle); BeginNormalPaletteFade(PALETTES_ALL, 0, 0x10, 0, RGB_BLACK); diff --git a/src/reshow_battle_screen.c b/src/reshow_battle_screen.c index 4217d78c7..fd2ed03cc 100644 --- a/src/reshow_battle_screen.c +++ b/src/reshow_battle_screen.c @@ -73,7 +73,7 @@ static void CB2_ReshowBattleScreenAfterMenu(void) break; case 4: FreeAllSpritePalettes(); - gReservedSpritePaletteCount = 4; + gReservedSpritePaletteCount = MAX_BATTLERS_COUNT; break; case 5: ClearSpritesHealthboxAnimData(); From bca1267ca84af5dab9f82ec1c2209c786eb1f6b7 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Thu, 15 Sep 2022 14:52:18 -0300 Subject: [PATCH 05/15] Altered MAX_FRONTIER_PARTY_SIZE to be automatically calculated by the other frontier party sizes --- include/constants/global.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/constants/global.h b/include/constants/global.h index 2a0ac7d6f..8e40e6378 100644 --- a/include/constants/global.h +++ b/include/constants/global.h @@ -35,7 +35,9 @@ #define FRONTIER_PARTY_SIZE 3 #define FRONTIER_DOUBLES_PARTY_SIZE 4 #define FRONTIER_MULTI_PARTY_SIZE 2 -#define MAX_FRONTIER_PARTY_SIZE FRONTIER_DOUBLES_PARTY_SIZE +#define MAX_FRONTIER_PARTY_SIZE (max(FRONTIER_PARTY_SIZE, \ + max(FRONTIER_DOUBLES_PARTY_SIZE,\ + FRONTIER_MULTI_PARTY_SIZE))) #define UNION_ROOM_PARTY_SIZE 2 // capacities of various saveblock objects From 63156b4398213bc89fb6666f2126f751902a4d84 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Fri, 16 Sep 2022 20:24:26 -0300 Subject: [PATCH 06/15] Removed malloc macro --- gflib/malloc.h | 1 - src/decoration.c | 2 +- src/diploma.c | 2 +- src/easy_chat.c | 2 +- src/event_object_movement.c | 2 +- src/field_region_map.c | 2 +- src/link.c | 2 +- src/record_mixing.c | 6 +++--- src/region_map.c | 2 +- src/tv.c | 4 ++-- 10 files changed, 12 insertions(+), 13 deletions(-) diff --git a/gflib/malloc.h b/gflib/malloc.h index 8d49e0be7..27004adf7 100644 --- a/gflib/malloc.h +++ b/gflib/malloc.h @@ -2,7 +2,6 @@ #define GUARD_ALLOC_H #define HEAP_SIZE 0x1C000 -#define malloc Alloc #define calloc(ct, sz) AllocZeroed((ct) * (sz)) #define free Free diff --git a/src/decoration.c b/src/decoration.c index c5c7c02c3..2384daa80 100644 --- a/src/decoration.c +++ b/src/decoration.c @@ -2060,7 +2060,7 @@ static u8 AddDecorationIconObjectFromIconTable(u16 tilesTag, u16 paletteTag, u8 palette.data = GetDecorationIconPicOrPalette(decor, 1); palette.tag = paletteTag; LoadCompressedSpritePalette(&palette); - template = malloc(sizeof(struct SpriteTemplate)); + template = Alloc(sizeof(struct SpriteTemplate)); *template = gItemIconSpriteTemplate; template->tileTag = tilesTag; template->paletteTag = paletteTag; diff --git a/src/diploma.c b/src/diploma.c index ce31578dc..a30d71554 100644 --- a/src/diploma.c +++ b/src/diploma.c @@ -73,7 +73,7 @@ void CB2_ShowDiploma(void) ResetPaletteFade(); FreeAllSpritePalettes(); LoadPalette(sDiplomaPalettes, 0, 64); - sDiplomaTilemapPtr = malloc(0x1000); + sDiplomaTilemapPtr = Alloc(0x1000); InitDiplomaBg(); InitDiplomaWindow(); ResetTempTileDataBuffers(); diff --git a/src/easy_chat.c b/src/easy_chat.c index ebc843b3c..054c65c0f 100644 --- a/src/easy_chat.c +++ b/src/easy_chat.c @@ -1627,7 +1627,7 @@ static bool8 InitEasyChatScreenStruct(u8 type, u16 *words, u8 displayedPersonTyp u8 templateId; int i; - sEasyChatScreen = malloc(sizeof(*sEasyChatScreen)); + sEasyChatScreen = Alloc(sizeof(*sEasyChatScreen)); if (sEasyChatScreen == NULL) return FALSE; diff --git a/src/event_object_movement.c b/src/event_object_movement.c index a63eeb22b..83f12c4bb 100644 --- a/src/event_object_movement.c +++ b/src/event_object_movement.c @@ -1537,7 +1537,7 @@ u8 CreateObjectGraphicsSprite(u16 graphicsId, void (*callback)(struct Sprite *), struct Sprite *sprite; u8 spriteId; - spriteTemplate = malloc(sizeof(struct SpriteTemplate)); + spriteTemplate = Alloc(sizeof(struct SpriteTemplate)); CopyObjectGraphicsInfoToSpriteTemplate(graphicsId, callback, spriteTemplate, &subspriteTables); if (spriteTemplate->paletteTag != TAG_NONE) LoadObjectEventPalette(spriteTemplate->paletteTag); diff --git a/src/field_region_map.c b/src/field_region_map.c index 5e14920fb..43055174f 100644 --- a/src/field_region_map.c +++ b/src/field_region_map.c @@ -92,7 +92,7 @@ static const struct WindowTemplate sFieldRegionMapWindowTemplates[] = void FieldInitRegionMap(MainCallback callback) { SetVBlankCallback(NULL); - sFieldRegionMapHandler = malloc(sizeof(*sFieldRegionMapHandler)); + sFieldRegionMapHandler = Alloc(sizeof(*sFieldRegionMapHandler)); sFieldRegionMapHandler->state = 0; sFieldRegionMapHandler->callback = callback; SetMainCallback2(MCB2_InitRegionMapRegisters); diff --git a/src/link.c b/src/link.c index 57e33c811..b01be9d89 100644 --- a/src/link.c +++ b/src/link.c @@ -1608,7 +1608,7 @@ void CB2_LinkError(void) SetVBlankCallback(VBlankCB_LinkError); ResetBgsAndClearDma3BusyFlags(0); InitBgsFromTemplates(0, sLinkErrorBgTemplates, ARRAY_COUNT(sLinkErrorBgTemplates)); - sLinkErrorBgTilemapBuffer = tilemapBuffer = malloc(BG_SCREEN_SIZE); + sLinkErrorBgTilemapBuffer = tilemapBuffer = Alloc(BG_SCREEN_SIZE); SetBgTilemapBuffer(1, tilemapBuffer); if (InitWindows(sLinkErrorWindowTemplates)) { diff --git a/src/record_mixing.c b/src/record_mixing.c index c899db25e..72edd52f2 100644 --- a/src/record_mixing.c +++ b/src/record_mixing.c @@ -315,8 +315,8 @@ static void Task_RecordMixing_Main(u8 taskId) switch (tState) { case 0: // init - sSentRecord = malloc(sizeof(*sSentRecord)); - sReceivedRecords = malloc(sizeof(*sReceivedRecords) * MAX_LINK_PLAYERS); + sSentRecord = Alloc(sizeof(*sSentRecord)); + sReceivedRecords = Alloc(sizeof(*sReceivedRecords) * MAX_LINK_PLAYERS); SetLocalLinkPlayerId(gSpecialVar_0x8005); VarSet(VAR_TEMP_0, 1); sReadyToReceive = FALSE; @@ -689,7 +689,7 @@ static void ReceiveLilycoveLadyData(LilycoveLady *records, size_t recordSize, u8 if (GetLilycoveLadyId() == 0) { - lilycoveLady = malloc(sizeof(*lilycoveLady)); + lilycoveLady = Alloc(sizeof(*lilycoveLady)); if (lilycoveLady == NULL) return; diff --git a/src/region_map.c b/src/region_map.c index a4db1cb04..8157f8a4e 100644 --- a/src/region_map.c +++ b/src/region_map.c @@ -1664,7 +1664,7 @@ void CB2_OpenFlyMap(void) SetGpuReg(REG_OFFSET_BG2HOFS, 0); SetGpuReg(REG_OFFSET_BG3HOFS, 0); SetGpuReg(REG_OFFSET_BG3VOFS, 0); - sFlyMap = malloc(sizeof(*sFlyMap)); + sFlyMap = Alloc(sizeof(*sFlyMap)); if (sFlyMap == NULL) { SetMainCallback2(CB2_ReturnToFieldWithOpenMenu); diff --git a/src/tv.c b/src/tv.c index 0c394acf7..fe663bb35 100644 --- a/src/tv.c +++ b/src/tv.c @@ -3450,7 +3450,7 @@ void ReceiveTvShowsData(void *src, u32 size, u8 playersLinkId) TVShow (*rmBuffer2)[MAX_LINK_PLAYERS][TV_SHOWS_COUNT]; TVShow (*rmBuffer)[MAX_LINK_PLAYERS][TV_SHOWS_COUNT]; - rmBuffer2 = malloc(MAX_LINK_PLAYERS * TV_SHOWS_COUNT * sizeof(TVShow)); + rmBuffer2 = Alloc(MAX_LINK_PLAYERS * TV_SHOWS_COUNT * sizeof(TVShow)); if (rmBuffer2 != NULL) { for (i = 0; i < MAX_LINK_PLAYERS; i++) @@ -3835,7 +3835,7 @@ void ReceivePokeNewsData(void *src, u32 size, u8 playersLinkId) PokeNews (*rmBuffer2)[MAX_LINK_PLAYERS][POKE_NEWS_COUNT]; PokeNews (*rmBuffer)[MAX_LINK_PLAYERS][POKE_NEWS_COUNT]; - rmBuffer2 = malloc(MAX_LINK_PLAYERS * POKE_NEWS_COUNT * sizeof(PokeNews)); + rmBuffer2 = Alloc(MAX_LINK_PLAYERS * POKE_NEWS_COUNT * sizeof(PokeNews)); if (rmBuffer2 != NULL) { for (i = 0; i < MAX_LINK_PLAYERS; i++) From e412ec30a0d9ddcf1a1cc427488fdc8279ae08a6 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Fri, 16 Sep 2022 20:34:22 -0300 Subject: [PATCH 07/15] Removed calloc macro --- gflib/malloc.h | 1 - src/frontier_util.c | 6 +++--- src/link_rfu_3.c | 2 +- src/mail.c | 2 +- src/secret_base.c | 2 +- src/tv.c | 2 +- 6 files changed, 7 insertions(+), 8 deletions(-) diff --git a/gflib/malloc.h b/gflib/malloc.h index 27004adf7..e21bd5a2c 100644 --- a/gflib/malloc.h +++ b/gflib/malloc.h @@ -2,7 +2,6 @@ #define GUARD_ALLOC_H #define HEAP_SIZE 0x1C000 -#define calloc(ct, sz) AllocZeroed((ct) * (sz)) #define free Free #define FREE_AND_SET_NULL(ptr) \ diff --git a/src/frontier_util.c b/src/frontier_util.c index f5dde452f..7906df736 100644 --- a/src/frontier_util.c +++ b/src/frontier_util.c @@ -2271,7 +2271,7 @@ static void Fill1PRecords(struct RankingHall1P *dst, s32 hallFacilityId, s32 lvl { s32 i, j; struct RankingHall1P record1P[HALL_RECORDS_COUNT + 1]; - struct PlayerHallRecords *playerHallRecords = calloc(1, sizeof(struct PlayerHallRecords)); + struct PlayerHallRecords *playerHallRecords = AllocZeroed(sizeof(struct PlayerHallRecords)); GetPlayerHallRecords(playerHallRecords); for (i = 0; i < HALL_RECORDS_COUNT; i++) @@ -2305,7 +2305,7 @@ static void Fill2PRecords(struct RankingHall2P *dst, s32 lvlMode) { s32 i, j; struct RankingHall2P record2P[HALL_RECORDS_COUNT + 1]; - struct PlayerHallRecords *playerHallRecords = calloc(1, sizeof(struct PlayerHallRecords)); + struct PlayerHallRecords *playerHallRecords = AllocZeroed(sizeof(struct PlayerHallRecords)); GetPlayerHallRecords(playerHallRecords); for (i = 0; i < HALL_RECORDS_COUNT; i++) @@ -2421,7 +2421,7 @@ void ClearRankingHallRecords(void) void SaveGameFrontier(void) { s32 i; - struct Pokemon *monsParty = calloc(PARTY_SIZE, sizeof(struct Pokemon)); + struct Pokemon *monsParty = AllocZeroed(sizeof(struct Pokemon) * PARTY_SIZE); for (i = 0; i < PARTY_SIZE; i++) monsParty[i] = gPlayerParty[i]; diff --git a/src/link_rfu_3.c b/src/link_rfu_3.c index 0825daea2..26102a8c3 100644 --- a/src/link_rfu_3.c +++ b/src/link_rfu_3.c @@ -913,7 +913,7 @@ void SaveLinkTrainerNames(void) s32 j; s32 nextSpace; s32 connectedTrainerRecordIndices[MAX_RFU_PLAYERS]; - struct TrainerNameRecord *newRecords = calloc(ARRAY_COUNT(gSaveBlock1Ptr->trainerNameRecords), sizeof(struct TrainerNameRecord)); + struct TrainerNameRecord *newRecords = AllocZeroed(sizeof(gSaveBlock1Ptr->trainerNameRecords)); // Check if we already have a record saved for connected trainers. for (i = 0; i < GetLinkPlayerCount(); i++) diff --git a/src/mail.c b/src/mail.c index 651fcbb84..f1e4fbedf 100644 --- a/src/mail.c +++ b/src/mail.c @@ -448,7 +448,7 @@ void ReadMail(struct Mail *mail, void (*exitCallback)(void), bool8 hasText) u16 buffer[2]; u16 species; - sMailRead = calloc(1, sizeof(*sMailRead)); + sMailRead = AllocZeroed(sizeof(*sMailRead)); sMailRead->language = GAME_LANGUAGE; sMailRead->international = TRUE; sMailRead->parserSingle = CopyEasyChatWord; diff --git a/src/secret_base.c b/src/secret_base.c index 74129d3ff..7459ba66b 100644 --- a/src/secret_base.c +++ b/src/secret_base.c @@ -921,7 +921,7 @@ static void Task_ShowSecretBaseRegistryMenu(u8 taskId) tSelectedRow = 0; tScrollOffset = 0; ClearDialogWindowAndFrame(0, FALSE); - sRegistryMenu = calloc(1, sizeof(*sRegistryMenu)); + sRegistryMenu = AllocZeroed(sizeof(*sRegistryMenu)); tMainWindowId = AddWindow(&sRegistryWindowTemplates[0]); BuildRegistryMenuItems(taskId); FinalizeRegistryMenu(taskId); diff --git a/src/tv.c b/src/tv.c index fe663bb35..530dd5d94 100644 --- a/src/tv.c +++ b/src/tv.c @@ -3966,7 +3966,7 @@ static void TranslateShowNames(TVShow *show, u32 language) int i; TVShow **shows; - shows = calloc(11, sizeof(TVShow *)); + shows = AllocZeroed(sizeof(TVShow *) * 11); for (i = 0; i < LAST_TVSHOW_IDX; i++) { switch (show[i].common.kind) From 8a68596b6436a28fee13cc216aed290736b3156d Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Fri, 16 Sep 2022 20:36:44 -0300 Subject: [PATCH 08/15] Removed free macro --- gflib/malloc.h | 3 +-- src/battle_pike.c | 4 ++-- src/battle_pyramid.c | 8 ++++---- src/decoration.c | 8 ++++---- src/event_object_movement.c | 2 +- src/frontier_util.c | 6 +++--- src/link_rfu_3.c | 2 +- src/record_mixing.c | 6 +++--- src/recorded_battle.c | 4 ++-- src/secret_base.c | 2 +- src/tv.c | 6 +++--- src/union_room.c | 10 +++++----- 12 files changed, 30 insertions(+), 31 deletions(-) diff --git a/gflib/malloc.h b/gflib/malloc.h index e21bd5a2c..851db83a6 100644 --- a/gflib/malloc.h +++ b/gflib/malloc.h @@ -2,11 +2,10 @@ #define GUARD_ALLOC_H #define HEAP_SIZE 0x1C000 -#define free Free #define FREE_AND_SET_NULL(ptr) \ { \ - free(ptr); \ + Free(ptr); \ ptr = NULL; \ } diff --git a/src/battle_pike.c b/src/battle_pike.c index 139ea497b..4f9af98ea 100644 --- a/src/battle_pike.c +++ b/src/battle_pike.c @@ -1084,7 +1084,7 @@ static u8 GetNextRoomType(void) } nextRoomType = roomCandidates[Random() % numRoomCandidates]; - free(roomCandidates); + Free(roomCandidates); if (nextRoomType == PIKE_ROOM_STATUS) TryInflictRandomStatus(); @@ -1363,7 +1363,7 @@ static void SetHintedRoom(void) } gSaveBlock2Ptr->frontier.pikeHintedRoomType = roomCandidates[Random() % count]; - free(roomCandidates); + Free(roomCandidates); if (gSaveBlock2Ptr->frontier.pikeHintedRoomType == PIKE_ROOM_STATUS && !AtLeastOneHealthyMon()) gSaveBlock2Ptr->frontier.pikeHintedRoomType = PIKE_ROOM_NPC; if (gSaveBlock2Ptr->frontier.pikeHintedRoomType == PIKE_ROOM_DOUBLE_BATTLE && !AtLeastTwoAliveMons()) diff --git a/src/battle_pyramid.c b/src/battle_pyramid.c index 6e8c6a37e..cbc1589bd 100644 --- a/src/battle_pyramid.c +++ b/src/battle_pyramid.c @@ -1568,7 +1568,7 @@ void GenerateBattlePyramidFloorLayout(u16 *backupMapData, bool8 setPlayerPositio } } RunOnLoadMapScript(); - free(floorLayoutOffsets); + Free(floorLayoutOffsets); } void LoadBattlePyramidObjectEventTemplates(void) @@ -1697,7 +1697,7 @@ static void SetPyramidObjectPositionsUniformly(u8 objType) } while (!(bits & 4) && TrySetPyramidObjectEventPositionInSquare(objType, floorLayoutOffsets, squareId, objectStartIndex + i)); bits &= 1; } - free(floorLayoutOffsets); + Free(floorLayoutOffsets); } static bool8 SetPyramidObjectPositionsInAndNearSquare(u8 objType, u8 squareId) @@ -1760,7 +1760,7 @@ static bool8 SetPyramidObjectPositionsInAndNearSquare(u8 objType, u8 squareId) r7 &= 1; } #ifdef BUGFIX - free(floorLayoutOffsets); + Free(floorLayoutOffsets); #endif return (numObjects / 2) > numPlacedObjects; @@ -1814,7 +1814,7 @@ static bool8 SetPyramidObjectPositionsNearSquare(u8 objType, u8 squareId) break; } #ifdef BUGFIX - free(floorLayoutOffsets); + Free(floorLayoutOffsets); #endif return (numObjects / 2) > numPlacedObjects; diff --git a/src/decoration.c b/src/decoration.c index 2384daa80..cd3e185da 100644 --- a/src/decoration.c +++ b/src/decoration.c @@ -1000,7 +1000,7 @@ static void HandleDecorationItemsMenuInput(u8 taskId) DestroyListMenuTask(tMenuTaskId, &sDecorationsScrollOffset, &sDecorationsCursorPos); RemoveDecorationWindow(WINDOW_DECORATION_CATEGORIES); RemoveDecorationItemsOtherWindows(); - free(sDecorationItemsMenu); + Free(sDecorationItemsMenu); sSecretBasePC_SelectedDecorationActions[tDecorationMenuCommand][0](taskId); break; } @@ -1161,7 +1161,7 @@ static void DecorationItemsMenuAction_Cancel(u8 taskId) RemoveDecorationItemsScrollIndicators(); RemoveDecorationItemsOtherWindows(); DestroyListMenuTask(tMenuTaskId, NULL, NULL); - free(sDecorationItemsMenu); + Free(sDecorationItemsMenu); ReinitDecorationCategoriesWindow(taskId); } @@ -2066,7 +2066,7 @@ static u8 AddDecorationIconObjectFromIconTable(u16 tilesTag, u16 paletteTag, u8 template->paletteTag = paletteTag; spriteId = CreateSprite(template, 0, 0, 0); FreeItemIconTemporaryBuffers(); - free(template); + Free(template); return spriteId; } @@ -2105,7 +2105,7 @@ static u8 AddDecorationIconObjectFromObjectEvent(u16 tilesTag, u16 paletteTag, u template->tileTag = tilesTag; template->paletteTag = paletteTag; spriteId = CreateSprite(template, 0, 0, 0); - free(template); + Free(template); } else { diff --git a/src/event_object_movement.c b/src/event_object_movement.c index 83f12c4bb..1e8668d55 100644 --- a/src/event_object_movement.c +++ b/src/event_object_movement.c @@ -1543,7 +1543,7 @@ u8 CreateObjectGraphicsSprite(u16 graphicsId, void (*callback)(struct Sprite *), LoadObjectEventPalette(spriteTemplate->paletteTag); spriteId = CreateSprite(spriteTemplate, x, y, subpriority); - free(spriteTemplate); + Free(spriteTemplate); if (spriteId != MAX_SPRITES && subspriteTables != NULL) { diff --git a/src/frontier_util.c b/src/frontier_util.c index 7906df736..686b69388 100644 --- a/src/frontier_util.c +++ b/src/frontier_util.c @@ -2298,7 +2298,7 @@ static void Fill1PRecords(struct RankingHall1P *dst, s32 hallFacilityId, s32 lvl record1P[highestId].winStreak = 0; } - free(playerHallRecords); + Free(playerHallRecords); } static void Fill2PRecords(struct RankingHall2P *dst, s32 lvlMode) @@ -2332,7 +2332,7 @@ static void Fill2PRecords(struct RankingHall2P *dst, s32 lvlMode) record2P[highestId].winStreak = 0; } - free(playerHallRecords); + Free(playerHallRecords); } static void PrintHallRecords(s32 hallFacilityId, s32 lvlMode) @@ -2436,7 +2436,7 @@ void SaveGameFrontier(void) for (i = 0; i < PARTY_SIZE; i++) gPlayerParty[i] = monsParty[i]; - free(monsParty); + Free(monsParty); } // Frontier Brain functions. diff --git a/src/link_rfu_3.c b/src/link_rfu_3.c index 26102a8c3..0d028cd48 100644 --- a/src/link_rfu_3.c +++ b/src/link_rfu_3.c @@ -955,7 +955,7 @@ void SaveLinkTrainerNames(void) // Finalize the new list, and clean up. memcpy(gSaveBlock1Ptr->trainerNameRecords, newRecords, sizeof(gSaveBlock1Ptr->trainerNameRecords)); - free(newRecords); + Free(newRecords); } } diff --git a/src/record_mixing.c b/src/record_mixing.c index 72edd52f2..5d75f3fc8 100644 --- a/src/record_mixing.c +++ b/src/record_mixing.c @@ -358,8 +358,8 @@ static void Task_RecordMixing_Main(u8 taskId) case 5: // Wait for the task created by CreateTask_ReestablishCableClubLink if (!gTasks[tLinkTaskId].isActive) { - free(sReceivedRecords); - free(sSentRecord); + Free(sReceivedRecords); + Free(sSentRecord); SetLinkWaitingForScript(); if (gWirelessCommType != 0) CreateTask(Task_ReturnToFieldRecordMixing, 10); @@ -705,7 +705,7 @@ static void ReceiveLilycoveLadyData(LilycoveLady *records, size_t recordSize, u8 if (lilycoveLady != NULL) { QuizLadyClearQuestionForRecordMix(lilycoveLady); - free(lilycoveLady); + Free(lilycoveLady); } } diff --git a/src/recorded_battle.c b/src/recorded_battle.c index e8785b5f8..dead1dd7e 100644 --- a/src/recorded_battle.c +++ b/src/recorded_battle.c @@ -475,8 +475,8 @@ bool32 MoveRecordedBattleToSaveData(void) break; } - free(battleSave); - free(savSection); + Free(battleSave); + Free(savSection); return ret; } diff --git a/src/secret_base.c b/src/secret_base.c index 7459ba66b..ea1999343 100644 --- a/src/secret_base.c +++ b/src/secret_base.c @@ -1006,7 +1006,7 @@ static void HandleRegistryMenuInput(u8 taskId) ClearWindowTilemap(tMainWindowId); RemoveWindow(tMainWindowId); ScheduleBgCopyTilemapToVram(0); - free(sRegistryMenu); + Free(sRegistryMenu); GoToSecretBasePCRegisterMenu(taskId); break; default: diff --git a/src/tv.c b/src/tv.c index 530dd5d94..b32881d09 100644 --- a/src/tv.c +++ b/src/tv.c @@ -3488,7 +3488,7 @@ void ReceiveTvShowsData(void *src, u32 size, u8 playersLinkId) CompactTVShowArray(gSaveBlock1Ptr->tvShows); DeactivateShowsWithUnseenSpecies(); DeactivateGameCompleteShowsIfNotUnlocked(); - free(rmBuffer2); + Free(rmBuffer2); } } @@ -3861,7 +3861,7 @@ void ReceivePokeNewsData(void *src, u32 size, u8 playersLinkId) } ClearInvalidPokeNews(); ClearPokeNewsIfGameNotComplete(); - free(rmBuffer2); + Free(rmBuffer2); } } @@ -4023,7 +4023,7 @@ static void TranslateShowNames(TVShow *show, u32 language) break; } } - free(shows); + Free(shows); } void SanitizeTVShowsForRuby(TVShow *shows) diff --git a/src/union_room.c b/src/union_room.c index 7d1417671..b47ddb41c 100644 --- a/src/union_room.c +++ b/src/union_room.c @@ -3365,12 +3365,12 @@ static void Task_InitUnionRoom(u8 taskId) } break; case 4: - free(data->spawnPlayer); - free(data->playerList); - free(data->incomingParentList); - free(data->incomingChildList); + Free(data->spawnPlayer); + Free(data->playerList); + Free(data->incomingParentList); + Free(data->incomingChildList); DestroyTask(data->searchTaskId); - free(sWirelessLinkMain.uRoom); + Free(sWirelessLinkMain.uRoom); LinkRfu_Shutdown(); DestroyTask(taskId); break; From 7e112b0f0ddcc05fcbe08855114e6fea810fc3a6 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Thu, 22 Sep 2022 21:43:33 -0300 Subject: [PATCH 09/15] Added missing uses of JOY_xx macros --- src/intro.c | 2 +- src/list_menu.c | 8 ++++---- src/main.c | 6 +++--- src/title_screen.c | 4 ++-- src/union_room_chat.c | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/intro.c b/src/intro.c index b06789142..bc81bcbb6 100644 --- a/src/intro.c +++ b/src/intro.c @@ -1039,7 +1039,7 @@ static void MainCB2_Intro(void) AnimateSprites(); BuildOamBuffer(); UpdatePaletteFade(); - if (gMain.newKeys && !gPaletteFade.active) + if (gMain.newKeys != 0 && !gPaletteFade.active) SetMainCallback2(MainCB2_EndIntro); else if (gIntroFrameCounter != -1) gIntroFrameCounter++; diff --git a/src/list_menu.c b/src/list_menu.c index 64692ce1f..112fca753 100644 --- a/src/list_menu.c +++ b/src/list_menu.c @@ -440,13 +440,13 @@ s32 ListMenu_ProcessInput(u8 listTaskId) break; case LIST_MULTIPLE_SCROLL_DPAD: // note: JOY_REPEAT won't match here - leftButton = gMain.newAndRepeatedKeys & DPAD_LEFT; - rightButton = gMain.newAndRepeatedKeys & DPAD_RIGHT; + leftButton = JOY_REPEAT(DPAD_LEFT); + rightButton = JOY_REPEAT(DPAD_RIGHT); break; case LIST_MULTIPLE_SCROLL_L_R: // same as above - leftButton = gMain.newAndRepeatedKeys & L_BUTTON; - rightButton = gMain.newAndRepeatedKeys & R_BUTTON; + leftButton = JOY_REPEAT(L_BUTTON); + rightButton = JOY_REPEAT(R_BUTTON); break; } diff --git a/src/main.c b/src/main.c index 5fd236447..29494043f 100644 --- a/src/main.c +++ b/src/main.c @@ -124,8 +124,8 @@ void AgbMain() ReadKeys(); if (gSoftResetDisabled == FALSE - && (gMain.heldKeysRaw & A_BUTTON) - && (gMain.heldKeysRaw & B_START_SELECT) == B_START_SELECT) + && JOY_HELD_RAW(A_BUTTON) + && JOY_HELD_RAW(B_START_SELECT) == B_START_SELECT) { rfu_REQ_stopMode(); rfu_waitREQComplete(); @@ -278,7 +278,7 @@ static void ReadKeys(void) gMain.heldKeys |= A_BUTTON; } - if (gMain.newKeys & gMain.watchedKeysMask) + if (JOY_NEW(gMain.watchedKeysMask)) gMain.watchedKeysPressed = TRUE; } diff --git a/src/title_screen.c b/src/title_screen.c index 25a1d60d0..689c96863 100644 --- a/src/title_screen.c +++ b/src/title_screen.c @@ -634,7 +634,7 @@ static void MainCB2(void) static void Task_TitleScreenPhase1(u8 taskId) { // Skip to next phase when A, B, Start, or Select is pressed - if ((gMain.newKeys & A_B_START_SELECT) || gTasks[taskId].data[1] != 0) + if (JOY_NEW(A_B_START_SELECT) || gTasks[taskId].data[1] != 0) { gTasks[taskId].tSkipToNext = TRUE; gTasks[taskId].tCounter = 0; @@ -681,7 +681,7 @@ static void Task_TitleScreenPhase2(u8 taskId) u32 yPos; // Skip to next phase when A, B, Start, or Select is pressed - if ((gMain.newKeys & A_B_START_SELECT) || gTasks[taskId].tSkipToNext) + if (JOY_NEW(A_B_START_SELECT) || gTasks[taskId].tSkipToNext) { gTasks[taskId].tSkipToNext = TRUE; gTasks[taskId].tCounter = 0; diff --git a/src/union_room_chat.c b/src/union_room_chat.c index 5c26d1ea3..e1ca7c0b0 100755 --- a/src/union_room_chat.c +++ b/src/union_room_chat.c @@ -1044,7 +1044,7 @@ static void Chat_HandleInput(void) { SetChatFunction(CHAT_FUNC_SWITCH); } - else if (gMain.newAndRepeatedKeys & B_BUTTON) + else if (JOY_REPEAT(B_BUTTON)) { if (sChat->bufferCursorPos) { From 44a5a8d31e5920c7f2eab588f772dd13ff7ff5f1 Mon Sep 17 00:00:00 2001 From: sbird Date: Fri, 23 Sep 2022 03:22:57 +0200 Subject: [PATCH 10/15] [debug] fix AGBAssert for AGBPrintf debug block --- include/gba/isagbprint.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/gba/isagbprint.h b/include/gba/isagbprint.h index abe7fb210..2fb860be9 100644 --- a/include/gba/isagbprint.h +++ b/include/gba/isagbprint.h @@ -39,7 +39,7 @@ void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopP void AGBPrintInit(void); #define DebugPrintf(pBuf, ...) AGBPrintf(const char *pBuf, ...) #define AGB_ASSERT(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, 1) -#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 0) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, 0) // Not used in this configuration #define MgbaOpen() From 22329d3318cde3f07ed5401226c0df2b5d951957 Mon Sep 17 00:00:00 2001 From: sbird Date: Fri, 23 Sep 2022 03:23:44 +0200 Subject: [PATCH 11/15] [debug] use boolean constants for nStopProgram --- include/gba/isagbprint.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/include/gba/isagbprint.h b/include/gba/isagbprint.h index 2fb860be9..37e2bb080 100644 --- a/include/gba/isagbprint.h +++ b/include/gba/isagbprint.h @@ -17,8 +17,8 @@ void MgbaClose(void); void MgbaPrintf(const char *pBuf, ...); void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); #define DebugPrintf(pBuf, ...) MgbaPrintf(pBuf, __VA_ARGS__) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, 1) -#define AGB_WARNING(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, 0) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, TRUE) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, FALSE) // Not used in this configuration #define AGBPrintfInit() @@ -26,8 +26,8 @@ void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nS void NoCashGBAPrintf(const char *pBuf, ...) void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) #define DebugPrintf(pBuf, ...) NoCashGBAPrintf(pBuf, __VA_ARGS__) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 1); -#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, 0) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, TRUE); +#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, FALSE) // Not used in this configuration #define MgbaOpen() @@ -38,8 +38,8 @@ void AGBPrintf(const char *pBuf, ...); void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopProgram); void AGBPrintInit(void); #define DebugPrintf(pBuf, ...) AGBPrintf(const char *pBuf, ...) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, 1) -#define AGB_WARNING(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, 0) +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, TRUE) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, FALSE) // Not used in this configuration #define MgbaOpen() From 12670e8e3ee0ca49dd88d36e83ec698bfc7b227f Mon Sep 17 00:00:00 2001 From: sbird Date: Fri, 23 Sep 2022 03:48:58 +0200 Subject: [PATCH 12/15] [debug] simplify macros, add EX versions --- include/gba/isagbprint.h | 60 ++++++++++++++++++++-------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/include/gba/isagbprint.h b/include/gba/isagbprint.h index 37e2bb080..59518ecdf 100644 --- a/include/gba/isagbprint.h +++ b/include/gba/isagbprint.h @@ -7,52 +7,52 @@ #define DebugPrintf(pBuf, ...) #define MgbaOpen() #define MgbaClose() -#define AGB_ASSERT(exp) -#define AGB_WARNING(exp) #define AGBPrintInit() +#define DebugAssert(pFile, nLine, pExpression, nStopProgram) #else -#if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) + bool32 MgbaOpen(void); void MgbaClose(void); void MgbaPrintf(const char *pBuf, ...); void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); -#define DebugPrintf(pBuf, ...) MgbaPrintf(pBuf, __VA_ARGS__) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, TRUE) -#define AGB_WARNING(exp) (exp) ? ((void*)0) : MgbaAssert(__FILE__, __LINE__, #exp, FALSE) - -// Not used in this configuration -#define AGBPrintfInit() -#elif (LOG_HANDLER == LOG_HANDLER_NOCASH_PRINT) -void NoCashGBAPrintf(const char *pBuf, ...) -void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) -#define DebugPrintf(pBuf, ...) NoCashGBAPrintf(pBuf, __VA_ARGS__) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, TRUE); -#define AGB_WARNING(exp) (exp) ? ((void*)0) : NoCashGBAAssert(__FILE__, __LINE__, #exp, FALSE) - -// Not used in this configuration -#define MgbaOpen() -#define MgbaClose() -#define AGBPrintInit() -#else // Default to AGBPrint +void NoCashGBAPrintf(const char *pBuf, ...); +void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); void AGBPrintf(const char *pBuf, ...); void AGBAssert(const char *pFile, int nLine, const char *pExpression, int nStopProgram); void AGBPrintInit(void); + +#if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) + +#define DebugPrintf(pBuf, ...) MgbaPrintf(pBuf, __VA_ARGS__) +#define DebugAssert(pFile, nLine, pExpression, nStopProgram) MgbaAssert(pFile, nLine, pExpression, nStopProgram) + +#elif (LOG_HANDLER == LOG_HANDLER_NOCASH_PRINT) + +#define DebugPrintf(pBuf, ...) NoCashGBAPrintf(pBuf, __VA_ARGS__) +#define DebugAssert(pFile, nLine, pExpression, nStopProgram) NoCashGBAAssert(pFile, nLine, pExpression, nStopProgram) + +#else // Default to AGBPrint + #define DebugPrintf(pBuf, ...) AGBPrintf(const char *pBuf, ...) -#define AGB_ASSERT(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, TRUE) -#define AGB_WARNING(exp) (exp) ? ((void*)0) : AGBAssert(__FILE__, __LINE__, #exp, FALSE) +#define DebugAssert(pFile, nLine, pExpression, nStopProgram) AGBAssert(pFile, nLine, pExpression, nStopProgram) -// Not used in this configuration -#define MgbaOpen() -#define MgbaClose() #endif #endif -// for matching purposes - #ifdef NDEBUG -#define AGB_ASSERT_EX(exp, file, line) + +#define AGB_ASSERT(exp) +#define AGB_WARNING(exp) +#define AGB_ASSERT_EX(exp, file, line) +#define AGB_WARNING_EX(exp, file, line) + #else -#define AGB_ASSERT_EX(exp, file, line) AGB_ASSERT(exp); + +#define AGB_ASSERT(exp) (exp) ? ((void*)0) : DebugAssert(__FILE__, __LINE__, #exp, TRUE) +#define AGB_WARNING(exp) (exp) ? ((void*)0) : DebugAssert(__FILE__, __LINE__, #exp, FALSE) + +#define AGB_WARNING_EX(exp, file, line) (exp) ? ((void *)0) : DebugAssert(file, line, #exp, FALSE); +#define AGB_ASSERT_EX(exp, file, line) (exp) ? ((void *)0) : DebugAssert(file, line, #exp, TRUE); #endif #endif // GUARD_GBA_ISAGBPRINT_H From 343d7f7d269be96fbc82be6b421bdc657fa79979 Mon Sep 17 00:00:00 2001 From: sbird Date: Fri, 23 Sep 2022 04:02:30 +0200 Subject: [PATCH 13/15] [debug] do not use heap allocation for MgbaPrintf --- include/gba/isagbprint.h | 10 ++++++-- src/libisagbprn.c | 50 +++------------------------------------- 2 files changed, 11 insertions(+), 49 deletions(-) diff --git a/include/gba/isagbprint.h b/include/gba/isagbprint.h index 59518ecdf..91aa9f214 100644 --- a/include/gba/isagbprint.h +++ b/include/gba/isagbprint.h @@ -3,6 +3,12 @@ #include "gba/types.h" +#define MGBA_LOG_FATAL (0) +#define MGBA_LOG_ERROR (1) +#define MGBA_LOG_WARN (2) +#define MGBA_LOG_INFO (3) +#define MGBA_LOG_DEBUG (4) + #ifdef NDEBUG #define DebugPrintf(pBuf, ...) #define MgbaOpen() @@ -13,7 +19,7 @@ bool32 MgbaOpen(void); void MgbaClose(void); -void MgbaPrintf(const char *pBuf, ...); +void MgbaPrintf(s32 level, const char *pBuf, ...); void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); void NoCashGBAPrintf(const char *pBuf, ...); void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram); @@ -23,7 +29,7 @@ void AGBPrintInit(void); #if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) -#define DebugPrintf(pBuf, ...) MgbaPrintf(pBuf, __VA_ARGS__) +#define DebugPrintf(pBuf, ...) MgbaPrintf(MGBA_LOG_INFO, pBuf, __VA_ARGS__) #define DebugAssert(pFile, nLine, pExpression, nStopProgram) MgbaAssert(pFile, nLine, pExpression, nStopProgram) #elif (LOG_HANDLER == LOG_HANDLER_NOCASH_PRINT) diff --git a/src/libisagbprn.c b/src/libisagbprn.c index 0dbaec157..fab9b5990 100644 --- a/src/libisagbprn.c +++ b/src/libisagbprn.c @@ -211,14 +211,6 @@ void NoCashGBAAssert(const char *pFile, s32 nLine, const char *pExpression, bool // mgba print functions #if (LOG_HANDLER == LOG_HANDLER_MGBA_PRINT) -#define MGBA_PRINTF_BUFFER_SIZE (4096) - -#define MGBA_LOG_FATAL (0) -#define MGBA_LOG_ERROR (1) -#define MGBA_LOG_WARN (2) -#define MGBA_LOG_INFO (3) -#define MGBA_LOG_DEBUG (4) - #define MGBA_REG_DEBUG_MAX (256) bool32 MgbaOpen(void) @@ -232,7 +224,7 @@ void MgbaClose(void) *REG_DEBUG_ENABLE = 0; } -static void MgbaPrintfBounded(s32 level, const char* ptr, ...) +void MgbaPrintf(s32 level, const char* ptr, ...) { va_list args; @@ -249,52 +241,16 @@ static void MgbaPrintfBounded(s32 level, const char* ptr, ...) *REG_DEBUG_FLAGS = level | 0x100; } -void MgbaPrintf(const char* ptr, ...) -{ - va_list args; - u32 offset = 0; - u32 n = 0; - u32 i; - char *buffer = Alloc(MGBA_PRINTF_BUFFER_SIZE); - AGB_ASSERT(buffer != NULL); - - va_start(args, ptr); - #if (PRETTY_PRINT_HANDLER == PRETTY_PRINT_MINI_PRINTF) - n = mini_vsnprintf(buffer, MGBA_PRINTF_BUFFER_SIZE, ptr, args); - #elif (PRETTY_PRINT_HANDLER == PRETTY_PRINT_LIBC) - n = vsnprintf(buffer, MGBA_PRINTF_BUFFER_SIZE, ptr, args); - #else - #error "unspecified pretty printing handler." - #endif - va_end(args); - - AGB_ASSERT(n < MGBA_PRINTF_BUFFER_SIZE); - - do - { - for (i = 0; i < MGBA_REG_DEBUG_MAX; ++i) - { - REG_DEBUG_STRING[i] = buffer[offset + i]; - if (buffer[offset + i] == 0) - break; - } - offset += i; - *REG_DEBUG_FLAGS = MGBA_LOG_INFO | 0x100; - } while ((i == MGBA_REG_DEBUG_MAX) && (buffer[offset] != '\0')); - - Free(buffer); -} - void MgbaAssert(const char *pFile, s32 nLine, const char *pExpression, bool32 nStopProgram) { if (nStopProgram) { - MgbaPrintfBounded(MGBA_LOG_ERROR, "ASSERTION FAILED FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + MgbaPrintf(MGBA_LOG_ERROR, "ASSERTION FAILED FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); asm(".hword 0xEFFF"); } else { - MgbaPrintfBounded(MGBA_LOG_WARN, "WARING FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); + MgbaPrintf(MGBA_LOG_WARN, "WARING FILE=[%s] LINE=[%d] EXP=[%s]", pFile, nLine, pExpression); } } #endif From d8b391906383186ff1b05d1cf7167577527ef8d2 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Sat, 24 Sep 2022 18:27:53 -0400 Subject: [PATCH 14/15] Ignore Porymap's prefabs file --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index cac4a07e6..8d9502ae8 100644 --- a/.gitignore +++ b/.gitignore @@ -31,6 +31,7 @@ build/ *.ddump .idea/ porymap.project.cfg +prefabs.json .vscode/ *.a .fuse_hidden* From 0f35f080ecb8a59d3941817c6a4e236d6600cabb Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Sat, 24 Sep 2022 23:48:24 -0300 Subject: [PATCH 15/15] =?UTF-8?q?Gender=20icon=20in=20naming=20screen=20ba?= =?UTF-8?q?sed=20on=20Pok=C3=A9mon=20name=20length?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/naming_screen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/naming_screen.c b/src/naming_screen.c index b4007b265..a05e501c2 100644 --- a/src/naming_screen.c +++ b/src/naming_screen.c @@ -1771,7 +1771,7 @@ static void DrawGenderIcon(void) StringCopy(text, gText_FemaleSymbol); isFemale = TRUE; } - AddTextPrinterParameterized3(sNamingScreen->windows[WIN_TEXT_ENTRY], FONT_NORMAL, 0x68, 1, sGenderColors[isFemale], TEXT_SKIP_DRAW, text); + AddTextPrinterParameterized3(sNamingScreen->windows[WIN_TEXT_ENTRY], FONT_NORMAL, (POKEMON_NAME_LENGTH * 4) + 64, 1, sGenderColors[isFemale], TEXT_SKIP_DRAW, text); } }