#ifndef RAGNAROK_SOURCE_CONTENTS_PETEVOLUTIONMGR_H #define RAGNAROK_SOURCE_CONTENTS_PETEVOLUTIONMGR_H #include #include #include #include struct lua_State; struct PetEvolutionRecipe { /* 0000 */ int target; /* 0004 */ std::vector> materials; }; // VTABLE: vt_00355 class CPetEvolutionMgr { public: // INLINED CPetEvolutionMgr() : m_isValid(true) { } // INLINED virtual ~CPetEvolutionMgr() { this->m_recipes.clear(); this->unknown_0010.clear(); this->m_autoFeeding.clear(); } static bool Create(); static void Destroy(); static int L_InsertEvolutionRecipeLGU(lua_State* state); static int L_InsertPetAutoFeeding(lua_State* state); std::pair> GetEvolutionTargets(int petEgg); std::pair>> GetMaterials(int petEgg, int target); bool Load(); std::pair InsertPetAutoFeeding(int petEgg); std::pair InsertRecipe(int petEgg, int target, int material, int count); bool IsAutoFeeding(int petEgg); /* 0004 */ bool m_isValid; /* 0008 */ std::map> m_recipes; /* 0010 */ std::map unknown_0010; /* 0018 */ std::vector m_autoFeeding; }; #if defined(_WIN32) && !defined(_WIN64) static_assert(sizeof(PetEvolutionRecipe) == 0x10); static_assert(sizeof(CPetEvolutionMgr) == 0x24); #endif extern CPetEvolutionMgr* g_petEvolutionMgr; #endif