GameConfig class Null safety
Some general config parameters for a game of gameType
Custom options can be added to the options map, but must be in a json compatible form
- Annotations
Constructors
-
GameConfig({required GameType gameType, PlayerID? adminID, @Default(NameSet.Basic) NameSet nameSet, @Default(false) bool customNames, @Default(15) int rounds, @Default(1) int minPlayers, @Default(10) int maxPlayers, @Default(true) bool autoStart, Map<
String, dynamic> ? options}) -
constfactory
-
GameConfig.fromJson(Map<
String, dynamic> map) -
factory
Properties
- adminID → String?
-
read-only, inherited
- autoStart → bool
-
read-only, inherited
-
copyWith
→ $GameConfigCopyWith<
GameConfig> -
@JsonKey(ignore: true), read-only, inherited
- customNames → bool
-
read-only, inherited
- gameType → String
-
read-only, inherited
- hashCode → int
-
The hash code for this object. [...]
read-only, inherited
- maxPlayers → int
-
read-only, inherited
- minPlayers → int
-
read-only, inherited
- nameSet → NameSet
-
read-only, inherited
-
options
→ Map<
String, dynamic> ? -
options must be json serializable
read-only, inherited
- rounds → int
-
read-only, inherited
- runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed. [...]
inherited
-
toJson(
) → Map< String, dynamic> -
inherited
-
toString(
) → String -
A string representation of this object. [...]
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator. [...]
inherited