public interface IShipyard
| Modifier and Type | Method and Description |
|---|---|
void |
addShipBuildingOrder(IShipDueDate dueDate)
Update the state with a building order.
|
void |
addShipBuildingOrder(IShipDueDate dueDate,
com.google.common.base.Optional<TimedTask> task)
Add an order for building a new ship to the list.
|
void |
addShipRefitOrder(IShipDueDate dueDate,
com.google.common.base.Optional<TimedTask> task)
Add an order for refitting a ship to the list.
|
void |
addShipRepairOrder(IShipDueDate dueDate,
com.google.common.base.Optional<TimedTask> task)
Add an order for repairing a ship to the list.
|
void |
addShipToRepairList(IShipDueDate dueDate)
Add a ship to the repair list.
|
void |
addToRefitList(IShipDueDate dueDate) |
int |
calculateBuildTime(EShipType type)
Calculate the build time for the ship of type.
|
int |
calculateConstructionCosts(EShipType type)
Calculate the labor costs for building a new ship of the indicated type.
|
int |
calculateRefitCosts(EShipType type,
int levels)
Calculate the labor costs for the refit based on the ship type and how many levels
should be upgraded.
|
int |
calculateRefitTime(EShipType type)
Calculate the time in days it takes for refitting.
|
int |
calculateRepairCosts(int repairTime,
int materialCosts)
Calculate the repair costs.
|
int |
calculateRepairMaterialCosts(IShip ship,
int damage)
Calculate the material costs for the repair.
|
int |
calculateRepairTime(EShipType type)
Calculate the repair time for the ship of type.
|
void |
cancelRepair(IShip ship)
Cancel the repair of the ship.
|
void |
cancelShipBuildingOrder(org.joda.time.DateTime finish)
Cancel the order of the building, finished on the given date.
|
EShipType[] |
getBuildableShipTypes()
Retrieve a list of all the types of ships this yard can build.
|
org.joda.time.DateTime |
getBuildCompleteDate(EShipType type)
Retrieve the date when the building of a new ship will be finished.
|
ICity |
getCity()
Retrieve the city the shipyard belongs to.
|
List<IShipDueDate> |
getShipBuildingList()
Retrieve an immutable list of the ships that are ordered
to be built on this shipyard.
|
List<IShipDueDate> |
getShipRepairList()
Retrieve the list of all ships that are to be repaired.
|
ICity getCity()
List<IShipDueDate> getShipBuildingList()
org.joda.time.DateTime getBuildCompleteDate(EShipType type)
type - of the ship to be builtvoid addShipBuildingOrder(IShipDueDate dueDate, com.google.common.base.Optional<TimedTask> task)
dueDate - when the ship is finished buildingtask - that is executed on completion.void addShipRepairOrder(IShipDueDate dueDate, com.google.common.base.Optional<TimedTask> task)
dueDate - when the ship is finished repairingtask - that is executed on completion.void addShipRefitOrder(IShipDueDate dueDate, com.google.common.base.Optional<TimedTask> task)
dueDate - when the ship is refittedtask - that is executed on completion.void addShipBuildingOrder(IShipDueDate dueDate)
dueDate - ship due datevoid cancelShipBuildingOrder(org.joda.time.DateTime finish)
finish - dateList<IShipDueDate> getShipRepairList()
void addShipToRepairList(IShipDueDate dueDate)
dueDate - ship due datevoid cancelRepair(IShip ship)
ship - which's repair order is to be canceledvoid addToRefitList(IShipDueDate dueDate)
int calculateRepairCosts(int repairTime,
int materialCosts)
repairTime - materialCosts - int calculateRepairMaterialCosts(IShip ship, int damage)
ship - damage - int calculateRefitCosts(EShipType type, int levels)
type - levels - int calculateRefitTime(EShipType type)
type - destination levelEShipType[] getBuildableShipTypes()
int calculateConstructionCosts(EShipType type)
type - of the shipint calculateBuildTime(EShipType type)
type - int calculateRepairTime(EShipType type)
type - Copyright © 2011-2015 Sahits GmbH. All Rights Reserved.