The Coordinator class is a wrapper class that provides a simplified interface for managing and controlling Starcraft II games. It allows you to set up game parameters, launch the Starcraft II application, start a game on a specific map, connect to the game, update the game state, and perform various game-related actions.
Here are some key functionalities provided by the Coordinator class:
* Initialization: The Coordinator class has multiple constructors that allow you to create an instance of the class. You can initialize it without any arguments or provide a string argument representing the path to the Starcraft II executable.
* Setting Participants: You can use the set_participants method to set the participants for the game. This method takes a list of participants as an argument, where each participant is defined by their race and other relevant information.
* Launching Starcraft II: The launch_starcraft method launches the Starcraft II application.
* Starting a Game: The start_game method starts a game on a specific map. You need to provide the path to the map as an argument.
* Connecting to the Game: The connect method allows you to connect to the game by specifying the port number.
* Updating the Game State: The update method updates the game state, including the positions and statuses of units, resources, and other game elements.
* Game Control: The all_games_ended method checks if all games have ended. The join_game method allows you to join a game. The set_real_time method sets the game to real-time mode. The leave_game method allows you to leave the current game.
These are just some of the methods provided by the Coordinator class. It serves as a central control point for managing Starcraft II games and provides an interface for interacting with the game engine.
)";
py::enum_<sc2::Race>(m,"Race","The Race enum in the provided code represents the different races in the Starcraft II game. It is used to define the race of a player or a unit. \
In Starcraft II, each race has its own unique units, buildings, and abilities. The Race enum allows you to specify the race of a player or a unit, which can be useful for various game-related operations and strategies. \
For example, if you want to set the race of a player to Zerg, you can use the Race::Zerg value. Similarly, if you want to check the race of a unit, you can compare its race with the enum values.")
The BuffID class is a wrapper class that represents the BuffID enum in the Starcraft II game. It is used to define the different buffs that can be applied to units in the game.
In Starcraft II, buffs are temporary effects that modify the behavior or attributes of units. The BuffID class allows you to specify a particular buff by its ID, which can be useful for various game-related operations and strategies.
For example, if you want to apply a specific buff to a unit, you can use the BuffID class to represent the buff and apply it to the unit. Similarly, if you want to check if a unit has a particular buff, you can compare its ID with the enum values.
The UnitTypeID class is a wrapper class that represents the UnitTypeID enum in the Starcraft II game. It is used to define the different types of units that exist in the game.
In Starcraft II, each unit has a unique type ID that identifies its unit type. The UnitTypeID class allows you to specify a particular unit type by its ID, which can be useful for various game-related operations and strategies.
For example, if you want to create a specific unit, you can use the UnitTypeID class to represent the unit type and create the unit. Similarly, if you want to check the type of a unit, you can compare its ID with the enum values.
The UpgradeID class is a wrapper class that represents the UpgradeID enum in the Starcraft II game. It is used to define the different upgrades that can be researched in the game.
In Starcraft II, upgrades are enhancements that improve the attributes or abilities of units and buildings. The UpgradeID class allows you to specify a particular upgrade by its ID, which can be useful for various game-related operations and strategies.
For example, if you want to research a specific upgrade, you can use the UpgradeID class to represent the upgrade and research it. Similarly, if you want to check if a unit or building has a particular upgrade, you can compare its ID with the enum values.
The EffectID class is a wrapper class that represents the EffectID enum in the Starcraft II game. It is used to define the different effects that can be applied to units or abilities in the game.
In Starcraft II, effects are special abilities or attributes that modify the behavior or properties of units or abilities. The EffectID class allows you to specify a particular effect by its ID, which can be useful for various game-related operations and strategies.
For example, if you want to apply a specific effect to a unit or ability, you can use the EffectID class to represent the effect and apply it. Similarly, if you want to check if a unit or ability has a particular effect, you can compare its ID with the enum values.
The AbilityID class is a wrapper class that represents the AbilityID enum in the Starcraft II game. It is used to define the different abilities that units and buildings can use in the game.
In Starcraft II, abilities are special actions or commands that units and buildings can perform. The AbilityID class allows you to specify a particular ability by its ID, which can be useful for various game-related operations and strategies.
For example, if you want to use a specific ability with a unit or building, you can use the AbilityID class to represent the ability and use it. Similarly, if you want to check if a unit or building has a particular ability, you can compare its ID with the enum values.