void OnTriggerEnter(Collider other) { if (other.gameObject == ball) { gui g = Camera.main.gameObject.GetComponent <gui>(); PlayerPrefs.SetInt("last_score", g.score); Application.LoadLevel("testing"); } }
// Use this for initialization void Start() { S = this; player1Goals = 0; player2Goals = 0; rightScore = GameObject.Find("ScoreRight").GetComponent <Text> (); leftScore = GameObject.Find("ScoreLeft").GetComponent <Text>(); goalText = GameObject.Find("GoalText"); goalText.SetActive(false); }
void Start() { rigidbody = GetComponent <Rigidbody>(); input = new Vector3(); jumpCount = 0; startPoint = GameObject.FindGameObjectWithTag("Start Point").transform.position; Cursor.visible = false; Cursor.lockState = CursorLockMode.Locked; cam = Camera.main; gameGUI = GameObject.Find("Canvas").GetComponentInChildren <gui>(); GameObject floor = GameObject.FindGameObjectWithTag("Floor"); floor.GetComponent <Renderer>().material.mainTexture.wrapMode = TextureWrapMode.Repeat; sensitivitySlider = GameObject.FindObjectOfType <Slider>(); sensitivitySlider.value = lookSensitivity; }
public void updateWindow(gui.Window window) { if(_settings.updateWindows) { _background.wait(); _client.execute(() => Protocol.requestWindowUpdate(window, _connection)); _requestGui(); } }
showItems.Append(gui.LineBreak);