Exemple #1
0
    protected override void Awake()
    {
        base.Awake();

        _targetChecker = GetComponent <CMonsterTargetChecker>();
        _monsterMove   = GetComponent <CMonsterMovement>();
    }
Exemple #2
0
    // 확장 피격 처리
    public override void Damage(float damage)
    {
        base.Damage(damage); // 부모의 데미지 처리 수행

        if (_damageValueText != null)
        {
            _damageValueText.DamageValueShow((damage * 100).ToString());
        }

        CMonsterMovement mv = GetComponent <CMonsterMovement>();

        if (mv != null)
        {
            mv.IdleTimeStop(0.3f);
        }

        // 이펙트가 생성됩니다.
        // 피격 이펙트를 생성
        GameObject effect = Instantiate(_damageEffectPrefab,
                                        _damageEffectPos.position, Quaternion.identity);

        Destroy(effect, 0.25f);
    }
Exemple #3
0
 protected override void Awake()
 {
     base.Awake();
     _movement = GetComponent <CMonsterMovement>();
     _fsm      = GetComponent <CMonsterFSM>();
 }
Exemple #4
0
 void Awake()
 {
     _movement = GetComponent <CMonsterMovement>();
     _anim     = GetComponent <CMonsterAnimation>();
     _attack   = GetComponent <CMonsterAttack>();
 }