cmpsc330hw5/strategic_player1.h
Sandipsinh Rathod 6362853abd
add vec
2024-12-06 19:06:23 -05:00

34 lines
857 B
C++

#ifndef HW4_STRATEGIC_PLAYER1_H
#define HW4_STRATEGIC_PLAYER1_H
#include "common.h"
#include "board.h"
#include "player.h"
#include <vector>
class StrategicPlayer1 : public IPlayer {
char name;
char box_name;
Board board;
public:
string PlayerInfo() override;
void Init(int board_rows, int board_cols, char box_type, char line_type) override;
void Close() override;
void EventAddLine(char bar, const Loc& loc) override;
void EventAddBox(char box, const Loc& loc) override;
Loc SelectLineLocation() override;
int EvaluateMoveCost(int row, int col);
int CountBoxLines(int row, int col);
Loc FindOptimalMove();
void ListEmptyLines(vector<Loc>& empty_lines);
bool DoesMoveCompleteBox(int row, int col);
Loc FindBoxCompletingMove();
~StrategicPlayer1();
};
#endif // HW4_STRATEGIC_PLAYER1_H