public static void setEvalFunc() { string nameOne = Config.getValue("ai", "alphabeta_eval_one"); string nameTwo = Config.getValue("ai", "alphabeta_eval_two"); //Set One if (nameOne.Equals("evade")) { playerOneEvalFunc += evade; } else if (nameOne.Equals("attack")) { playerOneEvalFunc += attack; } else if (nameOne.Equals("ratio")) { playerOneEvalFunc += ratio; } else if (nameOne.Equals("mixed")) { playerOneEvalFunc += mixed; } else if (nameOne.Equals("mixed_over_time")) { playerOneEvalFunc += mixedOverTime; } else { MainMethod.die("State.setEvalFunc : Function named: \"" + nameOne + "\" not recognized for player One."); } //Set Two if (nameTwo.Equals("evade")) { playerTwoEvalFunc += evade; } else if (nameTwo.Equals("attack")) { playerTwoEvalFunc += attack; } else if (nameTwo.Equals("ratio")) { playerTwoEvalFunc += ratio; } else if (nameTwo.Equals("mixed")) { playerTwoEvalFunc += mixed; } else if (nameTwo.Equals("mixed_over_time")) { playerTwoEvalFunc += mixedOverTime; } else { MainMethod.die("State.setEvalFunc : Function named: \"" + nameOne + "\" not recognized for player One."); } }
public static void setEvalFunc() { string nameOne = Config.getValue("ai", "alphabeta_eval_one"); string nameTwo = Config.getValue("ai", "alphabeta_eval_two"); //Set One if(nameOne.Equals("evade")) { playerOneEvalFunc += evade; } else if (nameOne.Equals("attack")) { playerOneEvalFunc += attack; } else if (nameOne.Equals("ratio")) { playerOneEvalFunc += ratio; } else if (nameOne.Equals("mixed")) { playerOneEvalFunc += mixed; } else if (nameOne.Equals("mixed_over_time")) { playerOneEvalFunc += mixedOverTime; } else { MainMethod.die("State.setEvalFunc : Function named: \"" + nameOne + "\" not recognized for player One."); } //Set Two if (nameTwo.Equals("evade")) { playerTwoEvalFunc += evade; } else if (nameTwo.Equals("attack")) { playerTwoEvalFunc += attack; } else if (nameTwo.Equals("ratio")) { playerTwoEvalFunc += ratio; } else if (nameTwo.Equals("mixed")) { playerTwoEvalFunc += mixed; } else if (nameTwo.Equals("mixed_over_time")) { playerTwoEvalFunc += mixedOverTime; } else { MainMethod.die("State.setEvalFunc : Function named: \"" + nameOne + "\" not recognized for player One."); } }