Skip to content

Commit

Permalink
Nayru's Pokedex
Browse files Browse the repository at this point in the history
Bundled: Idain's Custom Dex Colors and Toggle Shiny Palettes, doesnt impact you if you dont want it.

REQUIRED:
Replace StatExp with EVs,
Expanded Tilesets to 255,
Unique Mon Icons (or at least adapt to the new Bank structure, actual icons used are irrelevant)

and my Gen3 Type/Status/Cat Tiles. Pokedex portion must be implemented. Other parts, optional.

FEATURES:  Base stats and info, Move Info, Detailed area info, Evoulation chart, and sprite page showing animated sprites (reflects shiny toggle too).

Move Information: Lvl-Up Moves -> Field Moves (plus lvl learned and/or TM/HM/Move Tutor) -> Egg Moves -> TMs. I have fully functional code commented out to include HMs. But I decided not to since Field Moves serve the same purpse. But, if you've messed with adding or deleting Field Moves, I reccomend scrapping the Field Moves code and restoring the HM code. Please feel free to DM about this if it's an issue. I'm working on better solutions at some point.
Move Page Future Ideas: Full Page toggle option, to show additional details about the moves, Type, power, category, accuracy, effects, etc

AREA Pages: Currently supports Johto/Kanto Walking/grass/surfing encounters plus their swarms. Fishing Rods information is also included. Right now, all it will show you is the relevant Fishing Group Name. In the near future, it will print Route information like the other pages.
To check your local Fishing Group, check your PokeGear.

POKEGEAR: Now shows the detailed name of map you're currently in (based on Map Group & Map Number) and it also reads the map's attribute to see it's fishing group, if it has one.

COMING SOON: AREA support for Headbutt Trees and Rock Smash Rocks and the Bug contest. Roaming Support for the dogs and any custom roamers.

I also have an idea to have a python script scrape all information about special event pokemon (like Celebi, Ho-oh, Lugia, Starters, Casinos, Gift pokemon like Eevee) and NPC trades and displaying that. The script should be run if you ever make edits to these and will recompile the list. I should probably do this for Field Moves too, since people can and do have custom Field Moves...

Feel Free to DM me any suggestions and feedback. If you want to help me design Tiles/GFX to help make everything easier to look at, I would be eternally grateful.

Commit Notes: newest to oldest.

I'm still not happy with field moves, having to maintain a seperate data table about the moves and if they're TM/HM/MT goes against the spirit of the project. but for now, it works, and will display the field move twice if can learn via lvl up & TM/HM/MT

pokedexpart1

need to get mon icons

pokedexpart2

Mon Icons are broken,
Evo Page is borked,
Sprite Page isnt animating

Customizable Pokédex Color

https://github.com/pret/pokecrystal/wiki/Customizable-Pok%C3%A9dex-Color

Plus changing _CGB_PokedexSearchOption: in engine/gfx/cgb_layouts.asm, ld a, PREDEFPAL_POKEDEX -> call CheckPokedexColor

pokedex Restore EV code

Pokedex, fixed animations

reflected the latest commit that changed sprite stuff, copied the relevant old funcs from lilikoi and updated to the new Constants

pret#1055

Pokedex: PokeGear shows fish group, cards wrap

In the Pokedex, Press start to bring up the Vanilla AREA option, and Kanto is enabled regardless of HoF

Card icons:
Test w/:
- Only clock + phone
- clock, map, phone
Need to test w/ Radio

Pokegear: forgot a few things

forgot to add check for radio when going left on clock screen

added print local fishing group name. It's ugly. Soooo much space for tiles on the pokegear!

Pokedex BETA pokegear fish str fix

just forgot the @

vanilla merged fonts

charmap for evopage

Vanilla Dex changes

Vanilla complete, short text version

cleanup

Pokedex Choose Theme Color fix

https://github.com/pret/pokecrystal/wiki/Customizable-Pok%C3%A9dex-Color

Type GFX Vanilla

GFX SETup

Battle enemy hud fix

Remember to check hall of fame for NO. tile weirdness

Minor Sync fixes with Type tiles GFX

Dex Tweaks 1 & minor tweaks

pokegear more readable, search mode and unown mode applies custom color

Added Dex Info Page

also removes the mewtwo color

Nayru's Dex 2.0

Developed originally on Crystal Legacy 1.2, rebased here for vanilla crystal with rgbasm 6.1

Fixing page counter bug for Surfing Area Dex

same fix as the walking/grass one, thanks Craig

EV code

Sorting out the EV/StatExp Handling for Stats page

Dex Area Map UI updates

wont affect pokegear and fly map

pokegear part of dex area map UI

UI Moved Type on Entry page, EVO arrows

and added up/down arrows to EVO, Current mon arrow, moved caught ball up by 1 on EVO page too

Pics page UI updates

Main UI updates

UI misc

Part 1 UI Overhaul

Part 1 UI Overhaul

UI Overhaul part 2

Moved Caught Ball Icon next to Dex #

top button banner comments

misc edits

celebi event ready

no nayru sprite

misc clean up
  • Loading branch information
Nayru62 committed Jul 30, 2024
1 parent d11c1c5 commit 262d098
Show file tree
Hide file tree
Showing 45 changed files with 9,851 additions and 618 deletions.
9 changes: 8 additions & 1 deletion charmap.asm
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
; Actual characters (from gfx/font/font_battle_extra.png)

charmap "<LV>", $6e

charmap "<DEX_LV>", $5d
charmap "<DO>", $70 ; hiragana small do, unused
charmap "◀", $71
charmap "『", $72 ; Japanese opening quote, unused
Expand All @@ -52,6 +52,7 @@

; needed for StatsScreen_PlaceShinyIcon and PrintPartyMonPage1
charmap "⁂", $3f ; gfx/stats/stats_tiles.png, tile 14
charmap "<DEX_⁂>", $64 ; gfx/stats/stats_tiles.png, tile 14

; Actual characters (from gfx/font/font.png)

Expand Down Expand Up @@ -115,6 +116,12 @@
charmap "x", $b7
charmap "y", $b8
charmap "z", $b9
charmap ">", $c0
charmap "<", $c1
charmap "=", $c2
charmap "+", $c3
charmap "<%>", $c4

charmap "┌", $ba
charmap "─", $bb
Expand Down
2 changes: 1 addition & 1 deletion constants/event_flags.asm
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
const EVENT_LAKE_OF_RAGE_EXPLAINED_WEIRD_MAGIKARP
const EVENT_LAKE_OF_RAGE_ASKED_FOR_MAGIKARP
const EVENT_LAKE_OF_RAGE_ELIXIR_ON_STANDBY
const_skip ; unused
const EVENT_CELEBI_FATEFUL_ENCOUNTER ; const_skip ; unused
const_skip ; unused
const EVENT_HEALED_MOOMOO
const EVENT_GOT_TM13_SNORE_FROM_MOOMOO_FARM
Expand Down
10 changes: 9 additions & 1 deletion constants/pokemon_data_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ DEF WATER_WILDDATA_LENGTH EQU 2 + 1 + NUM_WATERMON * 2
DEF FISHGROUP_DATA_LENGTH EQU 1 + 2 * 3

DEF NUM_ROAMMON_MAPS EQU 16 ; RoamMaps table size (see data/wild/roammon_maps.asm)
NUM_ROAMMONS EQU 2 ; G/S is three, and wram still has 3 roamers
; but Crystal only has 2. please change this if you want to use the 3rd

; treemon sets
; TreeMons indexes (see data/wild/treemons.asm)
Expand All @@ -188,7 +190,7 @@ DEF NUM_ROAMMON_MAPS EQU 16 ; RoamMaps table size (see data/wild/roammon_maps.as
const TREEMON_SET_KANTO
const TREEMON_SET_LAKE
const TREEMON_SET_FOREST
const TREEMON_SET_ROCK
; const TREEMON_SET_ROCK
DEF NUM_TREEMON_SETS EQU const_value

; treemon scores
Expand All @@ -197,6 +199,12 @@ DEF NUM_TREEMON_SETS EQU const_value
const TREEMON_SCORE_GOOD ; 1
const TREEMON_SCORE_RARE ; 2

; rock smash groups, for Nayru's pokedex
; const TREEMON_SET_ROCK is originally within NUM_TREEMON_SETS
const_def
const TREEMON_SET_ROCK
NUM_ROCKSMASH_SETS EQU const_value

; ChangeHappiness arguments (see data/events/happiness_changes.asm)
const_def 1
const HAPPINESS_GAINLEVEL ; 01
Expand Down
2 changes: 2 additions & 0 deletions constants/scgb_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
const SCGB_POKEGEAR_PALS
const SCGB_STATS_SCREEN_HP_PALS
const SCGB_POKEDEX
const SCGB_POKEDEX_EVO
const SCGB_POKEDEX_PICS
const SCGB_SLOT_MACHINE
const SCGB_BETA_TITLE_SCREEN
const SCGB_GS_INTRO
Expand Down
13 changes: 13 additions & 0 deletions constants/wram_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,19 @@ DEF AUTO_INPUT EQU $ff
const DEXMODE_ABC
const DEXMODE_UNOWN

; wPokedexColor
const_def
const DEXCOLOR_RED
const DEXCOLOR_BLUE
const DEXCOLOR_PURPLE
const DEXCOLOR_BROWN
const DEXCOLOR_GREEN
const DEXCOLOR_PINK
const DEXCOLOR_YELLOW
const DEXCOLOR_CYAN
const DEXCOLOR_GRAY
const DEXCOLOR_MEWTWO

; wMonType::
const_def
const PARTYMON ; 0
Expand Down
1,357 changes: 1,357 additions & 0 deletions data/maps/map_names.asm

Large diffs are not rendered by default.

576 changes: 288 additions & 288 deletions data/maps/maps.asm

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion data/wild/bug_contest_mons.asm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ContestMons:
ContestMons::
; %, species, min, max
db 20, CATERPIE, 7, 18
db 20, WEEDLE, 7, 18
Expand Down
100 changes: 100 additions & 0 deletions data/wild/fish.asm
Original file line number Diff line number Diff line change
Expand Up @@ -231,3 +231,103 @@ TimeFishGroups:
db HORSEA, 40, HORSEA, 40 ; 19
db TENTACOOL, 20, TENTACOOL, 20 ; 20
db TENTACOOL, 40, TENTACOOL, 40 ; 21

FishGroups_Names::
table_width 2, FishGroups_Names
dw Group1_Name
dw Group2_Name
dw Group3_Name
dw Group4_Name
dw Group5_Name
dw Group6_Name
dw Group7_Name
dw Group8_Name
dw Group9_Name
dw Group10_Name
dw Group11_Name
dw Group12_Name
dw Group13_Name
assert_table_length NUM_FISHGROUPS ; (13, NONE is not included in the count)

Group1_Name:
db " SHORE@"
Group2_Name:
db " OCEAN@"
Group3_Name:
db " LAKE@"
Group4_Name:
db " POND@"
Group5_Name:
db " DRATINI@"
Group6_Name:
db " SWARM 1@"
Group7_Name:
db " SWARM 2@"
Group8_Name:
db " GYARADOS@"
Group9_Name:
db " ROUTE 45@"
; db " DRATINI 2@"
Group10_Name:
db " WHIRL@"
Group11_Name:
db " QWILFISH@"
Group12_Name:
db " REMORAID@"
Group13_Name:
db " ROUTE 12@"
; db " QWILFISH 2@"

GetFishGroupName:
; given fishing group num in 'a'
; return str ptr in 'de'
dec a
add a ; doubles the index since ptrs are 2 bytes
ld hl, FishGroups_Names
ld d, 0
ld e, a
add hl, de
ld e, [hl]
inc hl
ld d, [hl]
ret

GetMapsFishGroup::
dec d ; map num
dec e ; map group
push de
ld d, 0
; 'e' is the map group
ld hl, MapGroupPointers
add hl, de ; since ptrs are 2 bytes, double the index
add hl, de
ld a, BANK(MapGroupPointers)
call GetFarWord
pop de
ld a, d ; map num becomes the index, do the same as map group
ld bc, MAP_LENGTH
; hl is pointing to map group ptr
call AddNTimes ; Add bc * a to hl.
; fish group is the very last byte in the entry
ld bc, MAP_LENGTH - 1
add hl, bc
ld a, BANK(MapGroupPointers)
call GetFarByte
; ld a, [hl] ; fishing group
cp FISHGROUP_NONE
jr z, .fishgroup_none
call GetFishGroupName
; ptr to fishgroup name is in de
ret
.fishgroup_none
xor a
ld d, a
ld e, a
ret

; GetNextMapName_FishGroup:
; given: Fish group
; given: page number + num already printed
; calculate the map number of next map entry with that fishing group
; get map name based on map index
; return: map name ptr in 'de'
162 changes: 162 additions & 0 deletions data/wild/non_wildmon_locations.asm
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
MACRO casinomon
; species, coins needed
db \1
dw \2
ENDM

MACRO specialencounter
; requested mon, offered mon, item, OT ID, OT name, gender requested
db \1
dw \2
map_id \3
dw \4
ENDM

CasinoMons::
; usually 3 per region, but not a hard coded limit
; region map ; 2 bytes (group/ID)
; species, coins (2 bytes)

; johto, from maps\goldenrodgamecorner.asm
map_id GOLDENROD_GAME_CORNER
casinomon ABRA, GOLDENRODGAMECORNER_ABRA_COINS
casinomon CUBONE, GOLDENRODGAMECORNER_CUBONE_COINS
casinomon WOBBUFFET, GOLDENRODGAMECORNER_WOBBUFFET_COINS
db -1
; kanto, from maps\celadongamecornerprizeroom.asm
map_id CELADON_GAME_CORNER_PRIZE_ROOM
casinomon PIKACHU, CELADONGAMECORNERPRIZEROOM_PIKACHU_COINS
casinomon PORYGON, CELADONGAMECORNERPRIZEROOM_PORYGON_COINS
casinomon LARVITAR, CELADONGAMECORNERPRIZEROOM_LARVITAR_COINS
db -1

NPCTradeMons_Locations::
; corresponds to NPCTrades:: in data\events\npc_trades.asm
table_width 2 ; map is 2 bytes
map_id GOLDENROD_DEPT_STORE_5F ; MAPGROUP_GOLDENROD, MAP_GOLDENROD_DEPT_STORE_5F
map_id VIOLET_KYLES_HOUSE ; MAPGROUP_VIOLET, MAP_VIOLET_KYLES_HOUSE
map_id OLIVINE_TIMS_HOUSE ; MAPGROUP_OLIVINE, MAP_OLIVINE_TIMS_HOUSE
map_id BLACKTHORN_EMYS_HOUSE ; MAPGROUP_BLACKTHORN, MAP_BLACKTHORN_EMYS_HOUSE
map_id PEWTER_POKECENTER_1F ; MAPGROUP_PEWTER, MAP_PEWTER_POKECENTER_1F
map_id ROUTE_14 ; MAPGROUP_FUCHSIA, MAP_ROUTE_14
map_id POWER_PLANT ; MAPGROUP_CERULEAN, MAP_POWER_PLANT
assert_table_length NUM_NPC_TRADES

EventWildMons::
; replace map_id with -1 to hide location but keep hint
; specialencounter SPECIES, EVENT_FLAG, map_id, blurb string ptr
specialencounter LAPRAS, -1, UNION_CAVE_B2F, FridayLapras_Str ; reoccurs every Friday
specialencounter SUDOWOODO, EVENT_FOUGHT_SUDOWOODO, ROUTE_36, SudowoodoEvent_Str
specialencounter GYARADOS, EVENT_LAKE_OF_RAGE_RED_GYARADOS, LAKE_OF_RAGE, ShinyGyarados_Str
specialencounter SNORLAX, EVENT_FOUGHT_SNORLAX, VERMILION_CITY, SnorlaxEvent_Str
specialencounter SUICUNE, EVENT_FOUGHT_SUICUNE, TIN_TOWER_1F, SuicuneEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
specialencounter CELEBI, EVENT_CELEBI_FATEFUL_ENCOUNTER, ILEX_FOREST, CelebiEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
specialencounter LUGIA, EVENT_FOUGHT_LUGIA, WHIRL_ISLAND_LUGIA_CHAMBER, LugiaEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
specialencounter HO_OH, EVENT_FOUGHT_HO_OH, TIN_TOWER_ROOF, HoOhEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
; specialencounter ARTICUNO, EVENT_CAUGHT_ARTICUNO, ROUTE_20, ArticunoEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
; specialencounter ZAPDOS, EVENT_CAUGHT_ZAPDOS, ROUTE_10_NORTH, ZapdosEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
; specialencounter MOLTRES, EVENT_CAUGHT_MOLTRES, VICTORY_ROAD, MoltresEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
; specialencounter MEWTWO, EVENT_CERULEAN_CAVE_B1F_MEWTWO, SILVER_CAVE_ROOM_3, MewtwoEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
; specialencounter MEW, EVENT_ROUTE_24_MEW_CAUGHT, ROUTE_24, MewEvent_Str ; will not normally be seen by player w/o Dex Splash Page, may need new EVENT constant
db -1

; LoadWildMon Dex Hints, max 18 chars per line
FridayLapras_Str:
db "Appears every"
next "FRIDAY, lonely in"
next "hidden sea cave.@"
SudowoodoEvent_Str:
db "Unassuming fake"
next "tree. Vengeful if"
next "watered. LVL 20.@"
ShinyGyarados_Str:
db "Unique rampaging"
next "Red GYARADOS."
next "LVL 30.@"
SnorlaxEvent_Str:
db "Guaranteed to be"
next "holding LEFTOVERS."
next "LVL 40.@"
SuicuneEvent_Str:
db "CLEAR BELL is the"
next "key to the hunt."
next "LVL 40.@"
CelebiEvent_Str:
db "GS BALL, deeply"
next "buried in RUINS."
next "Offer to SHRINE.@"
LugiaEvent_Str:
db "SILVER WING, dull"
next "PEWTER sheen. Mis-"
next "placed as memento.@"
HoOhEvent_Str:
db "RAINBOW WING best-"
next "owed to Trainers"
next "after FOUR trials.@"
; ArticunoEvent_Str:
; db "Waiting surrounded"
; next "by waves."
; next "LVL 60.@"
; ZapdosEvent_Str:
; db "Waiting above"
; next "electric renewal."
; next "LVL 60.@"
; MoltresEvent_Str:
; db "Waiting in the"
; next "long dark of"
; next "VICTORY. LVL 60.@"
; MewtwoEvent_Str:
; db "Not CERULEAN, but"
; next "RED and SILVER"
; next "ice. LVL 75.@"
; MewEvent_Str:
; db "Meet at nugget"
; next "bridge, with 251."
; next "LVL 60.@"

GiftMons::
; replace map_id with -1 to hide location but keep hint
; species, EVENT_FLAG, map_id, blurb string ptr
specialencounter SHUCKLE, EVENT_MANIA_TOOK_SHUCKIE_OR_LET_YOU_KEEP_HIM, MANIAS_HOUSE, ShuckieEvent_Str ; EVENT_GOT_SHUCKIE / EVENT_MANIA_TOOK_SHUCKIE_OR_LET_YOU_KEEP_HIM
specialencounter SPEAROW, EVENT_GOT_KENYA, ROUTE_35_GOLDENROD_GATE, KenyaEvent_Str
specialencounter DRATINI, EVENT_GOT_DRATINI, DRAGON_SHRINE, ExtremespeedDratini_Str
specialencounter EEVEE, EVENT_GOT_EEVEE, BILLS_FAMILYS_HOUSE, BillsEevee_Str
specialencounter TYROGUE, EVENT_GOT_TYROGUE_FROM_KIYO, MOUNT_MORTAR_1F_OUTSIDE, TyrogueEvent_Str
; specialencounter AERODACTYL,EVENT_GAVE_SCIENTIST_OLD_AMBER, RUINS_OF_ALPH_RESEARCH_CENTER, OldAmberEvent_Str
; specialencounter KABUTO, EVENT_GAVE_SCIENTIST_DOME_FOSSIL, RUINS_OF_ALPH_RESEARCH_CENTER, DomeFossil_Str
; specialencounter OMANYTE, EVENT_GAVE_SCIENTIST_HELIX_FOSSIL, RUINS_OF_ALPH_RESEARCH_CENTER, HelixFossil_Str
db -1

; GivePoke Dex Hints, max 18 chars per line
ShuckieEvent_Str:
db "Happiness over 150"
next "may inspire change"
next "of heart, forever.@"
KenyaEvent_Str:
db "Scrappy birb"
next "carrying mail"
next "for ROUTE 31.@"
ExtremespeedDratini_Str:
db "EXTREMESPEED is"
next "rewarded as a true"
next "virtue reflection.@"
BillsEevee_Str:
db "LVL 20 - Cute"
next "baby with un-"
next "limited potential.@"
TyrogueEvent_Str:
db "Gift from KIYO,"
next "Karate Expert."
next "@"
; OldAmberEvent_Str:
; db "Solve mysterious"
; next "ruins puzzle, then"
; next "revive fossil.@"
; DomeFossil_Str:
; db "Solve mysterious"
; next "ruins puzzle, then"
; next "revive fossil.@"
; HelixFossil_Str:
; db "Solve mysterious"
; next "ruins puzzle, then"
; next "revive fossil.@"
4 changes: 2 additions & 2 deletions data/wild/treemon_maps.asm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ MACRO treemon_map
db \2 ; treemon set
ENDM

TreeMonMaps:
TreeMonMaps::
treemon_map ROUTE_26, TREEMON_SET_KANTO
treemon_map ROUTE_27, TREEMON_SET_KANTO
treemon_map ROUTE_28, TREEMON_SET_CITY
Expand Down Expand Up @@ -40,7 +40,7 @@ TreeMonMaps:
treemon_map ILEX_FOREST, TREEMON_SET_FOREST
db -1

RockMonMaps:
RockMonMaps::
treemon_map CIANWOOD_CITY, TREEMON_SET_ROCK
treemon_map ROUTE_40, TREEMON_SET_ROCK
treemon_map DARK_CAVE_VIOLET_ENTRANCE, TREEMON_SET_ROCK
Expand Down
Loading

0 comments on commit 262d098

Please sign in to comment.