public void Ctor_None_NoMoves() { var instruction = new MoveInstruction(); var act = instruction.ToString(); var exp = "no_moves"; Assert.AreEqual(exp, act); }
public void Ctor_Skip_Skip() { var instruction = new MoveInstruction(ActionType.Skip); var act = instruction.ToString(); var exp = "skip"; Assert.AreEqual(exp, act); }
public void Ctor_TurnRightRightRightRightLeftDown_TurnRightRightDrop() { var instruction = new MoveInstruction(ActionType.TurnRight, ActionType.Right, ActionType.Right, ActionType.Right, ActionType.Left, ActionType.Left, ActionType.Down); var act = instruction.ToString(); var exp = "turnright,right,drop"; Assert.AreEqual(exp, act); }
public void Ctor_LeftDown_LeftDrop() { var instruction = new MoveInstruction(ActionType.Left, ActionType.Down); var act = instruction.ToString(); var exp = "left,drop"; Assert.AreEqual(exp, act); }
public BotResponse GetResponse(TimeSpan time) { SetDuration(time); var path = DecisionMaker.GetMove(Field, Opponent, Current, Next, State.Round); var move = new MoveInstruction(path.Moves.ToArray()); var response = new BotResponse() { Move = move, Log = DecisionMaker.GetLog(), }; return response; }