//Sets the AI function to use when making moves. public void setAIFunc(string funcName) { if (funcName == "random") { aiFunc = pickRandomMove; } else if (funcName == "alpha_beta") { aiFunc = alphaBeta; } else { MainMethod.die("Error : Player.setAIFunc : Function name: " + funcName + " is not supported"); } }
public void setCtrl(aiMove newCtrl) { ctrl = newCtrl; }
// Use this for initialization void Start() { ctrl = new aiMove(Vector2.zero); pm = GetComponent <PlayerMover>(); tree.ReEnable(); }