public interface IAITradeStrategy
| Modifier and Type | Method and Description |
|---|---|
boolean |
executeTradeSteps(IAIPlayer player,
INavigableVessel vessel)
Execute the trad steps defined for the vessel.
|
ICity |
getCityToRestartTradeCycle(INavigableVessel vessel)
In the case where the trade cycle must be re-initialized, but the ship is not in a city,
determine the city to which the vessel should travel.
|
void |
handleShipArrivesInPort(IShipEntersPortEvent event)
Event handler for a ship entering port.
|
void |
initializeTradeCycle(IAIPlayer player,
INavigableVessel vessel)
Initialize the trade cycle.
|
default boolean |
isSelectable(IAIPlayer player,
INavigableVessel vessel)
Check if this strategy can be selected in the current setup.
|
void initializeTradeCycle(IAIPlayer player, INavigableVessel vessel)
player - vessel - ICity getCityToRestartTradeCycle(INavigableVessel vessel)
vessel - that should travel to a city, so that the trade cycle can be reinitializedboolean executeTradeSteps(IAIPlayer player, INavigableVessel vessel)
player - vessel - void handleShipArrivesInPort(IShipEntersPortEvent event)
event - default boolean isSelectable(IAIPlayer player, INavigableVessel vessel)
vessel.player - for which the strategy is chosen.vessel - for which the strategy is chose.player and vessel. The
default implementation will always return true.Copyright © 2011-2018 Sahits GmbH. All Rights Reserved.