void Info_update() { GameObject obj = GameObject.Find("mainslider"); if (obj == null) { Debug.Log("No Slider Object."); } else { Debug.Log("Slider Object."); } Slider mainslider = (Slider)obj.GetComponent <Slider>(); // 设置进度条开始拍数和结束拍数 GameObject obj1 = GameObject.Find("num"); if (obj1 == null) { Debug.Log("No num Object."); } else { Debug.Log("num Object."); } Text num = (Text)obj1.GetComponent <Text>(); num.text = mainslider.value.ToString() + "/" + mainslider.maxValue.ToString(); int step = (int)mainslider.value; //Debug.Log("step" + step); GameObject obj2 = GameObject.Find("B0_vl"); if (obj1 == null) { Debug.Log("No B0_vl Object."); } else { Debug.Log("B0_vl Object."); } Text B0_vl = (Text)obj2.GetComponent <Text>(); Debug.Log("++"); //B0_vl.text = dr.Index(step).BlueRobot[0].pos.x.ToString(); B0_vl.text = "0"; // MatchInfo Event.Send(Event.EventType1.ReplayInfoUpdate, dr.Index(step)); }