#ifndef POKEMON_APP_H #define POKEMON_APP_H #pragma once #include #include #include #include #include #include #include #define TAG "Pokemon" struct pokemon_data_table { const char* name; const Icon* icon; const uint8_t hex; }; typedef struct pokemon_data_table PokemonTable; typedef enum { GAMEBOY_INITIAL, GAMEBOY_READY, GAMEBOY_WAITING, GAMEBOY_TRADE_READY, GAMEBOY_SEND, GAMEBOY_PENDING, GAMEBOY_TRADING } render_gameboy_state_t; #if 0 struct App { Gui* gui; ViewDispatcher* view_dispatcher; SelectPokemon* select_pokemon; Trade* trade; uint32_t view_id; int current_pokemon = 0; char pokemon_hex_code = ' '; }; #endif struct pokemon_fap { Gui* gui; ViewDispatcher* view_dispatcher; /* View ports for each of the application's steps */ View* select_view; View* trade_view; /* Table of pokemon data for Gen I */ const PokemonTable* pokemon_table; /* The currently selected pokemon */ int curr_pokemon; /* Some state tracking */ /* This, combined with some globals in trade.cpp, can probably be better * consolidated at some point. */ bool trading; bool connected; render_gameboy_state_t gameboy_status; /* TODO: Other variables will end up here, like selected level, EV/IV, * moveset, etc. Likely will want to be another sub struct similar to * the actual pokemon data structure. */ }; typedef struct pokemon_fap PokemonFap; typedef enum { AppViewSelectPokemon, AppViewTrade, AppViewExitConfirm, } AppView; #endif /* POKEMON_APP_H */