-
Notifications
You must be signed in to change notification settings - Fork 0
/
MyFormationBruteforcer.h
40 lines (32 loc) · 1.01 KB
/
MyFormationBruteforcer.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#pragma once
#include "model/VehicleType.h"
#include <algorithm>
#include <vector>
using namespace std;
using xypoint = pair<int, int>;
struct FormationStep
{
model::VehicleType mVt;
xypoint mMoveFrom, mMoveTo;
};
class MyFormationBruteforcer
{
public:
void buildPathToFormation();
vector<FormationStep> getLandFormationPath() const;
vector<FormationStep> getAirFormationPath() const;
vector<xypoint> getLandFormation() const;
MyFormationBruteforcer(xypoint tankStartCell, xypoint ifvStartCell, xypoint arrvStartCell, xypoint fighterStartCell, xypoint helicopterStartCell);
~MyFormationBruteforcer();
private:
void buildLandPathToPoints(xypoint targetTankCell, xypoint targetIfvCell, xypoint targetArrvCell);
void buildAirPath();
bool mLandPathIsEmpty, mAirPathIsEmpty;
vector<FormationStep> mCurrentLandFormationPath, mCurrentAirFormationPath;
vector<xypoint> mFinalLandFormation;
xypoint mTankStartCell;
xypoint mIfvStartCell;
xypoint mArrvStartCell;
xypoint mFighterStartCell;
xypoint mHelicopterStartCell;
};