#ifndef PKMNLIB_AI_AIRESOLVER_HPP #define PKMNLIB_AI_AIRESOLVER_HPP #include "../src/DepthSearchAI.hpp" #include "../src/NaiveAI.hpp" #include "../src/PokemonAI.hpp" #include "../src/RandomAI.hpp" class AIResolver { public: static PkmnLibAI::PokemonAI* Resolve(const ArbUt::StringView& name) { switch (name) { case "random"_cnc: return new PkmnLibAI::RandomAI(); case "depthsearch"_cnc: return new PkmnLibAI::DepthSearchAI(); case "naive"_cnc: return new PkmnLibAI::NaiveAI(); default: throw ArbUt::Exception("Unknown AI name."); } } }; #endif // PKMNLIB_AI_AIRESOLVER_HPP