ClientServer/Client/Assets/Scripts/Util/TestServerLobbyText.cs
TG9six 03a642d635 first push
first push
2025-09-06 17:17:39 +04:00

39 lines
948 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using TMPro;
public class TestServerLobbyText : MonoBehaviour
{
public static TestServerLobbyText Instance;
private TextMeshPro welcomeText;
private void Awake()
{
Instance = this;
welcomeText = GetComponent<TextMeshPro>();
welcomeText.gameObject.SetActive(false);
}
public void SetWelcomeText(string message, bool isLiveServer, bool isTestServer, bool isLocalServer)
{
if (isLiveServer)
{
welcomeText.gameObject.SetActive(false);
}
else if (isTestServer)
{
welcomeText.gameObject.SetActive(true);
welcomeText.SetText("Welcome To \n Test Server!");
}
else if (isLocalServer)
{
welcomeText.gameObject.SetActive(true);
welcomeText.SetText("Welcome To \n Local Server!");
}
}
}