Blizzard / s2client-api

StarCraft II Client - C++ library supported on Windows, Linux and Mac designed for building scripted bots and research using the SC2API.
MIT License
1.66k stars 281 forks source link

Add map_name to GameInfo #153

Closed IanGallacher closed 7 years ago

IanGallacher commented 7 years ago

Adds map_name to GameInfo. Will be useful in conjunction with the sc2ai.net bot ladder. My bot specifically needs it to load map specific training data from text files.

I would also suggest changing gamesettings.map_name to gamesettings.map_path to avoid confusion. map_name will almost never match the map filename. For example, the map_name may contain spaces, and does not usually include the .SC2Map file extension.

gamesettings.map_name does not appear to be publicly exposed, so it should be safe to change. There is already an inconsistancy in Coordinator::StartGame. map_path is passed into the function, and map_name is set to it.

KevinCalderone commented 7 years ago

Looks good, thanks! Maybe we should expose local_map_path too...