void Start() { agent = GetComponent <NavMeshAgent>(); myPathBuilder = waypointManager.GetComponent <PathBuilder_FS> (); agent.autoBraking = false; GoToNextPoint(); }
public override void OnInspectorGUI() { DrawDefaultInspector(); PathBuilder_FS myScript = (PathBuilder_FS)target; if (GUILayout.Button("Build Path Point")) { myScript.BuildPath(); } if (GUILayout.Button("Clear All Paths")) { myScript.ClearPath(); } }