eco-state-machine
eco-state-machine copied to clipboard
README modifications for Godot 4.x
As of the current Godot 4 alpha build, the instructions in the readme (for Example 1) can be modified to function with the new callable system, as shown:
func _ready():
.
.
.
fsm.state_changed.connect(self._on_state_changed)
.
.
.
func _on_state_changed(state_from, state_to, _args):
print("switched to state ",state_to)