You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I see in line 135 of GoapAgent.cs as shown below code, but there is else condition at 170 which solves a similar problem. can you explain in which condition this is needed? if (!hasActionPlan()) { // no actions to perform Debug.Log("<color=red>Done actions</color>"); fsm.popState(); fsm.pushState(idleState); dataProvider.actionsFinished(); return; }
The text was updated successfully, but these errors were encountered:
In that case it doesn't seems to make much a difference.
However, if you land in the first if (!hasActionPlan()) it means you're in the performActionState while not having any plan.
If you land in the else condition, line 170 in the code, it means you have successfully achieved every action in your plan (since you had a plan when entering the state but the last action has been removed line 146).
I see in line 135 of GoapAgent.cs as shown below code, but there is else condition at 170 which solves a similar problem. can you explain in which condition this is needed?
if (!hasActionPlan()) { // no actions to perform Debug.Log("<color=red>Done actions</color>"); fsm.popState(); fsm.pushState(idleState); dataProvider.actionsFinished(); return; }
The text was updated successfully, but these errors were encountered: