#include "potions.h" #include "constants.h" #include "potions/restore_health.h" #include "potions/boost_atk.h" #include "potions/boost_def.h" #include "potions/poison_health.h" #include "potions/wound_atk.h" #include "potions/wound_def.h" std::unique_ptr new_potion(potion_type type, const position &pos) { switch (type) { case restore_health: return std::make_unique(pos); break; case boost_atk: return std::make_unique(pos); break; case boost_def: return std::make_unique(pos); break; case poison_health: return std::make_unique(pos); break; case wound_atk: return std::make_unique(pos); break; case wound_def: return std::make_unique(pos); break; default: break; } return nullptr; }