BWAPI
SnippyHolloW-BroodwarBotQ-f01ab56/src/Micro/UnitManager/UnitManager.h
Go to the documentation of this file.
00001 #pragma once
00002 #include <CSingleton.h>
00003 #include <BWAPI.h>
00004 
00005 #include <UnitGroup.h>
00006 #include <Regions.h>
00007 
00008 class UnitManager: public CSingleton<UnitManager>
00009 {
00010         friend class CSingleton<UnitManager>;
00011 
00012 private:
00016         UnitManager();
00017 
00021         ~UnitManager();
00022 
00023 protected : 
00024         std::list<BWAPI::Unit*> lUnits_;          
00025         std::list<UnitGroup*> lGroup_;            
00026         std::list<Objective*> lObjective_;        
00027         Regions* regions;
00028 
00029         /*************** Constructors and destructors ***************/
00030 
00031 public : 
00032 
00033         /************************* Accessors ************************/
00034 
00039     std::string getName() const;
00040 
00041         /************************** Update **************************/
00042 
00046         void update();
00047 
00051         void checkNewObjectives();
00052 
00056         void assignGroupToObj();
00057 
00058         /******* Modification of the list of available units ********/
00059 
00064         void onUnitCreate(BWAPI::Unit* unit);
00065 
00070         void onUnitDestroy(BWAPI::Unit* unit);
00071 };
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines