From b54b4a8b4325ea7e1763db6df5ed0d826dae0f55 Mon Sep 17 00:00:00 2001 From: NTG_Lenovo Date: Thu, 24 Oct 2024 17:05:32 +0900 Subject: [PATCH] =?UTF-8?q?0.3.2.4=20=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Assets/01.Scenes/01.Tycoon.unity | 189 ++++++++---------- .../Character/Npc/Customer/Customer.cs | 19 +- Assets/02.Scripts/EventManager.cs | 8 +- .../Prop/Tycoon/InteractionFuniture.cs | 3 + Assets/02.Scripts/Prop/Tycoon/TableSeat.cs | 25 ++- Assets/02.Scripts/Prop/Tycoon/Vomiting.cs | 26 ++- .../ScriptableObject/CardDataTable.asset | 4 +- Assets/02.Scripts/Ui/InteractionUi.cs | 4 +- Assets/02.Scripts/Ui/Tycoon/Bill.cs | 10 +- Assets/02.Scripts/Ui/Tycoon/TycoonCardArea.cs | 10 +- .../02.Scripts/Ui/Tycoon/TycoonSelectCard.cs | 28 +-- Assets/Resources/Excel/CardDataTable.xlsx | Bin 9607 -> 9616 bytes Assets/Resources/JSON/CardDataTable.json | 4 +- 13 files changed, 170 insertions(+), 160 deletions(-) diff --git a/Assets/01.Scenes/01.Tycoon.unity b/Assets/01.Scenes/01.Tycoon.unity index 3a8bd1736..aa2248500 100644 --- a/Assets/01.Scenes/01.Tycoon.unity +++ b/Assets/01.Scenes/01.Tycoon.unity @@ -2554,13 +2554,13 @@ RectTransform: m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: - - {fileID: 737939132} + - {fileID: 1621314686} m_Father: {fileID: 1049919592} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0.5} - m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 100, y: 100} + m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &186139409 MonoBehaviour: @@ -7651,112 +7651,6 @@ RectTransform: m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} ---- !u!1001 &737939131 -PrefabInstance: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_Modification: - serializedVersion: 3 - m_TransformParent: {fileID: 186139408} - m_Modifications: - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_Pivot.x - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_Pivot.y - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchorMax.x - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchorMax.y - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchorMin.x - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchorMin.y - value: 0.5 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_SizeDelta.x - value: 100 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_SizeDelta.y - value: 100 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalPosition.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalRotation.w - value: 1 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalRotation.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalRotation.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalRotation.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchoredPosition.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_AnchoredPosition.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalEulerAnglesHint.x - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalEulerAnglesHint.y - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_LocalEulerAnglesHint.z - value: 0 - objectReference: {fileID: 0} - - target: {fileID: 5785355462301107295, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_Name - value: Card - objectReference: {fileID: 0} - - target: {fileID: 5785355462301107295, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - propertyPath: m_IsActive - value: 0 - objectReference: {fileID: 0} - m_RemovedComponents: [] - m_RemovedGameObjects: [] - m_AddedGameObjects: [] - m_AddedComponents: [] - m_SourcePrefab: {fileID: 100100000, guid: 2116ffd228314c745b8615652b11d19e, type: 3} ---- !u!224 &737939132 stripped -RectTransform: - m_CorrespondingSourceObject: {fileID: 725714798138964366, guid: 2116ffd228314c745b8615652b11d19e, type: 3} - m_PrefabInstance: {fileID: 737939131} - m_PrefabAsset: {fileID: 0} --- !u!1 &738101929 GameObject: m_ObjectHideFlags: 0 @@ -18345,6 +18239,81 @@ MonoBehaviour: m_DeselectOnBackgroundClick: 1 m_PointerBehavior: 0 m_CursorLockBehavior: 0 +--- !u!1 &1621314685 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1621314686} + - component: {fileID: 1621314688} + - component: {fileID: 1621314687} + m_Layer: 5 + m_Name: Panel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &1621314686 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1621314685} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 186139408} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1621314687 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1621314685} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.78431374} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1621314688 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1621314685} + m_CullTransparentMesh: 1 --- !u!1001 &1627308700 PrefabInstance: m_ObjectHideFlags: 0 diff --git a/Assets/02.Scripts/Character/Npc/Customer/Customer.cs b/Assets/02.Scripts/Character/Npc/Customer/Customer.cs index 0a16ec50c..460e78556 100644 --- a/Assets/02.Scripts/Character/Npc/Customer/Customer.cs +++ b/Assets/02.Scripts/Character/Npc/Customer/Customer.cs @@ -33,7 +33,7 @@ namespace BlueWater.Npcs.Customers public enum CustomerInteractionType { None = 0, - OrderCocktail + ServedCocktail } public class Customer : MonoBehaviour, IPlayerInteraction, ICrewInteraction @@ -273,9 +273,16 @@ namespace BlueWater.Npcs.Customers public void ServedItem(CocktailData cocktailData) { - CurrentTableSeat.SetFood(); BalloonUi.ReceiveItem(cocktailData); - StateMachineController.TransitionToState(IsOrderedSucceed ? HappyState : UpsetState, this); + if (IsOrderedSucceed) + { + CurrentTableSeat.SetFood(); + StateMachineController.TransitionToState(HappyState, this); + } + else + { + StateMachineController.TransitionToState(UpsetState, this); + } } public void Interaction() @@ -284,7 +291,7 @@ namespace BlueWater.Npcs.Customers { case CustomerInteractionType.None: break; - case CustomerInteractionType.OrderCocktail: + case CustomerInteractionType.ServedCocktail: var currentPickupItem = GameManager.Instance.CurrentTycoonPlayer.TycoonPickupHandler.GetCurrentPickupItem(); var servedCocktailData = ItemManager.Instance.CocktailDataSo.GetDataByIdx(currentPickupItem.Idx); IsOrderedSucceed = currentPickupItem.Idx == OrderedCocktailData.Idx; @@ -306,7 +313,7 @@ namespace BlueWater.Npcs.Customers { case CustomerInteractionType.None: return false; - case CustomerInteractionType.OrderCocktail: + case CustomerInteractionType.ServedCocktail: var currentPickupItem = GameManager.Instance.CurrentTycoonPlayer.TycoonPickupHandler.GetCurrentPickupItem(); return currentPickupItem != null; default: @@ -438,7 +445,7 @@ namespace BlueWater.Npcs.Customers InteractionMessage = "칵테일 전달"; OrderedCocktailData = TycoonManager.Instance.TycoonIngredientController.GetRandomCocktailData(); BalloonUi.OrderItem(OrderedCocktailData.Idx, CurrentLevelData.WaitTime, CurrentLevelData.HurryTime); - _customerInteractionType = CustomerInteractionType.OrderCocktail; + _customerInteractionType = CustomerInteractionType.ServedCocktail; RegisterPlayerInteraction(); EventManager.InvokeOrderedCocktail(this); diff --git a/Assets/02.Scripts/EventManager.cs b/Assets/02.Scripts/EventManager.cs index 7c1c06b20..1f9079496 100644 --- a/Assets/02.Scripts/EventManager.cs +++ b/Assets/02.Scripts/EventManager.cs @@ -57,8 +57,12 @@ namespace BlueWater OnHideInteractionUi?.Invoke(); } - // 플레이어 상호작용중 이벤트 - public static Action OnInteracting; + // 플레이어 홀딩 상호작용중 이벤트 + public static Action OnHoldInteracting; + public static void InvokeHoldInteracting(float value) + { + OnHoldInteracting?.Invoke(value); + } #endregion diff --git a/Assets/02.Scripts/Prop/Tycoon/InteractionFuniture.cs b/Assets/02.Scripts/Prop/Tycoon/InteractionFuniture.cs index 181e2e581..2dec64a81 100644 --- a/Assets/02.Scripts/Prop/Tycoon/InteractionFuniture.cs +++ b/Assets/02.Scripts/Prop/Tycoon/InteractionFuniture.cs @@ -37,6 +37,7 @@ namespace BlueWater.Tycoons protected TycoonPlayer CurrentTycoonPlayer; protected bool IsQuitting; + protected bool IsShowing; protected Material OriginalMaterial; private void OnDrawGizmosSelected() @@ -100,6 +101,7 @@ namespace BlueWater.Tycoons { VisualLook.material = OutlineMaterial; EventManager.InvokeShowInteractionUi(InteractionMessage); + IsShowing = true; } public virtual void HideInteractionUi() @@ -109,6 +111,7 @@ namespace BlueWater.Tycoons VisualLook.material = OriginalMaterial; } EventManager.InvokeHideInteractionUi(); + IsShowing = false; } protected void RegisterPlayerInteraction() diff --git a/Assets/02.Scripts/Prop/Tycoon/TableSeat.cs b/Assets/02.Scripts/Prop/Tycoon/TableSeat.cs index cfbffda69..b265aa671 100644 --- a/Assets/02.Scripts/Prop/Tycoon/TableSeat.cs +++ b/Assets/02.Scripts/Prop/Tycoon/TableSeat.cs @@ -68,8 +68,6 @@ namespace BlueWater.Tycoons if (_isPlayerInteracting) { - var clamp = Mathf.Clamp(_playerElapsedTime / _interactionHoldingTime, 0f, 1f); - EventManager.OnInteracting?.Invoke(clamp); if (_playerElapsedTime > _interactionHoldingTime) { CleanTable(); @@ -77,6 +75,24 @@ namespace BlueWater.Tycoons _playerElapsedTime += Time.deltaTime; } + else + { + if (_playerElapsedTime > 0f) + { + _playerElapsedTime -= Time.deltaTime; + } + } + + var holdingGauge = 0f; + if (_playerElapsedTime > 0f) + { + holdingGauge = Mathf.Clamp(_playerElapsedTime / _interactionHoldingTime, 0f, 1f); + } + + if (IsShowing) + { + EventManager.InvokeHoldInteracting(holdingGauge); + } if (_isCrewInteracting) { @@ -110,16 +126,12 @@ namespace BlueWater.Tycoons public override void Interaction() { - _playerElapsedTime = 0f; - EventManager.OnInteracting?.Invoke(_playerElapsedTime); GameManager.Instance.CurrentTycoonPlayer.IsCleaningTable = true; _isPlayerInteracting = true; } public override void CancelInteraction() { - _playerElapsedTime = 0f; - EventManager.OnInteracting?.Invoke(_playerElapsedTime); GameManager.Instance.CurrentTycoonPlayer.IsCleaningTable = false; _isPlayerInteracting = false; } @@ -143,6 +155,7 @@ namespace BlueWater.Tycoons _isCrewInteracting = false; InteractionCanvas.BalloonUi.HideUi(); InteractionCanvas.BalloonUi.ResetUi(); + _playerElapsedTime = 0f; } public void DirtyTable() diff --git a/Assets/02.Scripts/Prop/Tycoon/Vomiting.cs b/Assets/02.Scripts/Prop/Tycoon/Vomiting.cs index 5ff1f9c2f..d9f42fa34 100644 --- a/Assets/02.Scripts/Prop/Tycoon/Vomiting.cs +++ b/Assets/02.Scripts/Prop/Tycoon/Vomiting.cs @@ -40,8 +40,6 @@ namespace BlueWater.Tycoons if (_isPlayerInteracting) { - var clamp = Mathf.Clamp(_playerElapsedTime / _interactionHoldingTime, 0f, 1f); - EventManager.OnInteracting?.Invoke(clamp); if (_playerElapsedTime > _interactionHoldingTime) { Destroy(); @@ -49,6 +47,24 @@ namespace BlueWater.Tycoons _playerElapsedTime += Time.deltaTime; } + else + { + if (_playerElapsedTime > 0f) + { + _playerElapsedTime -= Time.deltaTime; + } + } + + var holdingGauge = 0f; + if (_playerElapsedTime > 0f) + { + holdingGauge = Mathf.Clamp(_playerElapsedTime / _interactionHoldingTime, 0f, 1f); + } + + if (IsShowing) + { + EventManager.InvokeHoldInteracting(holdingGauge); + } if (_isCrewInteracting) { @@ -75,16 +91,12 @@ namespace BlueWater.Tycoons public override void Interaction() { - _playerElapsedTime = 0f; - EventManager.OnInteracting?.Invoke(_playerElapsedTime); GameManager.Instance.CurrentTycoonPlayer.IsCleaningFloor = true; _isPlayerInteracting = true; } public override void CancelInteraction() { - _playerElapsedTime = 0f; - EventManager.OnInteracting?.Invoke(_playerElapsedTime); GameManager.Instance.CurrentTycoonPlayer.IsCleaningFloor = false; _isPlayerInteracting = false; } @@ -102,14 +114,12 @@ namespace BlueWater.Tycoons public void InteractionCrew(Crew crew) { - _crewElapsedTime = 0f; _isCrewInteracting = true; ((CleanerCrew)crew).SetIsCleaningFloor(true); } public void CancelInteractionCrew() { - _crewElapsedTime = 0f; _isCrewInteracting = false; } diff --git a/Assets/02.Scripts/ScriptableObject/CardDataTable.asset b/Assets/02.Scripts/ScriptableObject/CardDataTable.asset index b90d7cd6d..cc6a9106e 100644 --- a/Assets/02.Scripts/ScriptableObject/CardDataTable.asset +++ b/Assets/02.Scripts/ScriptableObject/CardDataTable.asset @@ -130,7 +130,7 @@ MonoBehaviour: k__BackingField: k__BackingField: ExpGetUp k__BackingField: ExpGetUpImg - k__BackingField: "\uACBD\uD5D8\uCE58 \uD68D\uB4DD 5% \uC99D\uAC00" + k__BackingField: "\uACBD\uD5D8\uCE58 \uD68D\uB4DD 20% \uC99D\uAC00" k__BackingField: 10 k__BackingField: 5 k__BackingField: {fileID: 21300000, guid: 400a47b8bcd0a1e4b823160ce9f40232, type: 3} @@ -138,7 +138,7 @@ MonoBehaviour: k__BackingField: k__BackingField: GoldGetUp k__BackingField: GoldGetUpImg - k__BackingField: "\uACE8\uB4DC \uD68D\uB4DD 5% \uC99D\uAC00" + k__BackingField: "\uACE8\uB4DC \uD68D\uB4DD 20% \uC99D\uAC00" k__BackingField: 10 k__BackingField: 5 k__BackingField: {fileID: 21300000, guid: 121ed7da4e55d2a43ba798a00f95a474, type: 3} diff --git a/Assets/02.Scripts/Ui/InteractionUi.cs b/Assets/02.Scripts/Ui/InteractionUi.cs index 94912fc20..143e393d6 100644 --- a/Assets/02.Scripts/Ui/InteractionUi.cs +++ b/Assets/02.Scripts/Ui/InteractionUi.cs @@ -23,14 +23,14 @@ namespace BlueWater.Uis { EventManager.OnShowInteractionUi += ShowUi; EventManager.OnHideInteractionUi += HideUi; - EventManager.OnInteracting += SetFillAmount; + EventManager.OnHoldInteracting += SetFillAmount; } private void OnDestroy() { EventManager.OnShowInteractionUi -= ShowUi; EventManager.OnHideInteractionUi -= HideUi; - EventManager.OnInteracting -= SetFillAmount; + EventManager.OnHoldInteracting -= SetFillAmount; } public void ShowUi(string message) diff --git a/Assets/02.Scripts/Ui/Tycoon/Bill.cs b/Assets/02.Scripts/Ui/Tycoon/Bill.cs index 0dae25614..2d4595784 100644 --- a/Assets/02.Scripts/Ui/Tycoon/Bill.cs +++ b/Assets/02.Scripts/Ui/Tycoon/Bill.cs @@ -108,7 +108,7 @@ namespace BlueWater var rotationAngle = Mathf.Lerp(8f, 40f, distance / _maxDistance); var punchStrength = Mathf.Lerp(1f, 5f, distance / _maxDistance); - var moveSequence = DOTween.Sequence(); + var moveSequence = DOTween.Sequence().SetAutoKill(true); moveSequence.Append(_rect.DOLocalMoveX(CurrentBillInfo.Position.x, moveTime)); moveSequence.Join(_rect.DOLocalRotate(new Vector3(0, 0, rotationAngle), moveTime / 5f)); moveSequence.Join(_rect.DOPunchRotation(new Vector3(0f, 0f, punchStrength), moveTime * 4f / 5f, 3, 0.2f) @@ -174,14 +174,14 @@ namespace BlueWater public void BartenderMakingCocktail() { - _makingCocktailPivotObject.gameObject.SetActive(true); + _makingCocktailPivotObject?.gameObject.SetActive(true); } public void BartenderCompleteMakingCocktail() { - _makingCocktailPivotObject.gameObject.SetActive(false); - _checkImageObject.gameObject.SetActive(true); - _animationController.SetAnimationParameter("isBartenderChecked", true); + _makingCocktailPivotObject?.gameObject.SetActive(false); + _checkImageObject?.gameObject.SetActive(true); + _animationController?.SetAnimationParameter("isBartenderChecked", true); } } } \ No newline at end of file diff --git a/Assets/02.Scripts/Ui/Tycoon/TycoonCardArea.cs b/Assets/02.Scripts/Ui/Tycoon/TycoonCardArea.cs index 34b8a6829..a0436728f 100644 --- a/Assets/02.Scripts/Ui/Tycoon/TycoonCardArea.cs +++ b/Assets/02.Scripts/Ui/Tycoon/TycoonCardArea.cs @@ -36,7 +36,7 @@ public class TycoonCardArea : MonoBehaviour, IPointerEnterHandler, IPointerExitH private float _maxRotationAngle; private float _returnSpeed; - private TycoonCard _parent; //부모 + private TycoonCard _tycoonCard; //부모 private float _returnSpeedTime = 0.0f; // 복원속도를 더할 메서드 private bool _isPointerInside; // 이미지 안에 마우스가 있는지 여부를 추적 private Coroutine _startRotationCoroutine; @@ -49,12 +49,12 @@ public class TycoonCardArea : MonoBehaviour, IPointerEnterHandler, IPointerExitH private void Awake() { - _parent = transform.parent.GetComponent(); + _tycoonCard = transform.parent.GetComponent(); _rectTransform = this.GetComponent(); _cardComTransform = transform.parent.Find("CardCom").GetComponent(); _image = _cardComTransform.Find("Image").GetComponent(); - _maxRotationAngle = _parent.maxRotationAngle; - _returnSpeed = _parent.returnSpeed; + _maxRotationAngle = _tycoonCard.maxRotationAngle; + _returnSpeed = _tycoonCard.returnSpeed; } void Start() @@ -120,7 +120,7 @@ public class TycoonCardArea : MonoBehaviour, IPointerEnterHandler, IPointerExitH { if (_enable) { - _parent.transform.parent.GetComponent().SelectedCard(_parent); + _tycoonCard.transform.parent.parent.GetComponent().SelectedCard(_tycoonCard); //해당 밑줄은 따로 메소드를 만들어주자... 여기서 호출하는게 아니라 SelectCardUi에서 호출받는 방식으로... this.SetEnable(false); diff --git a/Assets/02.Scripts/Ui/Tycoon/TycoonSelectCard.cs b/Assets/02.Scripts/Ui/Tycoon/TycoonSelectCard.cs index 08e6a7f08..b5d08cb0a 100644 --- a/Assets/02.Scripts/Ui/Tycoon/TycoonSelectCard.cs +++ b/Assets/02.Scripts/Ui/Tycoon/TycoonSelectCard.cs @@ -1,10 +1,5 @@ -using System; using System.Collections; -using System.Collections.Generic; -using System.Linq; -using BlueWater.Players.Tycoons; using BlueWater.Tycoons; -using Mono.Cecil.Cil; using Sirenix.OdinInspector; using UnityEngine; using Random = UnityEngine.Random; @@ -13,7 +8,7 @@ namespace BlueWater.Uis { public class TycoonSelectCard : MonoBehaviour { - + private GameObject _panel; private Camera uiCamera; [field: SerializeField, CLabel("카드 1")] @@ -36,6 +31,9 @@ namespace BlueWater.Uis private void Awake() { EventManager.OnLevelUp += Test; + + _panel = transform.Find("Panel").gameObject; + HideUi(); } void Start() @@ -70,13 +68,13 @@ namespace BlueWater.Uis Destroy(_currentCard03); } - _currentCard01 = Instantiate(card01, this.transform); + _currentCard01 = Instantiate(card01, _panel.transform); _currentCard01.name = "Card01"; - _currentCard02 = Instantiate(card02, this.transform); + _currentCard02 = Instantiate(card02, _panel.transform); _currentCard02.name = "Card02"; - _currentCard03 = Instantiate(card03, this.transform); + _currentCard03 = Instantiate(card03, _panel.transform); _currentCard03.name = "Card03"; _currentCard01.transform.localPosition = new Vector3(-550, 0, 0); @@ -86,7 +84,8 @@ namespace BlueWater.Uis _tycoonCard01Componet = _currentCard01.GetComponent(); _tycoonCard02Componet = _currentCard02.GetComponent(); _tycoonCard03Componet = _currentCard03.GetComponent(); - + + ShowUi(); //----카드 값 지정 및 초기화---- @@ -181,9 +180,9 @@ namespace BlueWater.Uis case "SpeedUp": TycoonManager.Instance.TycoonStatus.PlayerMoveSpeedMultiplier += 0.05f; break; case "ExpGetUp": - TycoonManager.Instance.TycoonStatus.ExpMultiplier += 0.05f; break; + TycoonManager.Instance.TycoonStatus.ExpMultiplier += 0.2f; break; case "GoldGetUp": - TycoonManager.Instance.TycoonStatus.GoldMultiplier += 0.05f; break; + TycoonManager.Instance.TycoonStatus.GoldMultiplier += 0.2f; break; // case "CleanUp": return; break; // case "GaugeReset": return; break; default: Debug.Log("Not Found Card : IDX" + currTycoonCard.CardDataForIdx.Idx); return; break; @@ -290,7 +289,12 @@ namespace BlueWater.Uis Destroy(_currentCard03); } + HideUi(); + VisualFeedbackManager.Instance.ResetTimeScale(); } + + public void ShowUi() => _panel.SetActive(true); + public void HideUi() => _panel.SetActive(false); } } diff --git a/Assets/Resources/Excel/CardDataTable.xlsx b/Assets/Resources/Excel/CardDataTable.xlsx index ff314a0c0cb718b4928cbdbc7266d8c30413d6ef..ee43ce23c16edf3592b4cecd01578fb1c45af589 100644 GIT binary patch delta 2620 zcmV-C3d8k>OO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B}hz^*^Ake~->L8JloldfL zN>s0*21Am3YRQvdn5lXRiQ#)wNUABKnmyHRkVlzJ29jR=ZeR4@;kg_nmvcv4(@3uA zJK`!JxeD63if+t&UdbZCvU1QQ5K?lzsoo#UZ|C|VEhWrxt+J@q3k9O~d$ zer=Jgu5_KJF|^3nQ3=%#uSJkcp&I-0Y>%ifD{6N|ecsYgj+}tH3~lgM1?zC|Q?0i2 zI;_woW18G zknsmZ9d(g^jk8dXid5j7UTYw&UJU*uyB&4bfqlw`-0tczSPTOX?eInfYw_f}+}_vf z@2W`P)-RO+Z`fRfNL@QjR(tZ`14(xFp~tCRsHa!u2a`+k2h3X!0)I=ccjWe=>UPM* zX$=bdQYcECWn-PebH#4 zFgoe63PN0+!RZQpeEC-oe@rX7wKAQfoT5Gz+^YO{T`=L>jQtmrkpmP2B?YViv#=d0 z0e^!q7>4gn{12q}P+$jV11$3}Z`@)ci^jXA{k9QlY1%68-&6a$+ zFHw4*piNQ96h%RZJdmv7h1{iRlP~=l@{FaD)3TC~q5~K-&n_<#rUS#6 z_;vO8++Ni$WHT!UC`&jaOarx*&IDEJkl?{iGrf`;yK;lx7Qk-~S-!aU9yV)ly-Qdn z_;>7ht$qgu?l~dS>7SC9(d}KnL|Gh06F;2#;Ute{B)TS}@murvv-6E$w;_%W{}SV| zABAq^;T4HzWD*aECqUMEpFfK18iZyBP0ssKelZ_*M2|K&x`l|#0 z0KAhDBv%3KlWHVD0ilztBp@5IN$-XC)&B@ge{K003Ny-p~L5 diff --git a/Assets/Resources/JSON/CardDataTable.json b/Assets/Resources/JSON/CardDataTable.json index dfe1eba30..0493e324a 100644 --- a/Assets/Resources/JSON/CardDataTable.json +++ b/Assets/Resources/JSON/CardDataTable.json @@ -100,14 +100,14 @@ { "Idx": "ExpGetUp", "Img": "ExpGetUpImg", - "ScriptText": "경험치 획득 5% 증가", + "ScriptText": "경험치 획득 20% 증가", "Max": 10, "Ratio": 5 }, { "Idx": "GoldGetUp", "Img": "GoldGetUpImg", - "ScriptText": "골드 획득 5% 증가", + "ScriptText": "골드 획득 20% 증가", "Max": 10, "Ratio": 5 },