|
||||||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||||
| Packages that use SOCShip | |
|---|---|
| soc.game | |
| soc.robot | |
| Uses of SOCShip in soc.game |
|---|
| Methods in soc.game that return SOCShip | |
|---|---|
SOCShip |
SOCGame.canAttackPirateFortress()
Can the current player attack their pirate fortress, and try to conquer and recapture it? This method is validation before calling SOCGame.attackPirateFortress(SOCShip). |
SOCShip |
SOCGame.canMoveShip(int pn,
int fromEdge)
Can this player currently move this ship, based on game state and their trade routes and settlements/cities? Must be current player. |
SOCShip |
SOCGame.canMoveShip(int pn,
int fromEdge,
int toEdge)
Can this player currently move this ship to this new coordinate, based on game state and their trade routes and settlements/cities? Must be current player. |
SOCShip |
SOCPlayer.getMostRecentShip()
Get this player's most recently placed ship, if any. |
| Methods in soc.game that return types with arguments of type SOCShip | |
|---|---|
private java.util.Vector<SOCShip> |
SOCPlayer.checkTradeRouteFarEndClosed(SOCShip newShipEdge,
int edgeFarNode)
Follow a trade route (a line of SOCShips) away from a newly closed end, to
determine if the other end is closed or still open, and close this route if
necessary. |
private java.util.Vector<SOCShip> |
SOCPlayer.isTradeRouteFarEndClosed(SOCShip edgeFirstShip,
int edgeFarNode,
java.util.HashSet<java.lang.Integer> alreadyVisited,
java.util.List<java.util.Vector<java.lang.Object>> encounteredSelf)
Recursive call for SOCPlayer.checkTradeRouteFarEndClosed(SOCShip, int). |
| Methods in soc.game with parameters of type SOCShip | |
|---|---|
int[] |
SOCGame.attackPirateFortress(SOCShip adjacent)
The current player has built ships to their pirate fortress, and attacks now to try to conquer and recapture it. |
boolean |
SOCPlayer.canMoveShip(SOCShip sh)
Can we move this ship, based on our trade routes and settlements/cities near its current location? |
private java.util.Vector<SOCShip> |
SOCPlayer.checkTradeRouteFarEndClosed(SOCShip newShipEdge,
int edgeFarNode)
Follow a trade route (a line of SOCShips) away from a newly closed end, to
determine if the other end is closed or still open, and close this route if
necessary. |
boolean |
SOCGame.isShipWarship(SOCShip sh)
For scenario option _SC_PIRI, is this ship upgraded to a warship?
Counts down sh's player's SOCPlayer.getNumWarships()
while it looks for sh among the ships from SOCPlayer.getRoads(),
which is in the same chronological order as warship conversions. |
private java.util.Vector<SOCShip> |
SOCPlayer.isTradeRouteFarEndClosed(SOCShip edgeFirstShip,
int edgeFarNode,
java.util.HashSet<java.lang.Integer> alreadyVisited,
java.util.List<java.util.Vector<java.lang.Object>> encounteredSelf)
Recursive call for SOCPlayer.checkTradeRouteFarEndClosed(SOCShip, int). |
void |
SOCGame.moveShip(SOCShip sh,
int toEdge)
Move this ship on the board and update all related game state. |
private void |
SOCPlayer.putPiece_roadOrShip_checkNewShipTradeRouteAndSpecialEdges(SOCShip newShip,
SOCBoardLarge board,
boolean isTempPiece)
Check this new ship for adjacent settlements/cities/villages, to see if its trade route will be closed. |
void |
SOCGame.removeShip(SOCShip sh)
Remove this ship from the board and update all related game state. |
| Uses of SOCShip in soc.robot |
|---|
| Fields in soc.robot declared as SOCShip | |
|---|---|
private SOCShip |
SOCPlayerTracker.scen_SC_PIRI_closestShipToFortress
For scenario _SC_PIRI, the player's ship closest to the Fortress (the ship farthest west). |
| Methods in soc.robot that return SOCShip | |
|---|---|
SOCShip |
SOCPlayerTracker.getScenario_SC_PIRI_closestShipToFortress()
For scenario _SC_PIRI, get the player's ship closest to their Fortress (the ship farthest west). |
| Methods in soc.robot with parameters of type SOCShip | |
|---|---|
int |
SOCPlayerTracker.getScenario_SC_PIRI_shipDistanceToFortress(SOCShip ship)
For scenario _SC_PIRI, get the distance of this player's closest ship from their
SOCFortress. |
(package private) void |
SOCPlayerTracker.updateScenario_SC_PIRI_closestShipToFortress(SOCShip ship,
boolean shipAdded)
For scenario _SC_PIRI, update the player's ship closest to their Fortress. |
|
||||||||||
| PREV NEXT | FRAMES NO FRAMES | |||||||||