/// <summary> /// /// </summary> /// <param name="agent">The agend this action belongs to</param> /// <param name="delay">The amount of delay for this action (0f-1f)</param> public GoapAction(GoapAgent agent, float delay = 1f) { childs = new List <GoapAction>(); preconditions = new Dictionary <string, bool>(); effects = new Dictionary <string, bool>(); this.agent = agent; this.delay = delay; GenerateNewGUID(); }
void OnEnable() { agent = (GoapAgent)target; }