override public TurnStepAction FindAction(Avatar currentAvatar, AvatarTurnState avatarTurnState, QuestAnalyzer mapAnalyzer, ChanceProvider chanceProvider) { List<LocationOfInterest> interestingDestinations = mapAnalyzer.GetInterestingLocationsCheating(currentAvatar); if (interestingDestinations.Count <= 0) { return null; } interestingDestinations = interestingDestinations.OrderBy(item => item.StepsToLocation).ToList(); MovementTurnStepAction action = new MovementTurnStepAction(currentAvatar, interestingDestinations[0].StepsToLocation); return action; }
override public TurnStepAction FindAction(Avatar currentAvatar, AvatarTurnState avatarTurnState, QuestAnalyzer mapAnalyzer, ChanceProvider chanceProvider) { PointList unwalkedTiles = mapAnalyzer.GetAdjacentUnvisitedLocations(currentAvatar); if (unwalkedTiles.Count <= 0) { return null; } // Just pick the first tile, and see if that opens up any other actions... PointList path = new PointList() { unwalkedTiles[0] }; MovementTurnStepAction action = new MovementTurnStepAction(currentAvatar, path); return action; }