Question by
zayan24 · Jan 06, 2016 at 01:53 AM ·
fpsaimdownsights
Aim Down Sights Script Unable to Work
So I've been working on a sci-fi FPS and it's a good game so far. The thing that's bugging me is the ADS script. I used it on the first level, and it's presto easy! On the second level, the exact script is copied and aims all they way to the left. Help me as I need this answer soon!
SCRIPT:
pragma strict
var Crosshair : GameObject;
function Update () {
if(Input.GetKeyDown(KeyCode.L))
{
transform.localPosition = Vector3(0,-0.36,0.77);
Crosshair.SetActive(false);
}
if(Input.GetKeyUp(KeyCode.L))
{
transform.localPosition = Vector3(0.32,-0.34,1.11);
Crosshair.SetActive(true);
}
}
Comment