java.lang.Object
|
+--Unit
|
+--MilitaryUnit
MilitaryUnit class
| Field Summary | |
protected java.util.Vector |
charactrs
|
protected boolean |
isMobile
|
protected Charactr |
leader
|
protected int |
spacecombat
|
| Fields inherited from class Unit |
combat, environ, group, groupType, isChar, moved, name, orbit, side, unitType |
| Constructor Summary | |
MilitaryUnit(char s,
java.lang.String n,
int com,
int scom,
Environ env,
boolean m)
Constructor Methods |
|
| Method Summary | |
void |
addCharacter(Charactr c)
add Character() adds a character to the Military Unit |
boolean |
getIsMobile()
getIsMobile() returns true if the MilitaryUnit is mobile; false otherwise |
Charactr |
getLeader()
getLeader() returns the leader of the military unit |
int |
getNumChar()
|
int |
getSpacecombat()
getSpacecombat() returns the spacecombat ability (int) of the unit |
void |
removeCharacter(Charactr c)
remove Character() removes a character from the Military Unit |
void |
setLeader(Charactr lead)
setLeader() changes the leader of the military unit |
| Methods inherited from class Unit |
getCombat, getEnviron, getGroupType, getMoved, getName, getOrbit, getSide, getUnitType, moveFromOrbitBox, moveFromOrbitBox, moveFromOrbitBox, moveFromOrbitBox, moveFromOrbitBox, moveFromOrbitBox, moveShip, moveTo, moveTo, moveToOrbitBox, moveToOrbitBox, moveToOrbitBox, reactionMove, reactionMove, setEnviron, setGroupType, setOrbit |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected int spacecombat
protected boolean isMobile
protected Charactr leader
protected java.util.Vector charactrs
| Constructor Detail |
public MilitaryUnit(char s,
java.lang.String n,
int com,
int scom,
Environ env,
boolean m)
| Method Detail |
public boolean getIsMobile()
public int getSpacecombat()
public Charactr getLeader()
public void addCharacter(Charactr c)
public void removeCharacter(Charactr c)
public int getNumChar()
public void setLeader(Charactr lead)