//Jimmy Vegas Unity Tutorial //This script is for the aiming using System.Collections; using System.Collections.Generic; using UnityEngine; public class FiringPistol : MonoBehaviour { public bool isAiming = false; public GameObject thePlayer; void Update() { if (Input.GetMouseButton(1)) { isAiming = true; thePlayer.GetComponent().Play("Aiming1Pistol"); } else { isAiming = false; //thePlayer.GetComponent().Play("Idle"); } } }