Skip to content

Commit 1310eca

Browse files
Fix java client bug and random winner ID
1 parent b773ee9 commit 1310eca

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Clients/Java/main.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ public void setInfo() {
9696
int x = scanner.nextInt();
9797
int y = scanner.nextInt();
9898
location = new Point(x, y); // (row, column)
99+
map.grid = new Vector<>();
99100
for (int i = 0; i < map.sightRange * map.sightRange; i++) {
100101
MapTile tile = new MapTile();
101102
tile.type = MapType.values()[scanner.nextInt()];

src/process/GameHandler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ def check_finish(self):
119119
self.end_engine = True
120120
self.winner = [1, 'Timeout']
121121
if(self.end_engine):
122-
self.winner[0] = randrange(2)
122+
self.winner[0] += randrange(2)
123123
self.winner[1] += '/random'
124124

125125
def update_info(self):

0 commit comments

Comments
 (0)