示例#1
0
 void Start()
 {
     recoilHandler = RecoilHandlerObject.GetComponent <IRecoilHandler>();
     anim          = GetComponent <Animator>();
     //PlaceHands();
     // toimii currentAmmo = maxAmmo;
     ammo = magazine * mags;
 }
 // Start is called before the first frame update
 void Start()
 {
     recoilHandler = recoilHandlerObject.GetComponent <IRecoilHandler>();
     foreach (Transform child in transform)
     {
         GameObject obj = child.gameObject;
         obj.SetActive(false);
         weapons.Add(child.gameObject);
     }
     EquipWeapon(activeWeaponIndex);
 }
示例#3
0
 // Start is called before the first frame update
 void Start()
 {
     ammoText      = GameObject.Find("ammoText (TMP)").GetComponent <TextMeshProUGUI>();;
     recoilHandler = recoilHandlerObject.GetComponent <IRecoilHandler>();
     foreach (Transform child in transform)
     {
         GameObject obj = child.gameObject;
         obj.SetActive(false);
         weapons.Add(child.gameObject);
     }
     EquipWeapon(activeWeaponIndex);
 }