예제 #1
0
    public void Initialization()
    {
        AgentAI          = GetComponent <NavMeshAgent>();
        RIGI.isKinematic = true;

        RIGI = GetComponent <Rigidbody>();
        anim = GetComponentInChildren <Animator>();

        ETarget = GetComponent <EnemyTarget>();
        ETarget.Init(this);
        InitRagDoll();
        EparryIsON   = false;
        IgnoreLayers = ~(1 << 9);
        EnemyPos     = this.transform.position;
    }
예제 #2
0
    void Start()
    {
        health      = 10000000;
        anim        = GetComponentInChildren <Animator>();
        enemyTarget = GetComponent <EnemyTarget>();
        enemyTarget.Init(this);

        rigid = GetComponent <Rigidbody>();

        a_hook = anim.GetComponent <AnimatorHook>();
        if (a_hook == null)
        {
            a_hook = anim.gameObject.AddComponent <AnimatorHook>();
        }
        a_hook.Init(null, this);

        InitRagdoll();
        parryIsOn = false;
    }
예제 #3
0
    public void Init()
    {
        health   = 100;
        anim     = GetComponentInChildren <Animator>();
        enTarget = GetComponent <EnemyTarget>();
        enTarget.Init(this);

        rigid             = GetComponent <Rigidbody>();
        agent             = GetComponent <NavMeshAgent>();
        rigid.isKinematic = true;

        a_hook = anim.GetComponent <AnimtorHook>();
        if (a_hook == null)
        {
            a_hook = anim.gameObject.AddComponent <AnimtorHook>();
        }
        a_hook.Init(null, this);
        InitRagDoll();
        //dataRecolected = GameObject.Find("DataRecolected").GetComponent<DataRecolected>();
        ignoreLayers = ~(1 << 9);
    }