-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtoken.cpp
115 lines (112 loc) · 4.4 KB
/
token.cpp
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
// #include<iostream>
// #include"token.h"
// using namespace std;
// string token::radio(array handCard, card x) {
// int index = 0;
// while (handCard[index].getColor() == x.getColor() && index <= handCard.size() - 1) {
// if (handCard[index].getNum >= x.getNum()) {
// int max = handCard[index].getNum();
// }
// else {
// int max = x.getNum();
// }
// if (handCard[index].getNum <= x.getColor()) {
// int min = handCard[index].getNum();
// }
// else {
// int min = x.getNum();
// }
// index++
// }
// if (max == min) {
// return "only";
// }
// else if (max == x.getNum()) {
// return "max";
// }
// else if (min == x.getNum()) {
// return "min";
// }
// else {
// return "wrong selection";
// }
// }
// void token::distress(string direction,int playernumber) {
// if (playernumber == 3) {
// p1DisNum = player1.getdistressnumber();
// p2DisNum = player2.getdistressnumber();
// p3DisNum = player3.getdistressnumber();
// if (direction == "r") {
// player1.gethandcard().remove(p1DisNum);
// player2.gethandcard().add(p1DisNum);
// player2.gethandcard().remove(p2DisNum);
// player3.gethandcard().add(p2DisNum);
// player3.gethandcard().remove(p3DisNum);
// player1.gethandcard().add(p3DisNum);
// }else {
// player1.gethandcard().remove(p1DisNum);
// player3.gethandcard().add(p1DisNum);
// player3.gethandcard().remove(p3DisNum);
// player2.gethandcard().add(p3DisNum);
// player2.gethandcard().remove(p2DisNum);
// player1.gethandcard().add(p2DisNum);
// }
// }
// else if (playernumber == 4) {
// p1DisNum = player1.getdistressnumber();
// p2DisNum = player2.getdistressnumber();
// p3DisNum = player3.getdistressnumber();
// p4DisNum = player4.getdistressnumber();
// if (direction == "r") {
// player1.gethandcard().remove(p1DisNum);
// player2.gethandcard().add(p1DisNum);
// player2.gethandcard().remove(p2DisNum);
// player3.gethandcard().add(p2DisNum);
// player3.gethandcard().remove(p3DisNum);
// player4.gethandcard().add(p3DisNum);
// player4.gethandcard().remove(p4DisNum);
// player1.gethandcard().add(p4DisNum);
// }
// else {
// player1.gethandcard().remove(p1DisNum);
// player4.gethandcard().add(p1DisNum);
// player4.gethandcard().remove(p4DisNum);
// player3.gethandcard().add(p4DisNum);
// player3.gethandcard().remove(p3DisNum);
// player2.gethandcard().add(p3DisNum);
// player2.gethandcard().remove(p2DisNum);
// player1.gethandcard().add(p2DisNum);
// }
// }
// else if (playernumber == 5) {
// p1DisNum = player1.getdistressnumber();
// p2DisNum = player2.getdistressnumber();
// p3DisNum = player3.getdistressnumber();
// p4DisNum = player4.getdistressnumber();
// p5DisNum = player5.getdistressnumber();
// if (direction == "r") {
// player1.gethandcard().remove(p1DisNum);
// player2.gethandcard().add(p1DisNum);
// player2.gethandcard().remove(p2DisNum);
// player3.gethandcard().add(p2DisNum);
// player3.gethandcard().remove(p3DisNum);
// player4.gethandcard().add(p3DisNum);
// player4.gethandcard().remove(p4DisNum);
// player5.gethandcard().add(p4DisNum);
// player5.gethandcard().remove(p5DisNum);
// player1.gethandcard().add(p5DisNum);
// }
// else {
// player1.gethandcard().remove(p1DisNum);
// player5.gethandcard().add(p1DisNum);
// player5.gethandcard().remove(p5DisNum);
// player4.gethandcard().add(p5DisNum);
// player4.gethandcard().remove(p4DisNum);
// player3.gethandcard().add(p4DisNum);
// player3.gethandcard().remove(p3DisNum);
// player2.gethandcard().add(p3DisNum);
// player2.gethandcard().remove(p2DisNum);
// player1.gethandcard().add(p2DisNum);
// }
// }
// }