robocode.control.events

Class RoundStartedEvent


public class RoundStartedEvent
extends BattleEvent

A RoundStartedEvent is sent to onRoundStarted() when a new round in a battle is started.
Authors:
Pavel Savara (original)
Flemming N. Larsen (contributor)
Since:
1.6.2
See Also:
IBattleListener, RoundEndedEvent

Constructor Summary

RoundStartedEvent(ITurnSnapshot startSnapshot, int round)
Creates a new RoundStartedEvent.

Method Summary

int
getRound()
Returns the round number.
ITurnSnapshot
getStartSnapshot()
Returns the start snapshot of the participating robots, initial starting positions etc.

Constructor Details

RoundStartedEvent

public RoundStartedEvent(ITurnSnapshot startSnapshot,
                         int round)
Creates a new RoundStartedEvent.
Parameters:
startSnapshot - the start snapshot of the participating robots, initial starting positions etc.
round - the round number.

Method Details

getRound

public int getRound()
Returns the round number.
Returns:
the round number.

getStartSnapshot

public ITurnSnapshot getStartSnapshot()
Returns the start snapshot of the participating robots, initial starting positions etc.
Returns:
a ITurnSnapshot instance that serves as the start snapshot of the round.