示例#1
0
    private void Start()
    {
        m_ui = transform.Find("EnemyUI").GetComponent <UI.UnitUI>();

        m_navMeshAgent = GetComponent <NavMeshAgent>();
        m_animator     = GetComponent <Animator>();

        m_speedHash  = Animator.StringToHash("Speed");
        m_attackHash = Animator.StringToHash("Attack");

        m_hp = 100;
    }
示例#2
0
文件: Unit.cs 项目: SIL3nCe/DontWreck
    ///==================================================================================
    ///ENGINE METHODS
    ///==================================================================================

    private void Awake()
    {
        m_ui = transform.Find("UnitUI").GetComponent <UI.UnitUI>();

        m_target = new STarget(ETargetType.NONE, null, null);

        m_maxHp = 100;

        SetHP(m_maxHp);
        SetSelected(false);

        m_animStopped = true;
    }