-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathboard.h
More file actions
30 lines (24 loc) · 684 Bytes
/
board.h
File metadata and controls
30 lines (24 loc) · 684 Bytes
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
#pragma once
#include "SFML/Graphics.hpp"
#include <iostream>
#include <vector>
#include "coin.h"
#include "gridCell.h"
using namespace std;
class Board
{
public:
Board();
void PrintBoard();
bool isInBounds(int index);
bool isValidJump(int initPos, int finalPos);
bool isFinalDestinationEmpty(int dest);
std::vector<int> ConvertPositionsToIndex(std::vector<sf::Vector2i> vec, int size);
int ConvertPositionToIndex(int pos, int size);
void MoveCoins(int initialPos, int finalPos);
void MoveCoins(std::vector<int> pos);
void SwapCoins(int initialPos, int finalPos);
Coin GetCoinFromIndex(int index);
private:
vector<Coin> board;
};