dice_war.AI
Class GoAhead

java.lang.Object
  extended by dice_war.AITemplate
      extended by dice_war.AI.GoAhead
All Implemented Interfaces:
java.lang.Runnable

public class GoAhead
extends AITemplate

An example of AI, the strategy is simple, attack if it's attackable. arrange more new dices to the nodes which have more enemies in neighbor


Field Summary
 
Fields inherited from class dice_war.AITemplate
edge, edgeList, MAX_DICE, myCountry, nodes, probabilityTable
 
Constructor Summary
GoAhead()
           
 
Method Summary
protected  void arrangeNewDices(int nNewDice)
          the core of game play, when it's your turn, UserInterface will call this method.
protected  void main()
          the core of game play, when it's your turn, UserInterface will call this method.
 
Methods inherited from class dice_war.AITemplate
appendNewDice, attack, isAttackable, run
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GoAhead

public GoAhead()
Method Detail

main

protected void main()
Description copied from class: AITemplate
the core of game play, when it's your turn, UserInterface will call this method. Override this to do the strategy of attack.

Specified by:
main in class AITemplate

arrangeNewDices

protected void arrangeNewDices(int nNewDice)
Description copied from class: AITemplate
the core of game play, when it's your turn, UserInterface will call this method. Override this to do the strategy of attack.

Specified by:
arrangeNewDices in class AITemplate