ive been writing some script and now i get a problem i get 2 errors this is my code so please help guys this is the only place i have left to turn to im a noob at this
the errors i get are :expression denotes a value where a method groups was expected and that is on line 7 on the first if statement and the the second is : the name speed does not exsist in the current context
using UnityEngine;
using System.Collections;
public class accel : MonoBehaviour {
void OnGUI() {
if(GUI.Button(new Rect(10, 10, 100, 50),"Accel"))
{
if ((groundtrigger.triggered == 1) (Input.GetButton ("Fire1 "))( speed <800)) {speed += Time.deltaTime * 240;}
else if ((groundtrigger.triggered == 1) (Input.GetButton ("Fire1 "))( speed <800)) {speed += Time.deltaTime * 240;}
}
}
}