-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBoardSlot.cpp
More file actions
41 lines (37 loc) · 699 Bytes
/
Copy pathBoardSlot.cpp
File metadata and controls
41 lines (37 loc) · 699 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
31
32
33
34
35
36
37
38
39
40
41
#include "stdafx.h"
#include "BoardSlot.h"
BoardSlot::BoardSlot(int suit, int number, int x, int y)
{
this->suit = suit;
this->number = number;
this->x = x;
this->y = y;
switch(suit) // 0 == Spades, 1 == Clubs, 2 == Diamonds, 3 == Hearts
{
case 0:
this->card = "S";
break;
case 1:
this->card = "C";
break;
case 2:
this->card = "D";
break;
case 3:
this->card = "H";
break;
}
this->card += std::to_string(number);
teamChip = -1;
}
BoardSlot::BoardSlot(int x, int y) // Only corner pieces uses this constructor
{
this->card = "DS"; // Dead Space
this->suit = -1;
this->number = -1;
teamChip = -1;
this->x = x;
this->y = y;
}
BoardSlot::~BoardSlot()
{}