#pragma strict

private var Action : String = "WalkForward";

function OnTriggerEnter (other : Collider) {
	if (other.name == "bot") {
		Destroy(gameObject);
		other.GetComponent("Walk").SendMessage("SetAction", Action);
	}
}

function SetAction(newAction : String) {
	Debug.Log("foo"+newAction);
	Action = newAction;
}