Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default transition targetstate to transition configName #1213

Merged
merged 2 commits into from
Aug 21, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion addons/statemachine/fnc_createFromConfig.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,10 @@ private _stateMachine = [_list, _skipNull] call FUNC(create);
private _state = configName _x;
{
private _transition = configName _x;
private _targetState = getText (_x >> "targetState");
private _targetState = _transition;
if (isText (_x >> "targetState")) then {
_targetState = getText (_x >> "targetState");
};
GET_FUNCTION(_condition,_x >> "condition");
GET_FUNCTION(_onTransition,_x >> "onTransition");
private _events = getArray (_x >> "events");
Expand Down