fix: made Event/Request/ReconnectMessage subclasses of BasicMessage
This commit is contained in:
parent
dbc7264d5f
commit
f3d3310e46
@ -8,10 +8,7 @@ import java.util.HashMap;
|
|||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
/** Represents a message sent between client and server and contains all possible data. */
|
/** Represents a message sent between client and server and contains all possible data. */
|
||||||
public class EventMessage {
|
public class EventMessage extends BasicMessage {
|
||||||
|
|
||||||
/** This is the message type. It is either REQUESTS or EVENTS, everything else would be invalid here */
|
|
||||||
public MessageType messageType;
|
|
||||||
|
|
||||||
/** The list of {@link Event Events} sent inside the message. */
|
/** The list of {@link Event Events} sent inside the message. */
|
||||||
public Event[] messages;
|
public Event[] messages;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
package uulm.teamname.marvelous.gamelibrary.messages;
|
package uulm.teamname.marvelous.gamelibrary.messages;
|
||||||
|
|
||||||
public class ReconnectMessage {
|
public class ReconnectMessage extends BasicMessage {
|
||||||
|
|
||||||
/** Whether the client wants to reconnect to the previously running game */
|
/** Whether the client wants to reconnect to the previously running game */
|
||||||
public Boolean reconnect;
|
public Boolean reconnect;
|
||||||
|
@ -9,10 +9,7 @@ import java.util.HashMap;
|
|||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
/** Represents a message sent between client and server and contains all possible data. */
|
/** Represents a message sent between client and server and contains all possible data. */
|
||||||
public class RequestMessage {
|
public class RequestMessage extends BasicMessage {
|
||||||
|
|
||||||
/** This is the message type. It is either REQUESTS or EVENTS, everything else would be invalid here */
|
|
||||||
public MessageType messageType;
|
|
||||||
|
|
||||||
/** The list of {@link Event Events} sent inside the message. */
|
/** The list of {@link Event Events} sent inside the message. */
|
||||||
public Request[] messages;
|
public Request[] messages;
|
||||||
|
Loading…
Reference in New Issue
Block a user