From 73557e3bbe55a3c4565048cb451b680036bb8795 Mon Sep 17 00:00:00 2001 From: henriquenakashima Date: Thu, 24 Sep 2020 23:29:30 -0400 Subject: [PATCH] Show which cards are disabled --- Assets/Battle/BattleScene.unity | 5 ----- Assets/Battle/UI/CardUI.cs | 5 ++++- Assets/Battle/UI/CardUI.prefab | 4 +++- TODO.txt | 3 ++- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Assets/Battle/BattleScene.unity b/Assets/Battle/BattleScene.unity index e3ee6ca..0885e25 100644 --- a/Assets/Battle/BattleScene.unity +++ b/Assets/Battle/BattleScene.unity @@ -303,11 +303,6 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 7b3535d42bc43e04ea1e8d2588ef0542, type: 3} m_Name: m_EditorClassIdentifier: - heroIds: 010000000000000002000000 - monsterIds: 010000000000000000000000 - cardIds: 00000000000000000000000001000000010000000100000004000000030000000300000007000000 - mCardIds: 06000000060000000800000001000000010000000100000005000000050000000200000002000000 - mCardOwnerIndexes: 00000000000000000000000001000000010000000200000000000000000000000100000002000000 heroUIPrefab: {fileID: 6641511084601005557, guid: ef1b469b45cedee418e4c4adf577cd00, type: 3} uiCanvas: {fileID: 35522588} diff --git a/Assets/Battle/UI/CardUI.cs b/Assets/Battle/UI/CardUI.cs index 749d940..349c8e1 100644 --- a/Assets/Battle/UI/CardUI.cs +++ b/Assets/Battle/UI/CardUI.cs @@ -23,6 +23,7 @@ public class CardUI : MonoBehaviour this.typeText.text = "????"; this.costText.text = "????"; this.effectText.text = "????"; + this.GetComponent().color = Color.black; } // Start is called before the first frame update @@ -38,6 +39,8 @@ public class CardUI : MonoBehaviour } public bool Playable { - set {this.nameText.color = value ? Color.black : Color.red;} + set { + this.GetComponent().color = value ? Color.white : Color.grey; + } } } diff --git a/Assets/Battle/UI/CardUI.prefab b/Assets/Battle/UI/CardUI.prefab index 1f43afe..8dafe33 100644 --- a/Assets/Battle/UI/CardUI.prefab +++ b/Assets/Battle/UI/CardUI.prefab @@ -143,7 +143,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0.9150943, g: 0.9150943, b: 0.9150943, a: 1} + m_Color: {r: 0.9137255, g: 0.9137255, b: 0.9137255, a: 1} m_RaycastTarget: 1 m_Maskable: 1 m_OnCullStateChanged: @@ -219,6 +219,8 @@ MonoBehaviour: costText: {fileID: 6834692580065399204} artImage: {fileID: 8419538927331240723} effectText: {fileID: 2477879197027808366} + normalMaterial: {fileID: 0} + disabledMaterial: {fileID: 0} --- !u!1 &2477879197027808364 GameObject: m_ObjectHideFlags: 0 diff --git a/TODO.txt b/TODO.txt index dac6d7a..c9e570f 100644 --- a/TODO.txt +++ b/TODO.txt @@ -1,5 +1,6 @@ - Animate rearrange hand after card is used - Make hero cards be used in sequence Coroutines, not in parallel - Do not Highlight unusable cards -- Dim unusable cards +- Show which cards enemies will use +- Show on who enemies will use the cards - Extend BattleState to be more than hero turn true/false \ No newline at end of file