using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class GunHolder : MonoBehaviour
{
    public bool behind;
    // Start is called before the first frame update
    void Start()
    {
        behind = false;
    }

    // Update is called once per frame
    void FixedUpdate()
    {
        
        if (behind == false)
        {
            transform.position = new Vector3(transform.position.x, transform.position.y, -0.03f);
        }
        if (behind == true)
        {
            transform.position = new Vector3(transform.position.x, transform.position.y, -0.01f);
        }
    }
}
