Why is the second argument "any "when is known to be the index of the changed value from data table which is defined like this: {[string]: any}? It should be string, right?
Also the documentation is wrong for the DataChanged property of the State machine. (the e.g is the problem):
exampleStateMachine.StateChanged:Connect(function(newState: string, previousState: string)
print("Our previous state was: " .. previousState .. " now our state is: " .. newState)
end)
it should be:
exampleStateMachine.DataChanged:Connect(function(data: {[string]: any}, index: string, newValue: any, oldValue: any)
print("Changed the index " .. index .. " with: ", newValue)
end)
Why is the second argument "any "when is known to be the index of the changed value from data table which is defined like this: {[string]: any}? It should be string, right?
Also the documentation is wrong for the DataChanged property of the State machine. (the e.g is the problem):
it should be: