SC2API
An API for AI for StarCraft II
sc2_action_raw.h
1 #pragma once
2 
3 #include "sc2_common.h"
4 #include "sc2_typeenums.h"
5 #include <vector>
6 #include <stdint.h>
7 
8 namespace sc2 {
9 
10 class ActionRaw {
11 public:
12  // Note: Target types are mutually exclusive.
13  enum TargetType {
14  TargetNone, // No target generally means 'self', e.g., a order to make a unit.
15  TargetUnitTag, // The target is a unit tag, could also be a snapshot in the fog-of-war.
16  TargetPosition // The target is a point.
17  };
18 
19  AbilityID ability_id_; // The stable id that describes the ability link and ability index.
20  std::vector<uint64_t> unit_tags_; // Units this action applies to. In normal use, this would be the currently selected units.
21  TargetType target_type_; // Which target fields are valid.
22  uint64_t target_tag_; // Valid only when target_type_ == TargetUnitTag.
23  Point2D target_point_; // Valid only when target_type_ == TargetPosition.
24 
25  ActionRaw();
26 };
27 
28 typedef std::vector<ActionRaw> RawActions;
29 
30 }
Definition: sc2_common.h:41
Definition: sc2_action_raw.h:8
A list of enums provided for your convenience.
Definition: sc2_action_raw.h:10