public class ProductionChainTradeStrategy extends BasePlayerTradeStrategy
| Modifier and Type | Field and Description |
|---|---|
private com.google.common.eventbus.AsyncEventBus |
clientServerEventBus |
private org.apache.logging.log4j.Logger |
logger |
private MapProxy |
mapProxy |
private MapService |
mapService |
private ch.sahits.game.openpatrician.model.product.ProductionChain |
productionChain |
private ShipService |
shipService |
tradeStrategyType| Constructor and Description |
|---|
ProductionChainTradeStrategy() |
| Modifier and Type | Method and Description |
|---|---|
private void |
buyWaresAndTravelToNextStop(ch.sahits.game.openpatrician.model.IAIPlayer player,
ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
ch.sahits.game.openpatrician.model.city.ICity currentLocation,
ch.sahits.game.openpatrician.model.player.IProductionConsumptionKnowledge knowledge,
ch.sahits.game.openpatrician.model.city.ICity nextStop) |
private void |
destroy() |
private ch.sahits.game.openpatrician.model.city.ICity |
getCurrentCity(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel) |
private ProductionChainMissionData |
getMissionData(ch.sahits.game.openpatrician.model.IAIPlayer player,
ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel) |
void |
handleShipArrivesInPort(ch.sahits.game.openpatrician.model.event.IShipEntersPortEvent event) |
private void |
init() |
void |
initialzeTradeCycle(ch.sahits.game.openpatrician.model.IAIPlayer player,
ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel) |
addDefaultTradeSteps, append, createAggregatedBuyTradeStep, createAggregatedCheckedBuyTradeStep, createAggregatedDumpStep, createAggregatedSellStep, createCheckAndTakeLoanStep, createCheckRepairStep, createConditionalAggregatedDumpStep, createHireCaptain, createHireSailorStep, createJoinGuildTradeStep, createPaybackLoanStep, createTravelToStep, executeTradeSteps, findCitySupplyingWare, findCityWithAllRequiredWares, findDestinationToBuyRequiredProductionWares, findNextStop, findWaresOfInterest, getLoadedWares, getMostNeededWares, getMostNeededWares, getNextStep, getWaresNeedIn, handleHireSailors, handleRepairFinished, hasMoreTradeSteps, inject, isMatchingTradeStrategy, isNeededprivate final org.apache.logging.log4j.Logger logger
@Autowired private ch.sahits.game.openpatrician.model.product.ProductionChain productionChain
@Autowired private ShipService shipService
@Autowired @Qualifier(value="serverClientEventBus") private com.google.common.eventbus.AsyncEventBus clientServerEventBus
@Autowired private MapService mapService
@Autowired private MapProxy mapProxy
@PostConstruct private void init()
@PreDestroy private void destroy()
public void initialzeTradeCycle(ch.sahits.game.openpatrician.model.IAIPlayer player,
ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel)
private void buyWaresAndTravelToNextStop(ch.sahits.game.openpatrician.model.IAIPlayer player,
ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
ch.sahits.game.openpatrician.model.city.ICity currentLocation,
ch.sahits.game.openpatrician.model.player.IProductionConsumptionKnowledge knowledge,
ch.sahits.game.openpatrician.model.city.ICity nextStop)
public void handleShipArrivesInPort(ch.sahits.game.openpatrician.model.event.IShipEntersPortEvent event)
private ch.sahits.game.openpatrician.model.city.ICity getCurrentCity(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel)
private ProductionChainMissionData getMissionData(ch.sahits.game.openpatrician.model.IAIPlayer player, ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel)
Copyright © 2011-2017 Sahits GmbH. All Rights Reserved.