Closed pedronahum closed 5 years ago
Closing this, as there is an indirect way to obtain the race.
auto game_info = obs->GetGameInfo();
std::vector<sc2::PlayerInfo> player_information = game_info.player_info;
auto which_race = player_information[0].race_actual;
std::cout << "Player Race:" << which_race << std::endl;
Hi,
I couldn't find a way to extract from a replay the race of the player (and of the corresponding opponent). It seems that only the Player ID is exposed in the ObservationInterface.
obs->GetUnitTypeData()
could be used to create a logic to obtain the race of the player, but was wondering if there is a simpler way.Thanks!!!