示例#1
0
    public virtual void Receive(int _damage, bool _bCritical)
    {
        if (!bScriptEnable)
        {
            return;
        }

        int damage = m_characterInfo.DamageCalculation(_damage);

        DamageFontManager.Inst.ShowDamage(damage, DamageShowPosition(), _bCritical);
        m_characterInfo.HpDamage(damage);

        if (m_characterInfo.IsCharacterDie())
        {
            m_animator.SetTrigger("tDie");
            this.bScriptEnable = false;
        }

        if (m_randAudioFuntion != null)
        {
            m_randAudioFuntion.VoiceRandPlay("Hit");
        }
    }