프로젝트 Common 스크립트 추가

This commit is contained in:
aube.lee
2025-01-21 22:53:52 +09:00
parent 8c2341ff7e
commit 3bb9913d16
38 changed files with 1672 additions and 121 deletions

View File

@@ -0,0 +1,35 @@
using System.Collections;
using System.Collections.Generic;
using TMPro;
using UnityEngine;
using UnityEngine.UI;
namespace TON
{
public class IngameUI : UIBase
{
public static IngameUI Instance => UIManager.Singleton.GetUI<IngameUI>(UIList.IngameUI);
public Image hpBar;
public Image spBar;
public TextMeshProUGUI hpText;
public TextMeshProUGUI spText;
public void SetHP(float current, float max)
{
hpBar.fillAmount = current / max;
hpText.text = $"{current:0} / {max: 0}";
}
public void SetSP(float current, float max)
{
spBar.fillAmount = current / max;
spText.text = $"{current:0} / {max: 0}";
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: c00fc90238999db44b3bd05365097e20
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,11 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace TON
{
public class LoadingUI : UIBase
{
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 8a8d039df45deab40974bc49691b2dba
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,19 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace TON
{
public class TitleUI : UIBase
{
public void OnClickStartButton()
{
Main.Singleton?.ChangeScene(SceneType.Ingame);
}
public void OnClickExitButton()
{
Main.Singleton?.SystemQuit();
}
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: fc0dce4fb90a31a43927108fa0c15b2b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: