Skip to content

Commit d0a2993

Browse files
Write turn flatbuffer after ticks
1 parent 52f13ac commit d0a2993

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

engine/src/main/battlecode/world/InternalRobot.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -601,8 +601,6 @@ public void processEndOfTurn() {
601601
if (!indicatorString.equals("")) {
602602
this.gameWorld.getMatchMaker().addIndicatorString(this.ID, this.indicatorString);
603603
}
604-
this.gameWorld.getMatchMaker().endTurn(this.ID, this.health, this.paintAmount, this.movementCooldownTurns, this.actionCooldownTurns, this.bytecodesUsed, this.location);
605-
this.roundsAlive++;
606604

607605
if (this.getType().isRobotType()){
608606
Team owningTeam = this.gameWorld.teamFromPaint(this.gameWorld.getPaint(this.location));
@@ -627,6 +625,9 @@ public void processEndOfTurn() {
627625
if (this.paintAmount == 0 && type.isRobotType()){
628626
this.addHealth(-GameConstants.NO_PAINT_DAMAGE);
629627
}
628+
629+
this.gameWorld.getMatchMaker().endTurn(this.ID, this.health, this.paintAmount, this.movementCooldownTurns, this.actionCooldownTurns, this.bytecodesUsed, this.location);
630+
this.roundsAlive++;
630631
}
631632

632633
// *********************************

0 commit comments

Comments
 (0)