src/main/java/ru/alphatech/icfpc/policy/VitalityBoostPolicy.java
changeset 24 7938ec9d4fe0
parent 21 b0748d485790
child 32 04ac70718172
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/main/java/ru/alphatech/icfpc/policy/VitalityBoostPolicy.java	Sat Jun 18 19:46:50 2011 +0400
     1.3 @@ -0,0 +1,52 @@
     1.4 +package ru.alphatech.icfpc.policy;
     1.5 +
     1.6 +import ru.alphatech.icfpc.cards.Dbl;
     1.7 +import ru.alphatech.icfpc.cards.Succ;
     1.8 +import ru.alphatech.icfpc.cards.Zero;
     1.9 +import ru.alphatech.icfpc.game.Player;
    1.10 +
    1.11 +public class VitalityBoostPolicy extends AbstractPolicy {
    1.12 +	
    1.13 +	public static final int turnsCount = 100;
    1.14 +	
    1.15 +	public VitalityBoostPolicy(int targetSlot, Player player) {
    1.16 +		super(turnsCount, player);
    1.17 +		this.targetSlot = targetSlot;
    1.18 +		
    1.19 +		maxValueSlotNum = player.getStatistic().maxValueSlotNum;
    1.20 +		maxValue = player.getStatistic().maxValue;
    1.21 +		firstIdentitySlot = -1;
    1.22 +	}
    1.23 +	
    1.24 +	protected int targetSlot = -1;
    1.25 +	protected int maxValueSlotNum = -1;
    1.26 +	protected int maxValue = -1;
    1.27 +	protected int firstIdentitySlot = -1;
    1.28 +	
    1.29 +	public boolean next() {
    1.30 +		if ( super.next() ){
    1.31 +			
    1.32 +			switch (getCurrentTurns()) {
    1.33 +				case 0:
    1.34 +				break;
    1.35 +				case 1:
    1.36 +				case 2:
    1.37 +				break;
    1.38 +				case 3:
    1.39 +				case 4:
    1.40 +				case 5:
    1.41 +				case 6:
    1.42 +				case 7:
    1.43 +				case 8:
    1.44 +				case 9:
    1.45 +				case 10:
    1.46 +				break;
    1.47 +				case 11:
    1.48 +				break;
    1.49 +			}
    1.50 +			
    1.51 +		}
    1.52 +		return false;
    1.53 +	}
    1.54 +
    1.55 +}