0.3.2.10 업데이트2 (병합)
This commit is contained in:
parent
30423a4755
commit
3db4870837
File diff suppressed because it is too large
Load Diff
@ -283,6 +283,8 @@ namespace BlueWater.Tycoons
|
||||
// TODO : 레벨업 연출 추가 및 업그레이드 연출
|
||||
var tycoonManager = TycoonManager.Instance;
|
||||
var currentLevelData = tycoonManager.GetCurrentLevelData();
|
||||
EventManager.InvokeLevelUp(currentLevelData);
|
||||
|
||||
switch (currentLevelData.OpenUpgrade)
|
||||
{
|
||||
case "Upgrade0":
|
||||
@ -314,8 +316,6 @@ namespace BlueWater.Tycoons
|
||||
tycoonManager.TycoonIngredientController.GarnishBarrel2.Activate();
|
||||
break;
|
||||
}
|
||||
|
||||
EventManager.InvokeLevelUp(currentLevelData);
|
||||
}
|
||||
}
|
||||
}
|
@ -35,7 +35,7 @@ namespace BlueWater.Uis
|
||||
|
||||
private void Awake()
|
||||
{
|
||||
EventManager.OnLevelUp += Test;
|
||||
EventManager.OnLevelUp += CreateCardEvent;
|
||||
|
||||
_panel = transform.Find("Panel").gameObject;
|
||||
HideUi();
|
||||
@ -48,7 +48,7 @@ namespace BlueWater.Uis
|
||||
|
||||
private void OnDestroy()
|
||||
{
|
||||
EventManager.OnLevelUp -= Test;
|
||||
EventManager.OnLevelUp -= CreateCardEvent;
|
||||
}
|
||||
|
||||
[Button("카드 생성하기(레벨업)")]
|
||||
@ -147,7 +147,7 @@ namespace BlueWater.Uis
|
||||
_tycoonCard03Componet.Rotation_Start();
|
||||
}
|
||||
|
||||
private void Test(LevelData levelData)
|
||||
private void CreateCardEvent(LevelData levelData)
|
||||
{
|
||||
_lvData = levelData;
|
||||
if (_lvData.Idx == "1") return;
|
||||
@ -301,9 +301,9 @@ namespace BlueWater.Uis
|
||||
|
||||
HideUi();
|
||||
|
||||
if (int.Parse(_lvData.Idx) %5 == 0)
|
||||
if (int.Parse(_lvData.Idx) % 5 == 0)
|
||||
{
|
||||
_upgradePopup.SetActive(true);
|
||||
EventManager.InvokeUpgradeUi(_lvData);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -5,25 +5,35 @@ using UnityEngine.UI;
|
||||
|
||||
public class Upgrade_Popup : MonoBehaviour
|
||||
{
|
||||
[SerializeField]
|
||||
private GameObject _panel;
|
||||
|
||||
[SerializeField]
|
||||
private AnimationController _animationController;
|
||||
private bool isReversing = false; // 애니메이션 상태를 체크할 변수
|
||||
|
||||
[SerializeField]
|
||||
private Image information; //정보를 알려주는 이미지
|
||||
|
||||
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void OnEnable()
|
||||
|
||||
private void Start()
|
||||
{
|
||||
StartCoroutine(StartUpgradePopup());
|
||||
EventManager.OnUpgradeUi += StartUpgradePopup;
|
||||
}
|
||||
|
||||
private void OnDestroy()
|
||||
{
|
||||
EventManager.OnUpgradeUi -= StartUpgradePopup;
|
||||
}
|
||||
|
||||
private void StartUpgradePopup(LevelData currentLevelData)
|
||||
{
|
||||
StartCoroutine(StartUpgradePopupCoroutine(currentLevelData));
|
||||
}
|
||||
|
||||
// ReSharper disable Unity.PerformanceAnalysis
|
||||
private IEnumerator StartUpgradePopup()
|
||||
private IEnumerator StartUpgradePopupCoroutine(LevelData currentLevelData)
|
||||
{
|
||||
|
||||
|
||||
ShowUi();
|
||||
float timer = 0f;
|
||||
|
||||
while (timer < 1.0f)
|
||||
@ -78,7 +88,9 @@ public class Upgrade_Popup : MonoBehaviour
|
||||
}
|
||||
|
||||
VisualFeedbackManager.Instance.ResetTimeScale();
|
||||
gameObject.SetActive(false);
|
||||
HideUi();
|
||||
}
|
||||
|
||||
|
||||
public void ShowUi() => _panel.SetActive(true);
|
||||
public void HideUi() => _panel.SetActive(false);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user