Init repository
This commit is contained in:
Executable file
+28
@@ -0,0 +1,28 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
|
||||
public class TimeText3D : MonoBehaviour
|
||||
{
|
||||
public TMP_Text TextObject;
|
||||
|
||||
void Update()
|
||||
{
|
||||
if (TextObject)
|
||||
{
|
||||
string Time = TimeController.PublicFormattedTimeOfDay;
|
||||
TextObject.text = "In-game time: " + Time;
|
||||
}
|
||||
}
|
||||
|
||||
public void SetTimeFormat(bool is24hour)
|
||||
{
|
||||
TimeController.MilitaryTime = is24hour;
|
||||
}
|
||||
|
||||
private void OnMouseDown()
|
||||
{
|
||||
SetTimeFormat(!TimeController.MilitaryTime);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user