1 package cz.cuni.amis.pogamut.ut2004.tournament.deathmatch;
2
3 import java.util.ArrayList;
4 import java.util.HashMap;
5 import java.util.List;
6 import java.util.Map;
7
8 import cz.cuni.amis.pogamut.ut2004.analyzer.stats.UT2004AnalyzerObsStats;
9 import cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.PlayerScore;
10 import cz.cuni.amis.pogamut.ut2004.tournament.match.result.UT2004IndividualMatchResult;
11 import cz.cuni.amis.pogamut.ut2004.tournament.match.result.UT2004MatchResult;
12 import cz.cuni.amis.utils.maps.HashMapMap;
13 import cz.cuni.amis.utils.token.IToken;
14
15 public class UT2004DeathMatchResult extends UT2004IndividualMatchResult {
16
17 private List<IToken> bots = new ArrayList<IToken>();
18
19 private List<IToken> nativeBots = new ArrayList<IToken>();
20
21 private Map<IToken, PlayerScore> finalScores = new HashMap<IToken, PlayerScore>();
22
23 private Map<IToken, Integer> totalKills = new HashMap<IToken, Integer>();
24
25 private Map<IToken, Integer> wasKilled = new HashMap<IToken, Integer>();
26
27 private HashMapMap<IToken, IToken, Integer> killCounts = new HashMapMap<IToken, IToken, Integer>();
28
29 private Map<IToken, Integer> suicides = new HashMap<IToken, Integer>();
30
31 private Map<IToken, UT2004AnalyzerObsStats> botObservers = new HashMap<IToken, UT2004AnalyzerObsStats>();
32
33
34
35
36 public double matchTimeEnd;
37
38 @Override
39 public String toString() {
40 return "UT2004DeathMatchResult[" + (isDraw() ? "DRAW" : ("winnerBot=" + getWinnerBot()) ) + "]";
41 }
42
43 public UT2004DeathMatchResult() {
44 super();
45 }
46
47 public UT2004DeathMatchResult(IToken winnerBot) {
48 super(winnerBot);
49 }
50
51
52
53
54
55 public List<IToken> getBots() {
56 return bots;
57 }
58
59
60
61
62
63 public void setBots(List<IToken> bots) {
64 this.bots = bots;
65 }
66
67
68
69
70
71 public List<IToken> getNativeBots() {
72 return nativeBots;
73 }
74
75
76
77
78
79 public void setNativeBots(List<IToken> nativeBots) {
80 this.nativeBots = nativeBots;
81 }
82
83
84
85
86
87 public List<IToken> getAllBots() {
88 List<IToken> all = new ArrayList<IToken>(this.bots);
89 all.addAll(this.nativeBots);
90 return all;
91 }
92
93
94
95
96 public double getMatchTimeEnd() {
97 return matchTimeEnd;
98 }
99
100
101
102
103 public void setMatchTimeEnd(double matchTimeEnd) {
104 this.matchTimeEnd = matchTimeEnd;
105 }
106
107
108
109
110
111 public Map<IToken, PlayerScore> getFinalScores() {
112 return finalScores;
113 }
114
115
116
117
118
119 public void setFinalScores(Map<IToken, PlayerScore> finalScores) {
120 this.finalScores = finalScores;
121 }
122
123
124
125
126
127 public HashMapMap<IToken, IToken, Integer> getKillCounts() {
128 return killCounts;
129 }
130
131
132
133
134
135 public void setKillCounts(HashMapMap<IToken, IToken, Integer> killCounts) {
136 this.killCounts = killCounts;
137 }
138
139
140
141
142
143
144 public Map<IToken, Integer> getTotalKills() {
145 return totalKills;
146 }
147
148
149
150
151
152 public void setTotalKills(Map<IToken, Integer> totalKills) {
153 this.totalKills = totalKills;
154 }
155
156
157
158
159
160 public Map<IToken, Integer> getWasKilled() {
161 return wasKilled;
162 }
163
164
165
166
167
168 public void setWasKilled(Map<IToken, Integer> wasKilled) {
169 this.wasKilled = wasKilled;
170 }
171
172
173
174
175
176 public Map<IToken, Integer> getSuicides() {
177 return suicides;
178 }
179
180
181
182
183
184 public void setSuicides(Map<IToken, Integer> suicides) {
185 this.suicides = suicides;
186 }
187
188
189
190
191
192 public Map<IToken, UT2004AnalyzerObsStats> getBotObservers() {
193 return botObservers;
194 }
195
196
197
198
199
200 public void setBotObservers(Map<IToken, UT2004AnalyzerObsStats> botObservers) {
201 this.botObservers = botObservers;
202 }
203
204 }