// Update is called once per frame void Update () { if (drone.isDroneConnected) { GetComponent<Renderer>().material.color = Color.green; if(!connectMessageShow) { message.showMessage("Drohne verbunden!"); connectMessageShow = true; disconnectMessageShow = false; } } else { GetComponent<Renderer>().material.color = Color.red; if(!disconnectMessageShow) { message.showMessage("Drohne disconnected!", Color.red); disconnectMessageShow = true; connectMessageShow = false; } } }