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) { List<AbstractTileAction> actionsForCurrentLocation = mapAnalyzer.GetActionsAtObserverLocation(currentAvatar); if (actionsForCurrentLocation.Count <= 0) { return null; } AbstractTileAction tileAction = actionsForCurrentLocation[0]; TurnStepAction action = new ActionableTurnStepAction(tileAction, currentAvatar); 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; }
public virtual TurnStepAction FindAction(Avatar currentAvatar, AvatarTurnState avatarTurnState, QuestAnalyzer mapAnalyzer, ChanceProvider chanceProvider) { return null; } // Override in subclasses
override public TurnStepAction FindAction(Avatar currentAvatar, AvatarTurnState avatarTurnState, QuestAnalyzer mapAnalyzer, ChanceProvider chanceProvider) { List<Avatar> enemies = mapAnalyzer.GetAdjacentEnemies(currentAvatar, currentAvatar.CanAttackAdjacent); return null; }