|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.colossus.server.CustomRecruitBase
public abstract class CustomRecruitBase
Base class to implement custom recruiting functions (i.e. anything that is not a-number-of-creature to another creature)
Field Summary | |
---|---|
private static java.util.List<Caretaker> |
allCaretakerInfo
|
private static java.util.List<CustomRecruitBase> |
allCustomRecruitBase
|
protected static java.util.List<Player> |
allPlayers
|
private static java.util.logging.Logger |
LOGGER
|
private static GameServerSide |
serverGame
|
Constructor Summary | |
---|---|
CustomRecruitBase()
|
Method Summary | |
---|---|
static void |
addCaretakerClientSide(Caretaker ci)
|
static void |
addPlayerClientSide(Player pi)
|
protected void |
adjustAvailableCount(CreatureType type)
|
protected abstract void |
changeOfTurn(int newActivePlayer)
Bookkeeping function, called once after every player turn. |
static void |
everyoneAdvanceTurn(int newActivePlayer)
|
abstract java.util.List<CreatureType> |
getAllPossibleSpecialRecruiters(MasterBoardTerrain terrain)
List all creatures that can recruit in this terrain in a special way. |
abstract java.util.List<CreatureType> |
getAllPossibleSpecialRecruits(MasterBoardTerrain terrain)
List all creatures that can be recruited in this terrain in a special way. |
protected int |
getCount(CreatureType type)
|
protected int |
getDeadCount(CreatureType type)
|
abstract java.util.List<CreatureType> |
getPossibleSpecialRecruiters(MasterHex hex)
List creatures that can recruit in this terrain in a special way now. |
abstract java.util.List<CreatureType> |
getPossibleSpecialRecruits(MasterHex hex)
List creatures that can be recruited in this terrain in a special way now. |
protected void |
initCustomVariant()
|
static void |
initCustomVariantForAllCRBs()
|
abstract int |
numberOfRecruiterNeeded(CreatureType recruiter,
CreatureType recruit,
MasterHex hex)
Number of recruiters needed to get a recruit in a special way in this terrain now. |
static void |
reset()
|
static void |
resetAllInstances()
|
protected abstract void |
resetInstance()
Reset, called at the beginning of a game. |
protected void |
setCount(CreatureType type,
int newCount,
boolean reset)
|
static void |
setGame(GameServerSide g)
|
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
protected static final java.util.List<Player> allPlayers
private static final java.util.List<Caretaker> allCaretakerInfo
private static GameServerSide serverGame
private static final java.util.List<CustomRecruitBase> allCustomRecruitBase
Constructor Detail |
---|
public CustomRecruitBase()
Method Detail |
---|
public static final void reset()
public static final void resetAllInstances()
protected void initCustomVariant()
public static final void initCustomVariantForAllCRBs()
public static final void everyoneAdvanceTurn(int newActivePlayer)
public static final void addPlayerClientSide(Player pi)
public static final void addCaretakerClientSide(Caretaker ci)
public static final void setGame(GameServerSide g)
protected final void setCount(CreatureType type, int newCount, boolean reset)
protected final void adjustAvailableCount(CreatureType type)
protected final int getCount(CreatureType type)
protected final int getDeadCount(CreatureType type)
public abstract java.util.List<CreatureType> getAllPossibleSpecialRecruiters(MasterBoardTerrain terrain)
getAllPossibleSpecialRecruiters
in interface ICustomRecruitBase
public abstract java.util.List<CreatureType> getAllPossibleSpecialRecruits(MasterBoardTerrain terrain)
getAllPossibleSpecialRecruits
in interface ICustomRecruitBase
public abstract java.util.List<CreatureType> getPossibleSpecialRecruiters(MasterHex hex)
getPossibleSpecialRecruiters
in interface ICustomRecruitBase
hex
- The specific MasterHex considered for recruiting.
public abstract java.util.List<CreatureType> getPossibleSpecialRecruits(MasterHex hex)
getPossibleSpecialRecruits
in interface ICustomRecruitBase
hex
- The specific MasterHex considered for recruiting
(for an example, see getPossibleSpecialRecruits() in
BalrogRecruitment.java in Balrog variant directory)
public abstract int numberOfRecruiterNeeded(CreatureType recruiter, CreatureType recruit, MasterHex hex)
numberOfRecruiterNeeded
in interface ICustomRecruitBase
protected abstract void changeOfTurn(int newActivePlayer)
protected abstract void resetInstance()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |