|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.colossus.game.Battle
net.sf.colossus.client.BattleClientSide
public class BattleClientSide
Field Summary | |
---|---|
private Player |
battleActivePlayer
|
private BattlePhase |
battlePhase
|
private int |
battleTurnNumber
|
private java.util.List<BattleUnit> |
battleUnits
|
private static java.util.logging.Logger |
LOGGER
|
Fields inherited from class net.sf.colossus.game.Battle |
---|
attacker, defender, game |
Constructor Summary | |
---|---|
BattleClientSide(Game game,
Legion attacker,
Legion defender,
MasterHex location)
|
Method Summary | |
---|---|
boolean |
anyOffboardCreatures()
|
void |
cleanupBattle()
|
int |
countBrambleHexes(BattleHex hex1,
BattleHex hex2)
Deprecated. another function with explicit reference to Bramble that should be fixed. |
private int |
countBrambleHexesDir(BattleHex hex1,
BattleHex hex2,
boolean left,
int previousCount)
Deprecated. another function with explicit reference to Bramble that should be fixed. |
BattleUnit |
createBattleUnit(java.lang.String imageName,
boolean inverted,
int tag,
BattleHex hex,
CreatureType type,
Legion legion)
|
java.util.List<BattleUnit> |
getActiveBattleUnits()
|
private int |
getAttackerSkill(BattleCritter striker,
BattleCritter target,
Client client)
WARNING: this is duplicated in CreatureServerSide (moved from Strike to here) |
Legion |
getBattleActiveLegion()
|
Player |
getBattleActivePlayer()
|
BattlePhase |
getBattlePhase()
|
java.lang.String |
getBattlePhaseName()
|
int |
getBattleTurnNumber()
|
BattleUnit |
getBattleUnit(BattleHex hex)
|
(package private) BattleUnit |
getBattleUnit(int tag)
Get the BattleUnit with this tag. |
java.util.List<BattleUnit> |
getBattleUnits()
|
java.util.List<BattleUnit> |
getBattleUnits(BattleHex hex)
|
int |
getDice(BattleCritter battleUnit,
BattleCritter target,
Client client)
Return the number of dice that will be rolled when striking this target, including modifications for terrain. |
GameClientSide |
getGameClientSide()
|
java.util.List<BattleUnit> |
getInactiveBattleUnits()
|
int |
getStrikeNumber(BattleCritter striker,
BattleCritter target,
Client client)
WARNING: this is duplicated in CreatureServerSide (moved from Strike to here) |
void |
init(int battleTurnNumber,
Player battleActivePlayer,
BattlePhase battlePhase)
|
boolean |
isBattlePhase(BattlePhase phase)
|
protected boolean |
isOccupied(BattleHex hex)
Whether the hex is occupied by a critter/creature/chit/... |
void |
markOffboardCreaturesDead()
|
void |
removeDeadBattleChits()
|
void |
resetAllBattleMoves()
|
void |
setBattleActivePlayer(Player battleActivePlayer)
|
void |
setBattlePhase(BattlePhase battlePhase)
|
void |
setBattleTurnNumber(int battleTurnNumber)
|
void |
setupBattleFight(BattlePhase battlePhase,
Player battleActivePlayer)
|
void |
setupPhase(BattlePhase phase,
Player battleActivePlayer,
int battleTurnNumber)
|
Methods inherited from class net.sf.colossus.game.Battle |
---|
computeSkillPenaltyRangestrikeThrough, getAttackingLegion, getDefendingLegion, getDirection, getGame, getLegionByPlayer, getLocation, getRange, isLOSBlocked, isLOSBlockedDir, isRangestrikePossible, toLeft |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final java.util.logging.Logger LOGGER
private BattlePhase battlePhase
private int battleTurnNumber
private Player battleActivePlayer
private final java.util.List<BattleUnit> battleUnits
Constructor Detail |
---|
public BattleClientSide(Game game, Legion attacker, Legion defender, MasterHex location)
Method Detail |
---|
public void init(int battleTurnNumber, Player battleActivePlayer, BattlePhase battlePhase)
protected boolean isOccupied(BattleHex hex)
Battle
isOccupied
in class Battle
hex
- The hex whose occupancy is being checked
public GameClientSide getGameClientSide()
public void setBattleTurnNumber(int battleTurnNumber)
public int getBattleTurnNumber()
public Player getBattleActivePlayer()
public void cleanupBattle()
public Legion getBattleActiveLegion()
public BattlePhase getBattlePhase()
public void setBattlePhase(BattlePhase battlePhase)
public boolean isBattlePhase(BattlePhase phase)
public void setupPhase(BattlePhase phase, Player battleActivePlayer, int battleTurnNumber)
public java.lang.String getBattlePhaseName()
public void setBattleActivePlayer(Player battleActivePlayer)
public void setupBattleFight(BattlePhase battlePhase, Player battleActivePlayer)
public BattleUnit createBattleUnit(java.lang.String imageName, boolean inverted, int tag, BattleHex hex, CreatureType type, Legion legion)
public boolean anyOffboardCreatures()
public java.util.List<BattleUnit> getActiveBattleUnits()
public java.util.List<BattleUnit> getInactiveBattleUnits()
public java.util.List<BattleUnit> getBattleUnits()
public java.util.List<BattleUnit> getBattleUnits(BattleHex hex)
public BattleUnit getBattleUnit(BattleHex hex)
BattleUnit getBattleUnit(int tag)
public void resetAllBattleMoves()
public void markOffboardCreaturesDead()
public void removeDeadBattleChits()
public int getDice(BattleCritter battleUnit, BattleCritter target, Client client)
private int getAttackerSkill(BattleCritter striker, BattleCritter target, Client client)
public int getStrikeNumber(BattleCritter striker, BattleCritter target, Client client)
@Deprecated private int countBrambleHexesDir(BattleHex hex1, BattleHex hex2, boolean left, int previousCount)
@Deprecated public int countBrambleHexes(BattleHex hex1, BattleHex hex2)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |