// Overload of method to use if the pathfollowing is needed by another goal public FollowPathGoal(AwareEntity me, Vector2 target) : base(me) { GoalStatus = GoalStatus.Inactive; PathToFollow = new LinkedList <Vector2>(); Target = target; PathFindingAsSubGoal = true; }
public FollowPathGoal(AwareEntity me) : base(me) { GoalStatus = GoalStatus.Inactive; PathToFollow = new LinkedList <Vector2>(); Target = Game1.Instance.Target; PathFindingAsSubGoal = false; }
public MakeDecisionGoal(AwareEntity me) : base(me) { fuzzyModule = new FuzzyModule(); FuzzyVariable hunger = fuzzyModule.CreateFLV("Hunger"); FzSet hungry = hunger.AddLeftShoulder("Hungry", 0.0, 0.1, 0.3); FzSet content = hunger.AddTriangle("Content", 0.1, 0.5, 0.8); FzSet full = hunger.AddRightShoulder("Full", 0.5, 0.8, 1.0); FuzzyVariable fatique = fuzzyModule.CreateFLV("Fatique"); FzSet sleepy = fatique.AddLeftShoulder("Sleepy", 0.0, 0.1, 0.3); FzSet awake = fatique.AddTriangle("Awake", 0.1, 0.3, 0.5); FzSet alert = fatique.AddRightShoulder("Alert", 0.3, 0.5, 1.0); FuzzyVariable desirability = fuzzyModule.CreateFLV("Desirability"); FzSet unDesirable = desirability.AddLeftShoulder("Undesirable", 0, 0.25, 0.5); FzSet desirable = desirability.AddTriangle("Desirable", 0.25, 0.5, 0.75); FzSet veryDesirable = desirability.AddRightShoulder("VeryDesirable", 0.5, 0.75, 1.0); fuzzyModule.AddRule(new FzAND(hungry, sleepy), unDesirable); fuzzyModule.AddRule(new FzAND(hungry, awake), desirable); fuzzyModule.AddRule(new FzAND(hungry, alert), veryDesirable); fuzzyModule.AddRule(new FzAND(content, sleepy), unDesirable); fuzzyModule.AddRule(new FzAND(content, awake), desirable); fuzzyModule.AddRule(new FzAND(content, alert), veryDesirable); fuzzyModule.AddRule(new FzAND(full, sleepy), unDesirable); fuzzyModule.AddRule(new FzAND(full, awake), desirable); fuzzyModule.AddRule(new FzAND(full, alert), veryDesirable); }
public DealWithHungerGoal(AwareEntity me, EntityManager em) : base(me) { EM = em; GoalStatus = GoalStatus.Inactive; }
public CompositeGoal(AwareEntity me) { ME = me; SubGoals = new List <Goal>(); }
public SleepGoal(AwareEntity me) { ME = me; }
public TraverseNodeGoal(AwareEntity me, Vector2 target) { ME = me; Target = target; }
public EatGoal(AwareEntity me) { ME = me; }
public DecideBetweenNeedsGoal(AwareEntity me) : base(me) { GoalStatus = GoalStatus.Inactive; }