private void OnTriggerEnter2D(Collider2D collision) { WeaponAttachments weaponAttachments = collision.gameObject.GetComponent <CharacterHandleWeapon>()._weaponAttachments; weaponAttachments?.CreateWeapon(_rifleWeapon); Destroy(gameObject); }
public StoreController(WeaponController weaponController, Player player, WeaponAttachments weaponAttachments, SignalBus bus) { _weaponController = weaponController; _player = player; _weaponAttachments = weaponAttachments; _bus = bus; }
private void Awake() { shotDelayHold = _shotDelay; _weaponEffects = GetComponentInChildren <WeaponEffects>(); _weaponAttachments = GetComponentInParent <WeaponAttachments>(); }