allow data dict in watch state helper
This commit is contained in:
parent
ef7df7ea89
commit
47aa35a4c7
1 changed files with 2 additions and 2 deletions
|
|
@ -45,10 +45,10 @@ func match_state(exclude: Array[StringName] = []) -> StringName:
|
|||
return ""
|
||||
|
||||
|
||||
func watch_state(exclude: Array[StringName] = []) -> bool:
|
||||
func watch_state(exclude: Array[StringName] = [], data: Dictionary[StringName, Variant] = {}) -> bool:
|
||||
var next_state: StringName = match_state(exclude)
|
||||
if next_state != "":
|
||||
finished.emit(next_state)
|
||||
finished.emit(next_state, data)
|
||||
return true
|
||||
|
||||
return false
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue