mirror of
https://github.com/DerTyp7/fps-citybuild-unity.git
synced 2025-10-29 20:22:08 +01:00
24 lines
518 B
C#
24 lines
518 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
public class TimeTextScript : MonoBehaviour
|
|
{
|
|
private GameObject GameManager;
|
|
|
|
private string timeStr = "";
|
|
private Text timeText;
|
|
|
|
private void Start()
|
|
{
|
|
GameManager = GameObject.Find("GameManager");
|
|
timeText = GetComponent<Text>();
|
|
}
|
|
void Update()
|
|
{
|
|
timeStr = GameManager.GetComponent<TimeManager>().GetTimeString();
|
|
timeText.text = timeStr;
|
|
}
|
|
}
|