// Use this for initialization void Start() { if (!isServer) { return; } Players = GameObject.FindGameObjectsWithTag("Player"); pathTarget = GetComponent <EnemyController>(); isFireing = GetComponent <EnemyWeaponShooter>(); if (transform.Find("Hand") != null) { rotationTarget = transform.Find("Hand").GetComponent <EnemyArmRotation>(); } }
void Start() { enemy = GetComponent <EnemyMovement>(); enemyArm = GetComponentInChildren <EnemyArmRotation>(); enemyWeapon = GetComponentInChildren <EnemyWeapon>(); character = GameObject.Find("Main Character Doesn't Run(Clone)"); pHealth = character.GetComponent <playerHealth>(); if (character == null) { Debug.Log("FREAK OUT"); } if (enemyArm == null || enemyWeapon == null) { Debug.Log("FREAK OUT"); } }