12345678910111213141516171819202122232425262728293031323334 |
- using QFramework;
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- public class LoadShow : MonoSingleton<LoadShow>
- {
- public int allDownLoad;
- public Text text;
- public GameObject view;
- float progress;
- void Start()
- {
-
- }
- // Update is called once per frame
- void Update()
- {
-
- if (view.activeSelf)
- {
- progress = (float)(allDownLoad - (DownLoadManage.Instance.AllDownLoad + DownLoadManage.Instance.NowDownLoad)) / (float)allDownLoad*100;
- text.text = progress.ToString("F2")+"%";
- }
-
- }
- public void ViewShow(bool state)
- {
- view.SetActive(state);
- }
- }
|