public GoalState PlanForBot(Bot bot) { foreach (GoalState goal in bot.GetGoals()) { if (WorldEventManager.Contains(goal.worldState)) //rewrite this part { Debug.Log("[Planner] Found goal : " + goal + " finding action sequence " + bot.GetCurrentGoal()); goal.SetActionSequence(FindActionsForGoal(bot, goal)); return(goal); } } //if nothing was found Debug.Log("[Planner] nothing found, falling back on default!"); defaultGoalState.SetActionSequence(FindActionsForGoal(bot, defaultGoalState)); return(defaultGoalState); }
private void Awake() { Instance = this; EntityGroups = new List <EntityGroup>(); }