Пример #1
0
    // Стреляем
    public void Shoot()
    {
        ShellManager shell = Instantiate(shellPrefab);

        shell.transform.position = aim.SpawnPoint.position;
        shell.RBody.gravityScale = aim.ShellGravityScale;
        shell.RBody.velocity     = aim.LookDirection.normalized * aim.LaunchSpeed;

        shell.Init(weaponMeta);
        soundManager.Play(SoundName.Shoot, true);
    }