eco-state-machine icon indicating copy to clipboard operation
eco-state-machine copied to clipboard

README modifications for Godot 4.x

Open gregkrsak opened this issue 3 years ago • 0 comments

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)

gregkrsak avatar Feb 24 '22 00:02 gregkrsak