void Awake() { touchingGround = false; rbody2d = GetComponent<Rigidbody2D>(); animator = GetComponent<Animator>(); hashAnimatorCharacter = GetComponent<HashAnimatorCharacter>(); }
void Awake() { rbody2d = GetComponent<Rigidbody2D>(); animator = GetComponent<Animator>(); hashAnimatorCharacter = GetComponent<HashAnimatorCharacter>(); allWeapons = new WeaponShootAndKickback[allWeaponsObjects.Length]; for(int i=0; i<allWeaponsObjects.Length; i++){ allWeapons[i] = allWeaponsObjects[i].GetComponent<WeaponShootAndKickback>(); } ChangeWeapon(startingWeaponNumber); }