@HideInInspector
var GameLogicObj : GameObject;
var ButtonID : String;
function Awake ()
{
GameLogicObj = GameObject.FindGameObjectWithTag(“GameLogic”).gameObject;
}
function OnMouseOver ()
{
if(Input.GetButtonDown(“Fire1”));
{
if(ButtonID == “Attachments_IronSight”);
{
GameLogicObj.GetComponent(GameLogic).MainSightID = 1;
}
if(ButtonID == “Attachments_EOTech”);
{
GameLogicObj.GetComponent(GameLogic).MainSightID = 2;
}
}
}
I keep getting the error Assets/Scripts/ButtonTier1.js(16,90) BCE0044 expecting :, found =
Assets/Scripts/ButtonTier1.js(14,25) BCE0045 unexpected token if.
can someone plz help me