GenericEvent.message constructor Null safety

const GenericEvent.message(
  1. String message,
  2. {required PlayerID from,
  3. required PlayerID? to}
)

Sends a message from the player with id from to the player with id to

Implementation

const factory GenericEvent.message(
  String message, {
  required PlayerID from,
  required PlayerID? to,
}) = GameMessage;