HasWidgetsOverlay mixin

Superclass Constraints

Constructors

HasWidgetsOverlay()

Properties

builder WidgetBuilder
final
widgetOverlayController StreamController<OverlayWidget>
final
runOnCreation bool
Flag to tell the game loop if it should start running upon creation
read / write, inherited
pauseEngineFn VoidCallback
read / write, inherited
resumeEngineFn VoidCallback
read / write, inherited
widget Widget
Returns the game widget. Put this in your structure to start rendering and updating the game. You can add it directly to the runApp method or inside your widget structure (if you use vanilla screens and widgets).
read-only, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

addWidgetOverlay(String overlayName, Widget widget) → void
removeWidgetOverlay(String overlayName) → void
backgroundColor() Color
Returns the game background color. By default it will return a black color. It cannot be changed at runtime, because the game widget does not get rebuild when this value changes.
inherited
update(double t) → void
Implement this method to update the game state, given that a time t has passed. [...]
inherited
render(Canvas canvas) → void
Implement this method to render the current game state in the canvas.
inherited
resize(Size size) → void
This is the resize hook; every time the game widget is resized, this hook is called. [...]
inherited
lifecycleStateChange(AppLifecycleState state) → void
This is the lifecycle state change hook; every time the game is resumed, paused or suspended, this is called. [...]
inherited
recordDt(double dt) → void
Used for debugging
inherited
onAttach() → void
@mustCallSuper, inherited
onDetach() → void
@mustCallSuper, inherited
pauseEngine() → void
Pauses the engine game loop execution
inherited
resumeEngine() → void
Resumes the engine game loop execution
inherited
toString() String
Returns a string representation of this object.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited