public Node(Node parent, float runningCost, Dictionary <string, object> state, GOAPAction action) { Parent = parent; RunningCost = runningCost; State = state; Action = action; }
/** * Create a subset of the actions excluding the removeMe one. Creates a new set. */ protected HashSet <GOAPAction> ActionSubset(HashSet <GOAPAction> actions, GOAPAction removeMe) { var subset = new HashSet <GOAPAction>(); foreach (var a in actions) { if (!a.Equals(removeMe)) { subset.Add(a); } } return(subset); }
public void RemoveAction(GOAPAction action) { AvailableActions.Remove(action); }
public void AddAction(GOAPAction action) { AvailableActions.Add(action); }