Back to project page dragon-wars.
The source code is released under:
GNU General Public License
If you think the Android project dragon-wars listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.group7.dragonwars.engine.GoalArbitration; /*w w w.j av a 2 s. com*/ import com.group7.dragonwars.engine.GameState; import com.group7.dragonwars.engine.Unit; //abstract class from which "AttackUnit, DefendTile, MoveTo, CaptureTile" etc are derived from public abstract class AtomicAction { private float actionValue = 0; protected GameState gameState; protected Unit actionUnit; public AtomicAction(final GameState gamestate, final Unit unit, final float value) { actionValue = value; gameState = gamestate; actionUnit = unit; } public abstract void Perform(); public Unit getUnit() { return actionUnit; } public float getActionValue() { return actionValue; } }