Package megamek.common.event
Class GameTurnChangeEvent
java.lang.Object
java.util.EventObject
megamek.common.event.GameEvent
megamek.common.event.player.GamePlayerEvent
megamek.common.event.GameTurnChangeEvent
- All Implemented Interfaces:
Serializable
Instances of this class are sent when Game turn changes. This even keeps track of the player who will be taking the
new turn as well as the player who took the turn that triggered this event.
- See Also:
-
Field Summary
Fields inherited from class megamek.common.event.player.GamePlayerEvent
playerFields inherited from class java.util.EventObject
source -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidSub-classed events implement this method to call their specific method on a GameListener instance that their event has been fired.intMethods inherited from class megamek.common.event.player.GamePlayerEvent
getPlayerMethods inherited from class java.util.EventObject
getSource
-
Constructor Details
-
GameTurnChangeEvent
- Parameters:
source- The Game instancecurrPlayer- The player for whom the new turn is for.prevPlayerId- The id of the player who took the turn that triggered this event.
-
-
Method Details
-
fireEvent
Description copied from class:GameEventSub-classed events implement this method to call their specific method on a GameListener instance that their event has been fired. -
getEventName
- Specified by:
getEventNamein classGameEvent
-
getPreviousPlayerId
public int getPreviousPlayerId()
-