您最多选择25个主题
主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
32 行
648 B
32 行
648 B
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
namespace HuaweiHmsDemo
|
|
{
|
|
public class TestTip : MonoBehaviour
|
|
{
|
|
public static TestTip Inst;
|
|
public Text text;
|
|
private bool dirty = false;
|
|
private string word = "";
|
|
public TestTip()
|
|
{
|
|
Inst = this;
|
|
}
|
|
|
|
public void ShowText(string t)
|
|
{
|
|
word += (t + "\n");
|
|
dirty = true;
|
|
}
|
|
|
|
public void Update(){
|
|
if(dirty){
|
|
dirty = false;
|
|
text.text = word;
|
|
}
|
|
}
|
|
}
|
|
}
|