public override void OnInspectorGUI()
        {
            if (!bClass)
            {
                bClass = (AIStateMachine)target;
            }
            DrawType();
            GUILayout.Space(10f);

            base.OnInspectorGUI();
        }
 /// <summary>
 ///     Assign the state machine that is handling this script
 /// </summary>
 /// <param name="_statemachine"></param>
 public override void SetStateMachine(AIStateMachine _statemachine)
 {
     if (_statemachine.GetType() == typeof(AIRandomStateMachine))
     {
         stateMachine = (AIRandomStateMachine)_statemachine;
         base.SetStateMachine(stateMachine);
     }
     else
     {
         Debug.LogError("[AIRandomState.SetStateMachine()] Wrong state machine passed");
     }
 }
示例#3
0
        /// <summary>
        ///     Determines if this object can be shoot at
        /// </summary>

        public virtual void SetStateMachine(AIStateMachine _statemachine)
        {
            baseStateMachine = _statemachine;
        }