|
JSettlers v1.0.6 API Built ${date} |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsoc.robot.SOCPossiblePiece
soc.robot.SOCPossibleSettlement
This is a possible settlement that we can build
Field Summary | |
protected java.util.Vector |
conflicts
|
protected java.util.Vector |
necessaryRoads
|
protected int |
numberOfNecessaryRoads
|
protected java.util.Stack |
roadPath
|
protected int[] |
speedup
|
Fields inherited from class soc.robot.SOCPossiblePiece |
biggestThreats, CARD, CITY, coord, eta, hasBeenExpanded, MAXPLUSONE, MIN, pieceType, player, ROAD, score, SETTLEMENT, threats, threatUpdatedFlag, updated |
Constructor Summary | |
SOCPossibleSettlement(SOCPlayer pl,
int co,
java.util.Vector nr)
constructor |
|
SOCPossibleSettlement(SOCPossibleSettlement ps)
copy constructor Note: This will not copy vectors, only make empty ones |
Method Summary | |
void |
addConflict(SOCPossibleSettlement s)
add a conflicting settlement |
void |
addNecessaryRoad(SOCPossibleRoad rd)
add a possible road to the list of necessary roads |
java.util.Vector |
getConflicts()
|
java.util.Vector |
getNecessaryRoads()
|
int |
getNumberOfNecessaryRoads()
|
int[] |
getSpeedup()
|
int |
getSpeedupTotal()
|
void |
removeConflict(SOCPossibleSettlement s)
remove a conflicting settlement |
void |
setNumberOfNecessaryRoads(int num)
set the minimum number of necessary roads |
void |
updateSpeedup()
update the speedup that this settlement gives |
Methods inherited from class soc.robot.SOCPossiblePiece |
addBiggestThreat, addThreat, addToScore, clearBiggestThreats, clearThreats, clearUpdateFlag, getBiggestThreats, getCoordinates, getETA, getPlayer, getScore, getThreats, getType, hasBeenExpanded, isETAUpdated, isThreatUpdated, resetExpandedFlag, resetScore, setETA, setExpandedFlag, subtractFromScore, threatUpdated, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.util.Vector necessaryRoads
protected java.util.Vector conflicts
protected int[] speedup
protected int numberOfNecessaryRoads
protected java.util.Stack roadPath
Constructor Detail |
public SOCPossibleSettlement(SOCPlayer pl, int co, java.util.Vector nr)
pl
- the ownerco
- coordinates;nr
- necessaryRoads;public SOCPossibleSettlement(SOCPossibleSettlement ps)
ps
- the possible settlement to copyMethod Detail |
public java.util.Vector getNecessaryRoads()
public int getNumberOfNecessaryRoads()
public void setNumberOfNecessaryRoads(int num)
num
- the minimum number of necessary roadspublic void updateSpeedup()
public java.util.Vector getConflicts()
public void addNecessaryRoad(SOCPossibleRoad rd)
rd
- the roadpublic void addConflict(SOCPossibleSettlement s)
s
- the settlementpublic void removeConflict(SOCPossibleSettlement s)
s
- the settlementpublic int[] getSpeedup()
public int getSpeedupTotal()
|
JSettlers v1.0.6 API Built ${date} |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |