Serializable, Comparable<Event>public final class MessageEvent extends Event
onMessageReceived() when a teammate sends a message to your robot.
You can use the information contained in this event to determine what to do.| Constructor | Description |
|---|---|
MessageEvent(String sender,
Serializable message) |
Called by the game to create a new MessageEvent.
|
| Modifier and Type | Method | Description |
|---|---|---|
Serializable |
getMessage() |
Returns the message itself.
|
String |
getSender() |
Returns the name of the sending robot.
|
compareTo, getPriority, getTime, setPriority, setTimepublic MessageEvent(String sender, Serializable message)
sender - the name of the sending robotmessage - the message for your robotpublic String getSender()
public Serializable getMessage()
Copyright © 2018. All rights reserved.