sovereignx/include/wild_encounter.h

50 lines
1.3 KiB
C
Raw Normal View History

2017-11-16 19:38:10 +00:00
#ifndef GUARD_WILD_ENCOUNTER_H
#define GUARD_WILD_ENCOUNTER_H
#include "constants/wild_encounter.h"
2017-11-18 11:27:10 +00:00
2017-11-16 19:38:10 +00:00
struct WildPokemon
{
u8 minLevel;
u8 maxLevel;
u16 species;
};
struct WildPokemonInfo
{
u8 encounterRate;
const struct WildPokemon *wildPokemon;
};
struct WildPokemonHeader
{
u8 mapGroup;
u8 mapNum;
const struct WildPokemonInfo *landMonsInfo;
const struct WildPokemonInfo *waterMonsInfo;
const struct WildPokemonInfo *rockSmashMonsInfo;
const struct WildPokemonInfo *fishingMonsInfo;
};
extern const struct WildPokemonHeader gWildMonHeaders[];
extern bool8 gIsFishingEncounter;
extern bool8 gIsSurfingEncounter;
Fishing Enhancements (#4343) * Implemented chain fishing * Added configs * I_FISHING_MINIGAME implemented * Refactored Check For Bite * CLeaned up version of metatile checks * Removed debug script * Added helper functinons * Cleaned up CalculateFishingProximityOdds * Added new constatnts for cardinal direction and axis * Updated with constants * Reordered functions * Cleaned up some functions * Moved constants * Created UpdateChainFishingSpeciesAndStreak When 3 sides are blocked, every cast will get a mon * Created DoesFishingMinigameAllowCancel * Removed fishing chain check * Fixed bug where streak was not incremented correctly Fixed bug where Land was not properly counted Fixed bug where streak was always being read as maxed * Updated variable and function names * Updated variable and function names * Moved UpdateChainFishingSpeciesAndStreak to happen before shiny rolls occur * Removed debug statements * Applied feedback from https://github.com/rh-hideout/pokeemerald-expansion/pull/4343\#discussion_r1551278416 * Fixed default item config and changed gChainFishingDexNavStreak and sLastFishingSpecies to only use EWRAM when features are enabled * Update include/config/item.h Include feedback from https://github.com/rh-hideout/pokeemerald-expansion/pull/4343#discussion_r1567145660 Co-authored-by: Bassoonian <iasperbassoonian@gmail.com> * Changed Dexnav to DexNav per https://github.com/rh-hideout/pokeemerald-expansion/pull/4343\#discussion_r1567145660 --------- Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2024-04-16 21:53:50 +01:00
extern u8 gChainFishingDexNavStreak;
2017-11-16 19:38:10 +00:00
void DisableWildEncounters(bool8 disabled);
u8 PickWildMonNature(void);
2017-11-18 11:27:10 +00:00
bool8 StandardWildEncounter(u16 currMetaTileBehavior, u16 previousMetaTileBehavior);
2017-11-16 19:38:10 +00:00
bool8 SweetScentWildEncounter(void);
bool8 DoesCurrentMapHaveFishingMons(void);
void FishingWildEncounter(u8 rod);
u16 GetLocalWildMon(bool8 *isWaterMon);
u16 GetLocalWaterMon(void);
bool8 UpdateRepelCounter(void);
bool8 TryDoDoubleWildBattle(void);
Ported TheXaman's latest changes to the Debug Menu (#2815) * Added option for generating incrementing pokemon in pc boxes # Conflicts: # src/debug.c * added submenu arrows, increased menu high to full screen # Conflicts: # src/debug.c * combined flags and vars into one submenu # Conflicts: # src/debug.c * added new window to flags/vars showing the current state and added submenu indicator # Conflicts: # src/debug.c * added alligned arrows for debug submenus # Conflicts: # src/debug.c * used {CLEAR_TO X} instead of manual spaces # Conflicts: # src/debug.c * renamed gDebugText to proper sDebugText # Conflicts: # src/debug.c * added Fill submenu, added fill function for PC items and all bag pockets @LOuroboros # Conflicts: # src/debug.c * put cheat start into utility # Conflicts: # src/debug.c * put fill submenu into main menu # Conflicts: # src/debug.c * tiny fix * renaming and reordering # Conflicts: # src/debug.c * Added reset pokedex flags for @AsparagusEduardo * made flag toggle list dynamic # Conflicts: # src/debug.c * initial battle debug menu WIP # Conflicts: # src/debug.c # src/wild_encounter.c * fix visual bug * added battle start # Conflicts: # include/debug.h # src/battle_ai_script_commands.c * Added faster way to add initial movesets to mon * Added waiting music for the slow box filling * Simplified the call to scripts * Simplified debug scripts * Disabled Battle Test for now * Fixed personality on fast PC fill being always 0 * Removed BATTLE_ENGINE instances + added AI_FLAG_COUNT * Added missing return TRUE * Sets nickname * Changed how GetSpeciesName to how it's used upstream --------- Co-authored-by: TheXaman <48356183+TheXaman@users.noreply.github.com>
2023-07-18 08:17:03 +01:00
bool8 StandardWildEncounter_Debug(void);
Fishing Enhancements (#4343) * Implemented chain fishing * Added configs * I_FISHING_MINIGAME implemented * Refactored Check For Bite * CLeaned up version of metatile checks * Removed debug script * Added helper functinons * Cleaned up CalculateFishingProximityOdds * Added new constatnts for cardinal direction and axis * Updated with constants * Reordered functions * Cleaned up some functions * Moved constants * Created UpdateChainFishingSpeciesAndStreak When 3 sides are blocked, every cast will get a mon * Created DoesFishingMinigameAllowCancel * Removed fishing chain check * Fixed bug where streak was not incremented correctly Fixed bug where Land was not properly counted Fixed bug where streak was always being read as maxed * Updated variable and function names * Updated variable and function names * Moved UpdateChainFishingSpeciesAndStreak to happen before shiny rolls occur * Removed debug statements * Applied feedback from https://github.com/rh-hideout/pokeemerald-expansion/pull/4343\#discussion_r1551278416 * Fixed default item config and changed gChainFishingDexNavStreak and sLastFishingSpecies to only use EWRAM when features are enabled * Update include/config/item.h Include feedback from https://github.com/rh-hideout/pokeemerald-expansion/pull/4343#discussion_r1567145660 Co-authored-by: Bassoonian <iasperbassoonian@gmail.com> * Changed Dexnav to DexNav per https://github.com/rh-hideout/pokeemerald-expansion/pull/4343\#discussion_r1567145660 --------- Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2024-04-16 21:53:50 +01:00
void ResetChainFishingDexNavStreak(void);
bool32 IsCurrentEncounterFishing(void);
u32 CalculateChainFishingShinyRolls(void);
2017-11-16 19:38:10 +00:00
#endif // GUARD_WILD_ENCOUNTER_H