diff --git a/ColorlessWorld-2024-4-2/Assets/GameDate/RelicList.asset b/ColorlessWorld-2024-4-2/Assets/GameDate/RelicList.asset index e353e6d4..0f9e3915 100644 --- a/ColorlessWorld-2024-4-2/Assets/GameDate/RelicList.asset +++ b/ColorlessWorld-2024-4-2/Assets/GameDate/RelicList.asset @@ -12,4 +12,5 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 904fb4225c416d84e891fac047459035, type: 3} m_Name: RelicList m_EditorClassIdentifier: - relicClassNameList: [] + relicClassNameList: + - LegacyNode_BigBackpack diff --git a/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset b/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset index 966737f9..d336211a 100644 --- a/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset +++ b/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset @@ -13,13 +13,9 @@ MonoBehaviour: m_Name: cardDeckList m_EditorClassIdentifier: cardDeckList: - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 - - 1006 + - 1017 + - 1017 + - 1017 + - 1017 + - 1017 + - 1017 diff --git a/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity b/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity index 4c16af41..de6af330 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity +++ b/ColorlessWorld-2024-4-2/Assets/Scenes/SampleScene.unity @@ -15515,6 +15515,7 @@ MonoBehaviour: whiteNodeCount: 0 blackNodeCount: 0 metalNodeCount: 0 + yellowNodeCount: 0 playerNodeCount: 0 neutralNodeCount: 0 enemyNodeCount: 0 @@ -41803,7 +41804,6 @@ MonoBehaviour: type: 3} legacyFather: {fileID: 1748859173} relicClassNameList: [] - legacyNodesList: [] --- !u!1 &1774587053 GameObject: m_ObjectHideFlags: 0 diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff.cs index b4c092ae..89766316 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff.cs @@ -9,14 +9,17 @@ public class Buff public int value; public Sprite icon; public string iconPath = "BuffIcon_v02/"; + public int count = 0; public virtual void Settle() { value --; + count= 0; } public virtual void SettleEnemy(EnemyNode enemyNode) { value--; + count = 0; } public virtual void SettleEnemyBegin(EnemyNode enemyNode) diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs new file mode 100644 index 00000000..18c4f55e --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs @@ -0,0 +1,27 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_Bleed3TurnCost : Buff +{ + + public override void Settle() + { + count = 0; + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + count = 0; + } + public override Buff NewBuff(int value) + { + Buff buff = new Buff_Bleed3TurnCost(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs.meta new file mode 100644 index 00000000..0d240959 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed3TurnCost.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 87021152033dd3d4c905bf3e6634b532 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs new file mode 100644 index 00000000..f91fd10a --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs @@ -0,0 +1,28 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_Bleed4TurnCost : Buff +{ + public override void Settle() + { + count = 0; + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + count = 0; + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_Bleed4TurnCost(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs.meta new file mode 100644 index 00000000..a5083577 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Bleed4TurnCost.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: cfbad4c429526724dbf97c5aa362ac9d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs new file mode 100644 index 00000000..202043cf --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs @@ -0,0 +1,30 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_BleedDamage : Buff +{ + public override void Settle() + { + + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + + + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_BleedDamage(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs.meta new file mode 100644 index 00000000..b3f706fc --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedDamage.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 91dfd91b0c739a94d98f01c6d1c20797 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs new file mode 100644 index 00000000..2efe7c5f --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs @@ -0,0 +1,30 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_BleedHeal : Buff +{ + public override void Settle() + { + + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + + + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_BleedHeal(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs.meta new file mode 100644 index 00000000..7e1c007c --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_BleedHeal.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 74356d9ae2e6b8d43ac7376113dd0ce8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs new file mode 100644 index 00000000..05be8763 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs @@ -0,0 +1,26 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_CantShield : Buff +{ + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + + + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_CantShield(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs.meta new file mode 100644 index 00000000..5b061c62 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantShield.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8e55cb544c976bf469ae9f5b5364db7a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs new file mode 100644 index 00000000..002ef720 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_CantUserEffectCaed : Buff +{ + public override void Settle() + { + value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_CantUserEffectCaed(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs.meta new file mode 100644 index 00000000..eee9a54f --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_CantUserEffectCaed.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 9276906ae80f6ed479f35ff7fc93b1d4 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs new file mode 100644 index 00000000..582ed6f4 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs @@ -0,0 +1,30 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_DeathMark : Buff +{ + public override void Settle() + { + base.Settle(); + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + + base.Settle(); + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_DeathMark(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "downSpeed"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs.meta new file mode 100644 index 00000000..208948c6 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DeathMark.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 0f08d5c214bfb424fad4804da01ad7c5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs new file mode 100644 index 00000000..3c36def5 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs @@ -0,0 +1,30 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_Disable : Buff +{ + public override void Settle() + { + base.Settle(); + } + + + + public override void SettleEnemy(EnemyNode enemyNode) + { + + base.Settle(); + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_Disable(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "downSpeed"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs.meta new file mode 100644 index 00000000..2d6bcfbf --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_Disable.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 230c71876e5a24d4a80cd6426f787df5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs new file mode 100644 index 00000000..db64c809 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_DyeingCardCostMinusOne : Buff +{ + public override void Settle() + { + value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_DyeingCardCostMinusOne(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs.meta new file mode 100644 index 00000000..72bec3c6 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_DyeingCardCostMinusOne.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 05c4f66402c303a449ef37e1bad6ba3f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs new file mode 100644 index 00000000..33ad2bcb --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs @@ -0,0 +1,25 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_EmberDownOneTurn : Buff +{ + public override void Settle() + { + value=0; + } + + public override void SettleEnemy(EnemyNode enemyNode) + { + value = 0; + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_EmberDownOneTurn(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_nuhuo1_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs.meta new file mode 100644 index 00000000..ea9cff0e --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_EmberDownOneTurn.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7f07683220b4e6a419116fcf83af040f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs new file mode 100644 index 00000000..6d5284f9 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_NextCardCostHp : Buff +{ + public override void Settle() + { + value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_NextCardCostHp(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs.meta new file mode 100644 index 00000000..41de9500 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostHp.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1155e91d9a4d7f644943511072a0f9eb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs new file mode 100644 index 00000000..413d96fc --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_NextCardCostMinusOne : Buff +{ + public override void Settle() + { + value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_NextCardCostMinusOne(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs.meta new file mode 100644 index 00000000..1c2d5c3d --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextCardCostMinusOne.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: bc6c039d1d5ebaf4d81fa8c9a0159602 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs new file mode 100644 index 00000000..6bf0ac08 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_NextDyeingCardCostZero : Buff +{ + public override void Settle() + { + //value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_NextDyeingCardCostZero(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs.meta new file mode 100644 index 00000000..56c38e65 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardCostZero.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 09f8fcaca70d78544ade8ccb503a8c61 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs new file mode 100644 index 00000000..7ce551cb --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_NextDyeingCardRangeAddTwo : Buff +{ + public override void Settle() + { + value = 0; + + } + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_NextDyeingCardRangeAddTwo(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_liuxue_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs.meta new file mode 100644 index 00000000..5759b73a --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextDyeingCardRangeAddTwo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e9ce019f8ded4f548bcf23ebf202bc20 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs new file mode 100644 index 00000000..3c1f3d89 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs @@ -0,0 +1,22 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class Buff_NextEffectCardDoubleSettle : Buff +{ + public override void Settle() + { + value = 0; + + } + + + public override Buff NewBuff(int value) + { + Buff buff = new Buff_NextEffectCardDoubleSettle(); + buff.value = value; + buff.icon = BuffDataManager.Instance.LoadImage(iconPath + "Sslx_Ui_Buff_maozixifa_v01"); + return buff; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs.meta new file mode 100644 index 00000000..fa400258 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Buff/Buff_NextEffectCardDoubleSettle.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: bcc5d5190b465b9418756386128298a3 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs index 0e30fac9..cd25f55f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardDrag.cs @@ -261,7 +261,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag //检查卡牌的费用是否可以释放 private void costCheck() { - switch (cardEntity.cardOriginalData.costType) + switch (cardEntity.currentCostType) { case Name.CostType.energy: energyCostCheck(); @@ -274,15 +274,17 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag break; case Name.CostType.node: break; - - + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.cantUserEffectCaed) && cardEntity.cardOriginalData.CardType.Equals(Name.CardType.effect)) + { + cardEntity.canUse = false; } } private void energyCostCheck() { - int trueCost = cardEntity.cardOriginalData.Cost; + int trueCost = cardEntity.currentCost; if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Black)) { trueCost++; @@ -495,16 +497,8 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag currentNode = raycastHit.collider.transform.GetComponent(); //重新调用范围预览 //GameManager.Instance.player.StepPreviewInfluencedNode(cardEntity.cardOriginalData.CastingRange); - int castRange = GameManager.Instance.playerState.castRange; - if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Green)) - { - castRange++; - } - if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.tempCastRange)) - { - castRange+= Usermanager.playerAbnormalCondition[AbnormalCondition.tempCastRange].value; - } - setCastingRangePreview(castRange); + + setCastingRangePreview(); //预览影响范围 if (currentNode.influenced) { @@ -519,7 +513,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag //更新涂色预览材质 // SettlementManager.Instance.PreviewSwitchColor(cardEntity.cardOriginalData, currentNode); //更新地块计数 - SettlementManager.Instance.PreviewColorMapUnity(cardEntity.cardOriginalData, currentNode); + //SettlementManager.Instance.PreviewColorMapUnity(cardEntity.cardOriginalData, currentNode); } //更新效果作用范围内怪物虚血 @@ -530,14 +524,43 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag } - private void setCastingRangePreview(int castRange) + private void setCastingRangePreview() { + int castRange = GameManager.Instance.playerState.castRange; + if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Green)) + { + castRange++; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.tempCastRange)) + { + castRange += Usermanager.playerAbnormalCondition[AbnormalCondition.tempCastRange].value; + } + if (cardEntity.cardOriginalData.TrueFunctionVal.ContainsKey(CardFunction.castRangePlusOne)) + { + castRange += 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextDyeingCardRangeAddTwo)&&cardEntity.cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + castRange += 2; + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_Bipod)) + { + castRange += 4; + } foreach (MapUnity mapUnity in MapUnityManager.Instance.castPool) { mapUnity.influenced = false; } MapUnityManager.Instance.castPool.Clear(); - MapUnityManager.Instance.getCastPool(castRange); + if (cardEntity.cardOriginalData.TrueFunctionVal.ContainsKey(CardFunction.infCastRange)) + { + MapUnityManager.Instance.getCastPoolForInfRange(); + } + else + { + MapUnityManager.Instance.getCastPool(castRange); + } + } @@ -571,7 +594,7 @@ public class CardDrag : MonoBehaviour, IBeginDragHandler, IDragHandler, IEndDrag //更新效果作用范围内怪物虚血 EnemyManager.Instance.ShowExpHp_Observer(cardEntity.influencePreviewPool); //更新涂色材质和地块数量统计预览 - SettlementManager.Instance.PreviewColorMapUnity(cardEntity.cardOriginalData, GameManager .Instance .playerOn ); + //SettlementManager.Instance.PreviewColorMapUnity(cardEntity.cardOriginalData, GameManager .Instance .playerOn ); } public void OnDrag(PointerEventData eventData) diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs index 2252af20..6701da35 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardEntity.cs @@ -97,10 +97,10 @@ public class CardEntity : MonoBehaviour public Animator animator; [Header("卡牌边框画器控件")] public Animator borderAnim; - public Dictionary> cardFunToLose = new Dictionary>(); [Header("卡牌费用变化监测")] int lastCost; public int currentCost; + public string currentCostType; private void Start() { currentCost = cardOriginalData.Cost; @@ -171,7 +171,7 @@ public class CardEntity : MonoBehaviour //Debug.Log(cardId + "-" + CardOriginalDataList.Instance.cardOriginalDataList[cardId]); cardOriginalData = CardOriginalDataList.Instance.existCardOriginalDataList[cardId]; settleForStart(SettlementManager.settleTurn); - createCardUI(needTrueFun); + //createCardUI(needTrueFun); //createCardDescription(); createCardName(); //createCardCost(); @@ -362,7 +362,7 @@ public class CardEntity : MonoBehaviour public void createCardImageTest() { - MapUnity currentNode = CardPictureManager.Instance.ToolX[3].Y[3]; + MapUnity currentNode = CardPictureManager.Instance.ToolX[4].Y[4]; Debug.Log("card创建"); CardManager.setCardImageTest(cardOriginalData, 90.0f, currentNode,this); } @@ -380,19 +380,9 @@ public class CardEntity : MonoBehaviour } else {*/ - currentCost = cardOriginalData.Cost; - if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Black)) - { - currentCost += 1; - cost.text = currentCost.ToString(); - - } - else - { - cost.text = currentCost.ToString(); - } - - if(currentCost!=lastCost ) + (currentCost, currentCostType)=CardResourcesManager.Instance.getCardCost(cardOriginalData); + cost.text = currentCost.ToString(); + if (currentCost!=lastCost ) { lastCost = currentCost; CheckUse(); @@ -589,11 +579,11 @@ public class CardEntity : MonoBehaviour //Debug.Log("cardId是" + cardOriginalData.CardId + "功能是" + cardOriginalData.TrueFunctionVal.ElementAt(i).Key + "数值是" + cardOriginalData.TrueFunctionVal.ElementAt(i).Value); //Debug.Log("originFunctionVal的key是"+ fun); //Debug.Log("originFunctionVal的value是" + cardOriginalData.originFunctionVal.ElementAt(i).Value); - if (cardOriginalData.testTrueFunctionVal.Keys.Contains(fun)) + if (cardOriginalData.TrueFunctionVal.Keys.Contains(fun)) { keyChild.SetActive(true); valueChild.SetActive(true); - description.text = cardOriginalData.testTrueFunctionVal[fun]; + description.text = cardOriginalData.TrueFunctionVal[fun]; } else @@ -781,11 +771,37 @@ public class CardEntity : MonoBehaviour private void checkAndUpdateCondition() { -/* if (cardOriginalData.CardType != Name.CardType.dyeing) + /* if (cardOriginalData.CardType != Name.CardType.dyeing) + { + return; + }*/ + if (cardOriginalData.TrueFunctionVal != null) { - return; - }*/ - cardOriginalData.testTrueFunctionVal.Clear(); + cardOriginalData.TrueFunctionVal.Clear(); + } + foreach (KeyValuePair kvp in cardOriginalData.commonFunctionVal) + { + if (int.TryParse(kvp.Value, out int newValue)) + { + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, kvp.Key, kvp.Value); + } + else + { + if (Name.Color.AllColor.Contains(kvp.Value)) + { + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, kvp.Key, getNodeTools.getNodesCount(kvp.Value).ToString()); + } + else + { + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, kvp.Key, kvp.Value); + } + + } + } + + List allMatchList = new List(); + int exclusiveConditionIndex = 0; + bool canexclusiveCondition=false; for (int i = 0; i < cardOriginalData.conditionAndFunctionVal.Count; i++) { bool isAllMatch=true; @@ -817,69 +833,44 @@ public class CardEntity : MonoBehaviour } } Image condition = conditionList[i].GetComponent(); + allMatchList.Add(isAllMatch); if (isAllMatch) { - string[] fun = kvp.Value.Item1.Split("_"); - string[] vals = kvp.Value.Item2.Split("_"); - for (int j = 0; j < fun.Length; j++) - { - if (int.TryParse(vals[j], out int newValue)) - { - MathTool.AddOrUpdateDictionary(cardOriginalData.testTrueFunctionVal, fun[j], vals[j]); - } - else - { - MathTool.AddOrUpdateDictionary(cardOriginalData.testTrueFunctionVal, fun[j], getNodeTools.getNodesCount(vals[j]).ToString()); - } - } - string value = kvp.Value.Item2; - - + exclusiveConditionIndex = i; + canexclusiveCondition=true; condition.sprite = successCondition; - cardFunToLose.Remove( kvp.Key); } else { condition.sprite = unsuccessCondition; - cardFunToLose.TryAdd(kvp.Key, kvp.Value); } } - - /*cardOriginalData.TrueFunctionVal = cardOriginalData.originFunctionVal.ToDictionary(entry => entry.Key, entry => entry.Value); - Dictionary cardFunToLoseDict=new Dictionary(); - foreach (var kvp in cardFunToLose) + string[] fun = cardOriginalData.conditionAndFunctionVal.ElementAt(exclusiveConditionIndex).Value.Item1.Split("_"); + string[] vals = cardOriginalData.conditionAndFunctionVal.ElementAt(exclusiveConditionIndex).Value.Item2.Split("_"); + if (canexclusiveCondition) { - string[] fun=kvp.Value.Item1.Split("_"); - string[] vals = kvp.Value.Item2.Split("_"); for (int j = 0; j < fun.Length; j++) { - MathTool.AddOrUpdateDictionary(cardFunToLoseDict, fun[j], vals[j]); - } - - } - foreach (var kvp in cardFunToLoseDict) - { - string tupleKey = kvp.Key; // 从 A 中的 Tuple 获取 Item1 作为 B 的键 - string tupleValue = kvp.Value; // 从 A 中的 Tuple 获取 Item2 作为减数 - if (cardOriginalData.TrueFunctionVal.ContainsKey(tupleKey)) - { - // 解析字典 B 的值和 A 中 Tuple 的 Item2 - if (int.TryParse(cardOriginalData.TrueFunctionVal[tupleKey], out int bValue) && - int.TryParse(tupleValue, out int aValue2)) + if (int.TryParse(vals[j], out int newValue)) { - // 计算新的值,字典 B 中的值减去 A 中 Tuple 中的 Item2 值 - int newValue = bValue - aValue2; - - // 更新字典 C 中的值 - cardOriginalData.TrueFunctionVal[tupleKey] = newValue.ToString(); + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, fun[j], vals[j]); } else { - Console.WriteLine($"键 '{tupleKey}' 的值不是有效的整数,无法更新。"); + if (Name.Color.AllColor.Contains(vals[j])) + { + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, fun[j], getNodeTools.getNodesCount(vals[j]).ToString()); + } + else + { + MathTool.AddOrUpdateDictionary(cardOriginalData.TrueFunctionVal, fun[j], vals[j]); + } } } - }*/ - resultsScreenCal(cardDataSummary); + } + + + //resultsScreenCal(cardDataSummary); } private void createCardRelease() { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalData.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalData.cs index b78fde10..b6f97d5a 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalData.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalData.cs @@ -20,12 +20,14 @@ public class CardOriginalData : System.Object private int castingRange; private string effectRange; - + //一次性 private int isDisposable; private Dictionary trueFunctionVal; - public Dictionary testTrueFunctionVal; + public Dictionary showFunctionVal; + + public Dictionary commonFunctionVal; private string cardType; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalDataList.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalDataList.cs index 267a5fd7..0a32665f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalDataList.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardOriginalDataList.cs @@ -28,7 +28,7 @@ public class CardOriginalDataList : Singleton private void OnEnable() { - cardOriginalDataList = ReadExcelForDyeingCard("card_data_4.csv"); + cardOriginalDataList = ReadExcelForDyeingCard("card_data_5.csv"); effectCardOriginalDataList = ReadExcelForEffectCard("card_data_effect_4.csv"); itemCardOriginalDataList = ReadExcelForItemCard("card_data_item_4.csv"); //categorizeCardsByRarity(); @@ -210,7 +210,8 @@ public class CardOriginalDataList : Singleton //cardOriginalData.ChineseName = values[1]; cardOriginalData.costType = values[1]; cardOriginalData.Cost = int.Parse(values[2]); - //cardOriginalData.Rarity = int.Parse(values[3]); + cardOriginalData.Rarity = int.Parse(values[12]); + cardOriginalData.ChineseName = values[11]; cardOriginalData.CastingRange = int.Parse(values[3]); cardOriginalData.EffectRange = values[4]; //cardOriginalData.IsDisposable = int.Parse(values[6]) == 1; @@ -218,8 +219,8 @@ public class CardOriginalDataList : Singleton cardOriginalData.nodesColor = values[9].Split(";"); cardOriginalData.conditionAndFunctionVal = new Dictionary>(); cardOriginalData.TrueFunctionVal = new Dictionary(); - cardOriginalData.testTrueFunctionVal = new Dictionary(); cardOriginalData.originFunctionVal = new HashSet(); + cardOriginalData.commonFunctionVal = new Dictionary(); cardOriginalData.CardType = Name.CardType.dyeing; cardOriginalData.ImgPath = values[10]; for (int i = 0; i < cardOriginalData.nodesMark.Length; i++) @@ -246,43 +247,44 @@ public class CardOriginalDataList : Singleton cardOriginalData.cardImageMark = new HashSet(); //CardOriginalData cardOriginalData = CardOriginalData.Instance; cardOriginalData.CardId = values[0]; - //cardOriginalData.ChineseName = values[1]; + cardOriginalData.ChineseName = values[13]; cardOriginalData.costType = values[1]; cardOriginalData.Cost = int.Parse(values[2]); - //cardOriginalData.Rarity = int.Parse(values[3]); - cardOriginalData.CastingRange = int.Parse(values[8]); + cardOriginalData.Rarity = int.Parse(values[11]); //cardOriginalData.EffectRange = values[3]; - //cardOriginalData.IsDisposable = int.Parse(values[6]) == 1; - cardOriginalData.nodesMark = values[6].Split(";"); + cardOriginalData.IsDisposable = int.Parse(values[12]) == 1; + cardOriginalData.nodesMark = values[8].Split(";"); //cardOriginalData.nodesColor = values[8].Split(";"); cardOriginalData.conditionAndFunctionVal = new Dictionary>(); + cardOriginalData.commonFunctionVal = new Dictionary(); cardOriginalData.TrueFunctionVal = new Dictionary(); - cardOriginalData.testTrueFunctionVal = new Dictionary(); cardOriginalData.originFunctionVal = new HashSet(); cardOriginalData.CardType = Name.CardType.effect; - cardOriginalData.ImgPath = values[7]; - cardOriginalData.CastingRange = int.Parse(values[8]); - cardOriginalData.TrueFunctionVal = new Dictionary(); + cardOriginalData.ImgPath = values[9]; + cardOriginalData.CastingRange = int.Parse(values[10]); cardOriginalData.originFunctionVal = new HashSet(); //cardOriginalData.testTrueFunctionVal = new Dictionary(); - string[] condition = values[3].Split(";"); - string[] function = values[4].Split(";"); - string[] functionVal = values[5].Split(";"); - /*string[] advantagefunction = values[9].Split(";"); - string[] advantagefunctionVal = values[10].Split(";");*/ - //cardOriginalData.FunctionVal = new Dictionary(); - //cardOriginalData.AdvantageFunctionVal = new Dictionary(); + string[] condition = values[5].Split(";"); + string[] function = values[6].Split(";"); + string[] functionVal = values[7].Split(";"); + string[] commonFunction = values[3].Split(";"); + string[] commonFunctionVal = values[4].Split(";"); for (int i = 0; i < function.Length; i++) { cardOriginalData.conditionAndFunctionVal.Add(condition[i], new Tuple(function[i], functionVal[i])); } - //getDictionaryFromString(values, cardOriginalData); - /* for (int i = 0; i < function.Length; i++) + for (int i = 0; i < commonFunction.Length; i++) { - cardOriginalData.originFunctionVal.Add(function[i]); - cardOriginalData.TrueFunctionVal.Add(function[i], functionVal[i]); - cardOriginalData.testTrueFunctionVal.Add(function[i], functionVal[i]); - }*/ + cardOriginalData.commonFunctionVal.Add(commonFunction[i],commonFunctionVal[i]); + //Debug.Log("TrueFunctionVal是" + commonFunction[i] + "+" + commonFunctionVal[i]); + } + //getDictionaryFromString(values, cardOriginalData); + /* for (int i = 0; i < function.Length; i++) + { + cardOriginalData.originFunctionVal.Add(function[i]); + cardOriginalData.TrueFunctionVal.Add(function[i], functionVal[i]); + cardOriginalData.testTrueFunctionVal.Add(function[i], functionVal[i]); + }*/ return cardOriginalData; } @@ -312,7 +314,7 @@ public class CardOriginalDataList : Singleton string[] functionVal = values[4].Split(";"); cardOriginalData.TrueFunctionVal = new Dictionary(); cardOriginalData.originFunctionVal = new HashSet(); - cardOriginalData.testTrueFunctionVal = new Dictionary(); + cardOriginalData.TrueFunctionVal = new Dictionary(); cardOriginalData.IsDisposable=true; //getDictionaryFromString(values, cardOriginalData); @@ -320,7 +322,6 @@ public class CardOriginalDataList : Singleton { cardOriginalData.originFunctionVal.Add(function[i]); cardOriginalData.TrueFunctionVal.Add(function[i], functionVal[i]); - cardOriginalData.testTrueFunctionVal.Add(function[i], functionVal[i]); } return cardOriginalData; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardPictureManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardPictureManager.cs index 5b141498..99b82363 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardPictureManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardPictureManager.cs @@ -30,7 +30,7 @@ public class CardPictureManager : Singleton yield return StartCoroutine(SetUpMapUnityForTool()); yield return StartCoroutine(SetUpMapUnityForCubeForTool()); createCameraAboveObject(ToolX[3].Y[3].gameObject, 10.0f, 0); - CardManager.createCardImageMap(); + //CardManager.createCardImageMap(); } IEnumerator MapGenerateTest() { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardResourcesManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardResourcesManager.cs index 91cd353e..601d0470 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardResourcesManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/CardResourcesManager.cs @@ -82,6 +82,96 @@ public class CardResourcesManager : Singleton return System.Text.RegularExpressions.Regex.IsMatch(input, @"^[><=]|\d+$"); } + public (int trueCost, string trueCostType) getCardCost(CardOriginalData cardOriginalData) + { + int cost = cardOriginalData.Cost; + string costType=cardOriginalData.costType.Substring(0); + if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Black)) + { + cost += 1; + } + if (cardOriginalData.TrueFunctionVal.ContainsKey(CardFunction.reduceCost)) + { + cost -= int.Parse(cardOriginalData.TrueFunctionVal[CardFunction.reduceCost]); + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextCardCostMinusOne)) + { + cost -= 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.dyeingCardCostMinusOne)&&cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost -= 1; + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_Prism) && cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost -= 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextCardCostHp)) + { + costType=Name.CostType.health; + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_FreeBullet) && cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost = 0; + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_SpeedLoader) && cardOriginalData.CardType.Equals(Name.CardType.effect)) + { + cost = 0; + LegacyManager.Instance.tryResetCount(Name.Legacy.LegacyNode_SpeedLoader); + } + MathTool.keepNature(ref cost); + return (cost, costType); + } + + public (int trueCost, string trueCostType) getCardCostForSettle(CardOriginalData cardOriginalData) + { + int cost = cardOriginalData.Cost; + string costType = cardOriginalData.costType.Substring(0); + if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Black)) + { + cost += 1; + } + if (cardOriginalData.TrueFunctionVal.ContainsKey(CardFunction.reduceCost)) + { + cost -= int.Parse(cardOriginalData.TrueFunctionVal[CardFunction.reduceCost]); + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextCardCostMinusOne)) + { + cost -= 1; + Usermanager.playerAbnormalCondition[AbnormalCondition.nextCardCostMinusOne].value -= 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.dyeingCardCostMinusOne) && cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost -= 1; + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_Prism) && cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost -=1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextCardCostHp)) + { + costType = Name.CostType.health; + Usermanager.playerAbnormalCondition[AbnormalCondition.nextCardCostHp].value -= 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextDyeingCardCostZero) && cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost = 0; + Usermanager.playerAbnormalCondition[AbnormalCondition.nextDyeingCardCostZero].value -= 1; + } + if(LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_FreeBullet)&& cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + cost = 0; + LegacyManager.Instance.tryResetCount(Name.Legacy.LegacyNode_FreeBullet); + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_SpeedLoader) && cardOriginalData.CardType.Equals(Name.CardType.effect)) + { + cost = 0; + LegacyManager.Instance.tryResetCount(Name.Legacy.LegacyNode_SpeedLoader); + } + Usermanager.Instance.AbnormalConditionEndCheck(); + MathTool.keepNature(ref cost); + return (cost, costType); + } public void getImage(GameObject input,string imageString) { Image image = input.GetComponent(); diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs index 6cb21184..17506637 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Card/TurnMaster.cs @@ -1,9 +1,13 @@ +using System; using System.Collections; using System.Collections.Generic; +using System.Text.RegularExpressions; using Unity.VisualScripting; using UnityEngine; using UnityEngine.Playables; using UnityEngine.UI; +using UnityEngine.Windows; +using static Name; public class TurnMaster : Singleton { @@ -83,7 +87,9 @@ public class TurnMaster : Singleton Usermanager.Instance.PlayerTurnBeginSettle(); //恢复cost restoreResource(settleTurn); - + //重置遗物计数 + ResetLegacy(); + //恢复体力 GameManager.Instance.playerState.currentStepRange = Usermanager.Instance.StepRangeCalculation(GameManager.Instance.playerState.maxStepRange); //判断是否有使魔进行结算 @@ -210,6 +216,11 @@ public class TurnMaster : Singleton { GameManager.Instance.servantState.currentStepRange = GameManager.Instance.servantState.maxStepRange; } + + public void ResetLegacy() + { + LegacyManager.Instance.tryResetCount(Name.Legacy.LegacyNode_LightningBoots); + } public void CloseSkillUI() { GameManager.Instance.servant .SkillUI.SetActive(false); @@ -248,10 +259,10 @@ public class TurnMaster : Singleton { /* totalCost = Usermanager.Instance.totalCost; Usermanager.Instance.currentCost = totalCost;*/ - if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_AncientSilverCoin) && - settleTurn == 0) + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_PerpetualMotionPump)) { - GameManager.Instance.playerState.currentCost = GameManager.Instance.playerState.maxCost+1; + int lastRoundCost = GameManager.Instance.playerState.currentCost; + GameManager.Instance.playerState.currentCost = GameManager.Instance.playerState.maxCost+ lastRoundCost; } else { @@ -299,7 +310,7 @@ public class TurnMaster : Singleton { tureDrawCardsNum-=2; }*/ - MathTool.keepNature(tureDrawCardsNum); + MathTool.keepNature(ref tureDrawCardsNum); Debug.Log("真正抽卡数:"+tureDrawCardsNum); // 等待直到当前帧结束 yield return new WaitForEndOfFrame(); @@ -426,6 +437,188 @@ public class TurnMaster : Singleton yield break; } + public IEnumerator drawAndCopyOneCard() + { + int drawNum = 1; + GameManager.Instance.onDraw = true; + + int handCardCount = handCard.cardEntityList.Count; + int actualCardsToDraw = Mathf.Min(handCard.maxHandCard - handCardCount, drawNum); + + CardActiveSort.Instance.drawCardCount = actualCardsToDraw; + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.SortOldCardPointWithDrawCards()); + Debug.Log("抽卡点1"); + for (int i = handCardCount; i < handCardCount + actualCardsToDraw; i++) + { + + if (cardDeck.cardList.Count > 0) + { + createCard(i); + } + else if (usedCard.usedCardList.Count > 0) + { + //洗牌继续抽 + for (int c = 0; c < usedCard.usedCardList.Count; c++) + { + cardDeck.cardList.Add(usedCard.usedCardList[c]); + cardDeck.cardList.Shuffle(); + } + usedCard.usedCardList.Clear(); + + createCard(i); + } + yield return new WaitForSeconds(0.1f); + } + + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.ReflashCardPointWithDrawCards()); + yield return StartCoroutine(copyNewestCard()); + yield break; + } + + public IEnumerator copyNewestCard() + { + + int handCardCount = handCard.cardEntityList.Count; + if (handCardCount == handCard.maxHandCard) + { + yield return null; + } + string cardId= handCard.cardEntityList[handCardCount-1].cardOriginalData.CardId; + copyCard(handCardCount + 1,cardId); + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.ReflashCardPointWithDrawCards()); + yield break; + } + + public IEnumerator drawDyeingCards(int drawNum) + { + int dyeingCardCount = 0; + List dyeingCardIndexList= new List(); + List dyeingCardList = new List(); + + for (int i = 0; i < cardDeck.cardList.Count; i++) + { + if (System.Text.RegularExpressions.Regex.IsMatch(cardDeck.cardList[i], Name.Regex.pattern1xxx)) + { + dyeingCardCount++; + dyeingCardIndexList.Add(i); + //dyeingCardList.Add(cardDeck.cardList[i]); + } + } + GameManager.Instance.onDraw = true; + int handCardCount = handCard.cardEntityList.Count; + int drawNumA = Mathf.Min(dyeingCardIndexList.Count, drawNum); + int actualCardsToDraw = Mathf.Min(handCard.maxHandCard - handCardCount, drawNumA); + if (actualCardsToDraw == 0) + { + yield break; + } + //重新排序抽卡列表 + dyeingCardIndexList.Sort((a, b) => b.CompareTo(a)); + int count = Math.Min(actualCardsToDraw, dyeingCardIndexList.Count); + for (int i = 0; i < count; i++) + { + int index = dyeingCardIndexList[i]; + if (index >= 0 && index < cardDeck.cardList.Count) + { + dyeingCardList.Add(cardDeck.cardList[index]); // 保存移除的元素 + cardDeck.cardList.RemoveAt(index); // 移除元素 + } + } + cardDeck.cardList.InsertRange(0, dyeingCardList); + CardActiveSort.Instance.drawCardCount = actualCardsToDraw; + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.SortOldCardPointWithDrawCards()); + Debug.Log("抽卡点1"); + for (int i = handCardCount; i < handCardCount + actualCardsToDraw; i++) + { + + if (cardDeck.cardList.Count > 0) + { + createCard(i); + } + else if (usedCard.usedCardList.Count > 0) + { + //洗牌继续抽 + for (int c = 0; c < usedCard.usedCardList.Count; c++) + { + cardDeck.cardList.Add(usedCard.usedCardList[c]); + cardDeck.cardList.Shuffle(); + } + usedCard.usedCardList.Clear(); + + createCard(i); + } + yield return new WaitForSeconds(0.1f); + } + + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.ReflashCardPointWithDrawCards()); + yield break; + } + + public IEnumerator drawEffectCards(int drawNum) + { + int effectCardCount = 0; + List effectCardIndexList = new List(); + List effectCardList = new List(); + + for (int i = 0; i < cardDeck.cardList.Count; i++) + { + if (System.Text.RegularExpressions.Regex.IsMatch(cardDeck.cardList[i], Name.Regex.pattern2xxx)) + { + effectCardCount++; + effectCardIndexList.Add(i); + //dyeingCardList.Add(cardDeck.cardList[i]); + } + } + GameManager.Instance.onDraw = true; + int handCardCount = handCard.cardEntityList.Count; + int drawNumA = Mathf.Min(effectCardIndexList.Count, drawNum); + int actualCardsToDraw = Mathf.Min(handCard.maxHandCard - handCardCount, drawNumA); + if (actualCardsToDraw == 0) + { + yield break; + } + //重新排序抽卡列表 + effectCardIndexList.Sort((a, b) => b.CompareTo(a)); + int count = Math.Min(actualCardsToDraw, effectCardIndexList.Count); + for (int i = 0; i < count; i++) + { + int index = effectCardIndexList[i]; + if (index >= 0 && index < cardDeck.cardList.Count) + { + effectCardList.Add(cardDeck.cardList[index]); // 保存移除的元素 + cardDeck.cardList.RemoveAt(index); // 移除元素 + } + } + cardDeck.cardList.InsertRange(0, effectCardList); + CardActiveSort.Instance.drawCardCount = actualCardsToDraw; + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.SortOldCardPointWithDrawCards()); + Debug.Log("抽卡点1"); + for (int i = handCardCount; i < handCardCount + actualCardsToDraw; i++) + { + + if (cardDeck.cardList.Count > 0) + { + createCard(i); + } + else if (usedCard.usedCardList.Count > 0) + { + //洗牌继续抽 + for (int c = 0; c < usedCard.usedCardList.Count; c++) + { + cardDeck.cardList.Add(usedCard.usedCardList[c]); + cardDeck.cardList.Shuffle(); + } + usedCard.usedCardList.Clear(); + + createCard(i); + } + yield return new WaitForSeconds(0.1f); + } + + yield return CardActiveSort.Instance.StartCoroutine(CardActiveSort.Instance.ReflashCardPointWithDrawCards()); + yield break; + } + public void createCard(int i) { GameObject cardPrefab; @@ -463,6 +656,43 @@ public class TurnMaster : Singleton cardSmall.SetDestinationWithDrawCard(CardActiveSort.Instance.newPointList[i]); } + public void copyCard(int i,string cardId) + { + GameObject cardPrefab; + cardPrefab = Instantiate(cardDeck.rareCardPrefab, handCard.cardPanle.transform); + //int cardRarity = CardOriginalDataList.Instance.cardOriginalDataList[cardDeck.cardList[cardDeck.cardList.Count - 1]].Rarity; + //cardPrefab = new GameObject(); + /*switch (cardRarity) + { + case Name.CardRarity.Legendary: + cardPrefab = Instantiate(cardDeck.legendaryCardPrefab, handCard.cardPanle.transform); + break; + case Name.CardRarity.Rare: + cardPrefab = Instantiate(cardDeck.rareCardPrefab, handCard.cardPanle.transform); + break; + case Name.CardRarity.Common: + cardPrefab = Instantiate(cardDeck.cardPrefabPuTong, handCard.cardPanle.transform); + break; + }*/ + /* if (cardRarity==Name.CardRarity.Legendary) + { + cardPrefab = Instantiate(cardDeck.legendaryCardPrefab, handCard.cardPanle.transform); + } + else + { + cardPrefab = Instantiate(cardDeck.cardPrefabPuTong, handCard.cardPanle.transform); + }*/ + + cardPrefab.GetComponent().localEulerAngles = new Vector3(0, 0, 0); + CardEntity cardEntity = cardPrefab.GetComponent(); + cardEntity.createCard(cardId, i, true); + cardDeck.cardList.RemoveAt(cardDeck.cardList.Count - 1); + handCard.cardEntityList.Add(cardEntity); + //添加卡牌移动脚本 + CardSmall cardSmall = cardPrefab.AddComponent(); + cardSmall.SetDestinationWithDrawCard(CardActiveSort.Instance.newPointList[i]); + } + public void createCardWithoutMove(int i) { GameObject cardPrefab; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Enemy.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Enemy.cs index de24a445..56f25706 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Enemy.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Enemy.cs @@ -127,7 +127,7 @@ public class Enemy : MonoBehaviour public IEnumerator moveOneStep(MapUnity nexMapUnity) { - enemyNode.bleedCal(); + //enemyNode.bleedCal(); MapUnity currentNode = getNodeTools.LocationToGetNode(enemyNode.positionX, enemyNode.positionY); MapUnity disNode = nexMapUnity; currentNode.blocked = false; @@ -180,7 +180,7 @@ public class Enemy : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs index 8fa8c712..8d3a08b6 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/EnemyNode.cs @@ -337,6 +337,10 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver { extraStep += EnemyState.abnormalCondition[AbnormalCondition.upSpeed].value; } + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.disable)) + { + extraStep -= 1; + } if (EnemyManager.Instance.isEnemyAlive(Name.EnemyName.SoulMaker) && MapUnityManager.Instance.enemyNodeCount > 12) { extraStep += 2; @@ -346,7 +350,7 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver stepMultiplie = 0f; } int trueStepRange=EnemyState.stepRange+extraStep; - MathTool.keepNature(trueStepRange); + MathTool.keepNature(ref trueStepRange); int result=(int)(trueStepRange * stepMultiplie); return result; } @@ -730,14 +734,6 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver //死亡时 public virtual void OnDeath() { - if (EnemyState.abnormalCondition.TryGetValue(AbnormalCondition.posion,out Buff posionbuff)&& - LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_SnakeGall)) - { - if (posionbuff.value > 10) - { - Usermanager.Instance.recoverHp(1); - } - } if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.boomAndPollute)) { boomAndPolluteCal(); @@ -746,6 +742,27 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver { boomCal(); } + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.deathMark)&& EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + deathMarkCal(); + } + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_BloodTax)) + { + Usermanager.Instance.SufferPlayerAbnormalCondition(AbnormalCondition.bleedDamage, 1); + } + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_Sneakers)) + { + if (LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_Sneakers].isUsed.Equals(false)) + { + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_Sneakers].isUsed = true; + GameManager.Instance.playerState.currentStepRange = GameManager.Instance.playerState.maxStepRange; + } + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_ActivatedCarbon)) + { + MapUnity currentNode = GameManager.Instance.X[positionX].Y[positionY]; + currentNode.canChange = false; + } if (bone != null) { var currentenemy = Instantiate(bone, this.transform.position, this.transform.rotation); @@ -820,6 +837,16 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver } } + public void deathMarkCal() + { + MapUnity currentNode = GameManager.Instance.X[positionX].Y[positionY]; + HashSet targetSet = new HashSet(); + targetSet.Add(currentNode); + getNodeTools.getCircleNodeForBoom(targetSet, 3); + int bleedCount= EnemyState.abnormalCondition[AbnormalCondition.bleed].value; + SettlementManager.Instance.abnormalConditionWork(AbnormalCondition.bleed, bleedCount, new List(targetSet)); + } + public void boomCal() { MapUnity currentNode = GameManager.Instance.X[positionX].Y[positionY]; @@ -1092,7 +1119,7 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver { thornCal(); } - bleedCal(); + bleedRealize(); int trueDamage = SufferDamageCalculation(damageVal); if (trueDamage > EnemyState.shieldValue) { @@ -1180,6 +1207,89 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver } } + public void bleedRealize() + { + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + int bleedDamage = 2; + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.bleedDamage)) + { + bleedDamage += Usermanager.playerAbnormalCondition[AbnormalCondition.bleedDamage].value; + } + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleedHeal)) + { + Usermanager.Instance.recoverHp(bleedDamage); + } + bleed4TurnCostCal(); + bleed3TurnCostCal(); + sufferTrueDamage(bleedDamage); + EnemyState.abnormalCondition[AbnormalCondition.bleed].value -= 1; + if (EnemyState.abnormalCondition[AbnormalCondition.bleed].value <= 0) + { + EnemyState.abnormalCondition.Remove(AbnormalCondition.bleed); + } + + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_MeatSaw)) + { + bleedRealizeForMeatSaw(); + } + } + + } + + public void bleedRealizeForMeatSaw() + { + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + int bleedDamage = 2; + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.bleedDamage)) + { + bleedDamage += Usermanager.playerAbnormalCondition[AbnormalCondition.bleedDamage].value; + } + if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleedHeal)) + { + Usermanager.Instance.recoverHp(bleedDamage); + } + bleed4TurnCostCal(); + bleed3TurnCostCal(); + sufferTrueDamage(bleedDamage); + EnemyState.abnormalCondition[AbnormalCondition.bleed].value -= 1; + if (EnemyState.abnormalCondition[AbnormalCondition.bleed].value <= 0) + { + EnemyState.abnormalCondition.Remove(AbnormalCondition.bleed); + } + } + + } + + private void bleed4TurnCostCal() + { + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.bleed4TurnCost)) + { + Usermanager.playerAbnormalCondition[AbnormalCondition.bleed4TurnCost].count += 1; + if (Usermanager.playerAbnormalCondition[AbnormalCondition.bleed4TurnCost].count == 4) + { + GameManager.Instance.playerState.currentCost += 1; + Usermanager.playerAbnormalCondition[AbnormalCondition.bleed4TurnCost].count = 0; + } + } + + } + + private void bleed3TurnCostCal() + { + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.bleed3TurnCost)) + { + Usermanager.playerAbnormalCondition[AbnormalCondition.bleed3TurnCost].count += 1; + if (Usermanager.playerAbnormalCondition[AbnormalCondition.bleed3TurnCost].count == 3) + { + GameManager.Instance.playerState.currentCost += 1; + Usermanager.playerAbnormalCondition[AbnormalCondition.bleed4TurnCost].count = 0; + } + } + + } + private void thornCal() { if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.thorn)) @@ -1515,19 +1625,7 @@ public class EnemyNode : MonoBehaviour,IEnemyObserver } } - public void bleedRealize(MapUnity node) - { - if (EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) - { - sufferDamage(2, false); - EnemyState.abnormalCondition[AbnormalCondition.bleed].value -= 1; - if (EnemyState.abnormalCondition[AbnormalCondition.bleed].value <= 0) - { - EnemyState.abnormalCondition.Remove(AbnormalCondition.bleed); - } - } - - } + #endregion diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/AshBeetle.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/AshBeetle.cs index 178522b4..8db8cbfa 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/AshBeetle.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/AshBeetle.cs @@ -180,7 +180,7 @@ public class AshBeetle : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/BlastFistMushroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/BlastFistMushroom.cs index 47ebac05..7cea772e 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/BlastFistMushroom.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/BlastFistMushroom.cs @@ -186,7 +186,7 @@ public class BlastFistMushroom : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } @@ -207,7 +207,7 @@ public class BlastFistMushroom : MonoBehaviour public void AttackDamage() { int damage = GameManager.Instance.gerEnemytNodeCount(); - MathTool.keepNature(damage); + MathTool.keepNature(ref damage); Usermanager.Instance.SufferDamage(enemyNode.DamageCalculation(damage), enemyNode); } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/CorrosiveSludge.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/CorrosiveSludge.cs index a7c2275c..8669a953 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/CorrosiveSludge.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/CorrosiveSludge.cs @@ -208,7 +208,7 @@ public class CorrosiveSludge : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DarkCloud.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DarkCloud.cs index 720c40bd..1fb06e8e 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DarkCloud.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DarkCloud.cs @@ -317,7 +317,7 @@ public class DarkCloud : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DrowsyShroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DrowsyShroom.cs index 6cf7f86b..04797bbc 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DrowsyShroom.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/DrowsyShroom.cs @@ -188,7 +188,7 @@ public class DrowsyShroom : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/EmberWraith.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/EmberWraith.cs index 24fb6a46..5d94c5a8 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/EmberWraith.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/EmberWraith.cs @@ -204,7 +204,7 @@ public class EmberWraith : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Grinfiend.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Grinfiend.cs index 592433b7..83bfc399 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Grinfiend.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Grinfiend.cs @@ -326,7 +326,7 @@ public class Grinfiend : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/HoodWanderer.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/HoodWanderer.cs index 3d54ff57..a993ecf7 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/HoodWanderer.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/HoodWanderer.cs @@ -235,7 +235,7 @@ public class HoodWanderer : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Mushroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Mushroom.cs index 27c68a85..3ccb1202 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Mushroom.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Mushroom.cs @@ -393,7 +393,7 @@ public class Mushroom : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ParasiticMushroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ParasiticMushroom.cs index ed47400e..f7150843 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ParasiticMushroom.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ParasiticMushroom.cs @@ -239,7 +239,7 @@ public class ParasiticMushroom : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Polymaw.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Polymaw.cs index 8733865a..2b3cfe7f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Polymaw.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/Polymaw.cs @@ -331,7 +331,7 @@ public class Polymaw : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ShatteringFistMushroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ShatteringFistMushroom.cs index 12c00d52..2cf70c45 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ShatteringFistMushroom.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/ShatteringFistMushroom.cs @@ -243,7 +243,7 @@ public class ShatteringFistMushroom : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullGuardian.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullGuardian.cs index 7d0b49d9..1db7f610 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullGuardian.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullGuardian.cs @@ -202,7 +202,7 @@ public class SkullGuardian : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullMage.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullMage.cs index 692a7825..b58289ae 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullMage.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullMage.cs @@ -216,7 +216,7 @@ public class SkullMage : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullWarlock.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullWarlock.cs index f1b658d2..4742e8fb 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullWarlock.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/V0.1/SkullWarlock.cs @@ -206,7 +206,7 @@ public class SkullWarlock : MonoBehaviour //判断腐蚀 enemyNode.CorrodeRealize(endMapUnity); //判断流血 - enemyNode.bleedRealize(endMapUnity); + enemyNode.bleedRealize(); yield break; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild.meta index b6a8ff89..66a4c3b9 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild.meta +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: ae81639b55b115344ba483790eeab686 +guid: 281d6a379996cfb44962f57c0de81415 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs new file mode 100644 index 00000000..1cfbd7d0 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_ActivatedCarbon : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs.meta new file mode 100644 index 00000000..a28c082a --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ActivatedCarbon.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 0cc37f34a087db04490ed46f6fc2f981 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs new file mode 100644 index 00000000..999bc0c4 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs @@ -0,0 +1,29 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_AegisOfTheImmortal : LegacyNode +{ + public override void Use() + { + if (isUsed == false) + { + int recoverHpVal = (int)GameManager.Instance.playerState.maxHP / 10 * 3; + GameManager.Instance.playerState.currentHP=recoverHpVal; + isUsed = true; + } + + } + + public override bool IsUseful() + { + if (isUsed == false) + { + return true; + } + else + { + return false; + } + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs.meta new file mode 100644 index 00000000..7486d37d --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AegisOfTheImmortal.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7086a35f318e6bf448553227273a6943 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs new file mode 100644 index 00000000..82c3795e --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_BigBackpack : LegacyNode +{ + public override void Use() + { + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(3); + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs.meta new file mode 100644 index 00000000..4742e9fa --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BigBackpack.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 450ef84430f74dd4bbac3bc20c7c1e5a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs new file mode 100644 index 00000000..c98c286f --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs @@ -0,0 +1,30 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_Bipod : LegacyNode +{ + public bool lastRoundTrigger=true; + public bool thisRoundTrigger = false; + + public override bool IsUseful() + { + bool result = false; + if (lastRoundTrigger) + { + result = true; + } + return result; + } + + public override void EffectInPlayerTurnEnd() + { + lastRoundTrigger = thisRoundTrigger; + thisRoundTrigger=false; + } + + public override void ResetCount() + { + thisRoundTrigger=true; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs.meta new file mode 100644 index 00000000..339cc6bf --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Bipod.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e985a48b718f0d047848b5ce0a87c743 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs new file mode 100644 index 00000000..c0ab2642 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs @@ -0,0 +1,18 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_BloodBorne : LegacyNode +{ + // Start is called before the first frame update + void Start() + { + + } + + // Update is called once per frame + void Update() + { + + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs.meta new file mode 100644 index 00000000..5ca0630b --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodBorne.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f9dfde8ffd59d6645982ec82f20b043f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs new file mode 100644 index 00000000..5aca23d7 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_BloodTax : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs.meta new file mode 100644 index 00000000..273bcdf0 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_BloodTax.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8d4cac3a6694a174ca2b722f6ec2a93f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs new file mode 100644 index 00000000..aa00af95 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs @@ -0,0 +1,27 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_ChaosTrigger : LegacyNode +{ + public bool yellowTrigger=false; + public bool redTrigger = false; + public bool blueTrigger = false; + + public override bool IsUseful() + { + bool result=false; + if (yellowTrigger&& redTrigger&& blueTrigger) + { + result=true; + } + return result; + } + + public override void EffectInPlayerTurnEnd() + { + yellowTrigger = false; + blueTrigger = false; + redTrigger = false; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs.meta new file mode 100644 index 00000000..137facb6 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_ChaosTrigger.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c82f0b01863a17f42b7f2129b2ed44eb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs new file mode 100644 index 00000000..4694f569 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs @@ -0,0 +1,12 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_Cheese : LegacyNode +{ + public override void OnGet() + { + int recoverHpVal = 30; + Usermanager.Instance.recoverHp(recoverHpVal); + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs.meta new file mode 100644 index 00000000..2e98e3d9 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Cheese.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 44f70195fc587904baaae09745f23ddd +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs new file mode 100644 index 00000000..18b3b6a1 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_Filter : LegacyNode +{ + + + + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs.meta new file mode 100644 index 00000000..63837efa --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Filter.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5b63c67010446d24ab8cbcfc5f29f98d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs new file mode 100644 index 00000000..884054a9 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs @@ -0,0 +1,17 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_FreeBullet : LegacyNode +{ + + public override bool IsUseful() + { + bool result=false; + if (count == 4) + { + result=true; + } + return result; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs.meta new file mode 100644 index 00000000..221e6db5 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_FreeBullet.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1d501d5fe5fd5fc45ab49b81e264b455 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs new file mode 100644 index 00000000..e8459bd2 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs @@ -0,0 +1,24 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_LightningBoots : LegacyNode +{ + + public override bool IsUseful() + { + bool result = false; + if (count == 3) + { + result = true; + } + return result; + + } + + public override void Use() + { + GameManager.Instance.playerState.currentStepRange += 2; + ResetCount(); + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs.meta new file mode 100644 index 00000000..46b7f5db --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LightningBoots.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: cd26e3e64f3217644b98784901afe3fc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs new file mode 100644 index 00000000..bb569182 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_MeatSaw : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs.meta new file mode 100644 index 00000000..ff37ea19 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MeatSaw.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f650d7c780239c34c823efc783c917d0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs new file mode 100644 index 00000000..b3429435 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs @@ -0,0 +1,15 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_NurturingBloom: LegacyNode +{ + public override void EffectInPlayerTurnEnd() + { + if (GameManager.Instance.playerOn.whoColour == Name.NodeColor.Black) + { + Usermanager.Instance.SufferPlayerAbnormalCondition(AbnormalCondition.angerUpperDamage, 2); + Usermanager.Instance.lostHp(5); + } + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs.meta new file mode 100644 index 00000000..266b21bd --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_NurturingBloom.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7b8e9769b94e28442a9bc5680300c9f6 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PainContract.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PainContract.cs new file mode 100644 index 00000000..f78ec43e --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PainContract.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_PainContract : LegacyNode +{ + public override void EffectInPlayerTurnBegin() + { + Usermanager.Instance.lostHp(2); + List colorList = MathTool.GenerateRandomPlayerColorList(6); + MapUnity playerNode = GameManager.Instance.playerOn; + HashSet targetSet=new HashSet { playerNode }; + getNodeTools.getCircleNodeExceptSelf(targetSet,1); + List< MapUnity> targetList = new List(targetSet); + for (int i=0; i 9) + { + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(7); + } + + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Parasol.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Parasol.cs.meta new file mode 100644 index 00000000..26a625e2 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Parasol.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d5b288d7194006c4c93a0199ea52068e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs new file mode 100644 index 00000000..4e3c442a --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_PerpetualMotionPump : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs.meta new file mode 100644 index 00000000..fb0997b1 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PerpetualMotionPump.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e3b8b5ca83486ff4b95bd3f19cf0d24e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs new file mode 100644 index 00000000..9e9b80a9 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_PlatedSteelcaps : LegacyNode +{ + public override void Use() + { + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(3); + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs.meta new file mode 100644 index 00000000..8ab7a7f5 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PlatedSteelcaps.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 15720e4841ccf084aa2be96f1885ab52 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs new file mode 100644 index 00000000..5d5d027f --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_PortableReactor : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs.meta new file mode 100644 index 00000000..e2677276 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PortableReactor.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 47d9a0b02a09e7f47b7394b1efa3c3e5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs new file mode 100644 index 00000000..1b4af9c3 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs @@ -0,0 +1,17 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_Prism : LegacyNode +{ + public override bool IsUseful() + { + bool result=false; + if(MapUnityManager.Instance.yellowNodeCount!=0&& MapUnityManager.Instance.redNodeCount != 0&& MapUnityManager.Instance.blueNodeCount != 0) + { + result=true; + } + + return result; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs.meta new file mode 100644 index 00000000..7e2202e0 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Prism.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6b6bbcbf82f0ba14cb488396d88d77df +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs new file mode 100644 index 00000000..b8598600 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs @@ -0,0 +1,8 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_PurityBadge : LegacyNode +{ + +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs.meta new file mode 100644 index 00000000..4ca4c0ad --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_PurityBadge.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b7086655735c4ab4b91bc077d65e2118 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs new file mode 100644 index 00000000..55f594e4 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_Sneakers : LegacyNode +{ + public override void EffectInPlayerTurnBegin() + { + isUsed = false; + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs.meta new file mode 100644 index 00000000..eeafb6c4 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Sneakers.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7a1dda8190b57aa488026d258bb5c90a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs new file mode 100644 index 00000000..979d93ed --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs @@ -0,0 +1,18 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_SpeedLoader : LegacyNode +{ + + public override bool IsUseful() + { + bool result = false; + if (count == 9) + { + result = true; + } + return result; + + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs.meta new file mode 100644 index 00000000..b520c1a7 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SpeedLoader.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3eb4e618511b3cf4690c792d550f88aa +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs new file mode 100644 index 00000000..fa5078a3 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs @@ -0,0 +1,18 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LegacyNode_WasteReconstructor : LegacyNode +{ + // Start is called before the first frame update + void Start() + { + + } + + // Update is called once per frame + void Update() + { + + } +} diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs.meta new file mode 100644 index 00000000..36fb1e48 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_WasteReconstructor.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5ca2f000cceeaed40a945cbcdbb775c7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld.meta new file mode 100644 index 00000000..b6a8ff89 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ae81639b55b115344ba483790eeab686 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AgnisTorch.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AgnisTorch.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AgnisTorch.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AgnisTorch.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AgnisTorch.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AgnisTorch.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AgnisTorch.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AgnisTorch.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AncientSilverCoin.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AncientSilverCoin.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AncientSilverCoin.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AncientSilverCoin.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AncientSilverCoin.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AncientSilverCoin.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_AncientSilverCoin.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_AncientSilverCoin.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_EnchantedConch.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_EnchantedConch.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_EnchantedConch.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_EnchantedConch.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_EnchantedConch.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_EnchantedConch.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_EnchantedConch.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_EnchantedConch.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_GoldVines.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_GoldVines.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_GoldVines.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_GoldVines.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_GoldVines.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_GoldVines.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_GoldVines.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_GoldVines.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LavaHeart.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_LavaHeart.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LavaHeart.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_LavaHeart.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LavaHeart.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_LavaHeart.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_LavaHeart.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_LavaHeart.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MechanicalBoots.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_MechanicalBoots.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MechanicalBoots.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_MechanicalBoots.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MechanicalBoots.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_MechanicalBoots.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_MechanicalBoots.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_MechanicalBoots.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Scope.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Scope.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Scope.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Scope.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Scope.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Scope.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Scope.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Scope.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SnakeGall.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SnakeGall.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SnakeGall.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SnakeGall.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SnakeGall.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SnakeGall.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SnakeGall.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SnakeGall.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Starfish.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Starfish.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Starfish.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Starfish.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Starfish.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Starfish.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_Starfish.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_Starfish.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_StrongBody.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_StrongBody.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_StrongBody.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_StrongBody.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_StrongBody.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_StrongBody.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_StrongBody.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_StrongBody.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SuspiciousMushroom.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SuspiciousMushroom.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SuspiciousMushroom.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SuspiciousMushroom.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SuspiciousMushroom.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SuspiciousMushroom.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_SuspiciousMushroom.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_SuspiciousMushroom.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_VulcanHammer.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_VulcanHammer.cs similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_VulcanHammer.cs rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_VulcanHammer.cs diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_VulcanHammer.cs.meta b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_VulcanHammer.cs.meta similarity index 100% rename from ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChild/LegacyNode_VulcanHammer.cs.meta rename to ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyChildOld/LegacyNode_VulcanHammer.cs.meta diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyManager.cs index 32f91886..b7e627c1 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyManager.cs @@ -31,7 +31,7 @@ public class LegacyManager : Singleton public List relicClassNameList = new List(); [Header("已持有的遗物类列表")] - public List legacyNodesList = new List(); + public Dictionary legacyNodesList = new Dictionary(); private void OnEnable() { @@ -45,6 +45,43 @@ public class LegacyManager : Singleton // CreateLegacyClassAsNew("LegacyNode_StrongBody"); } + + public void tryUseLegacy(string legacyName) + { + if (LegacyManager.Instance.relicClassNameList.Contains(legacyName)) + { + LegacyManager.Instance.legacyNodesList[legacyName].Use(); + } + } + + public void tryAddCount(string legacyName,int i) + { + if (LegacyManager.Instance.relicClassNameList.Contains(legacyName)) + { + LegacyManager.Instance.legacyNodesList[legacyName].AddCount(i); + } + } + + public void tryResetCount(string legacyName) + { + if (LegacyManager.Instance.relicClassNameList.Contains(legacyName)) + { + LegacyManager.Instance.legacyNodesList[legacyName].ResetCount(); + } + } + + public bool isUseful(string legacyName) + { + bool result = false; + if (LegacyManager.Instance.relicClassNameList.Contains(legacyName)) + { + if (LegacyManager.Instance.legacyNodesList[legacyName].IsUseful()) + { + result = true; + } + } + return result; + } public void CreateLegacyClassAsNew(string className) { var lefacyObject = Instantiate(legacyPrefab, legacyFather.transform); @@ -117,9 +154,25 @@ public class LegacyManager : Singleton public void ReadRelicExcel(string fileName) { string filePath = Path.Combine(Application.streamingAssetsPath, fileName); - string[] lines = File.ReadAllLines(filePath); + //string[] lines = File.ReadAllLines(filePath); + using (FileStream fs = new FileStream(filePath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite)) + using (StreamReader reader = new StreamReader(fs)) + { + while (!reader.EndOfStream) + { + string line = reader.ReadLine(); + // 用逗号分隔每行数据 + string[] values = line.Split(','); + List currentRelictData = new List(); + foreach (string value in values) + { + currentRelictData.Add(value); + } + relicsDictionary.Add(values[1], currentRelictData); + } + } - for (int i = 0; i < lines.Length; i++) + /* for (int i = 0; i < lines.Length; i++) { string[] values = lines[i].Split(','); List currentRelictData = new List(); @@ -128,7 +181,7 @@ public class LegacyManager : Singleton currentRelictData.Add(value); } relicsDictionary.Add(values[1], currentRelictData); - } + }*/ } //玩家回合开始 diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyNode.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyNode.cs index fd36f006..e9bd4f79 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyNode.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Legacy/LegacyNode.cs @@ -10,16 +10,20 @@ public class LegacyNode : MonoBehaviour public string relicClassName; public string infor; public Sprite image; + public bool isUsed = false; + public int count = 0; + public bool isUseful = true; //构造函数 public virtual void CreateLegacy(string className,bool isOnGet) { - LegacyManager.Instance.legacyNodesList.Add(this); + List relicData = LegacyManager.Instance.relicsDictionary[className]; relicName = relicData[3]; relicClassName = relicData[1]; infor = relicData[4]; image = ToolDontDestory.Instance.LoadImage(relicData[2]); + LegacyManager.Instance.legacyNodesList.Add(relicName,this); GetComponent().sprite = image; if (isOnGet ) { @@ -29,13 +33,14 @@ public class LegacyNode : MonoBehaviour } public virtual void CreateSaledRelic(string className, bool isOnGet) { - LegacyManager.Instance.legacyNodesList.Add(this); + List relicData = LegacyManager.Instance.relicsDictionary[className]; relicName = relicData[3]; relicClassName = relicData[1]; infor = relicData[4]; image = ToolDontDestory.Instance.LoadImage(relicData[2]); transform.GetChild(0).GetComponent().sprite = image; + LegacyManager.Instance.legacyNodesList.Add(relicName,this); if (isOnGet) { OnGet(); @@ -50,7 +55,7 @@ public class LegacyNode : MonoBehaviour public virtual void EffectInPlayerTurnBegin() { - + count = 0; } public virtual void EffectInPlayerTurnEnd() { @@ -64,4 +69,24 @@ public class LegacyNode : MonoBehaviour { } + + public virtual void Use() + { + + } + + public virtual void ResetCount() + { + count = 0; + } + + public virtual bool IsUseful() + { + return isUseful; + } + + public virtual void AddCount(int i) + { + count+=i; + } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs index 27783e9b..42e5af9d 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/MapUnity.cs @@ -1,9 +1,11 @@ using System; using System.Collections; using System.Collections.Generic; +using System.Linq; using Unity.VisualScripting; using UnityEngine; using UnityEngine.InputSystem; +using UnityEngine.Playables; using UnityEngine.UI; public class MapUnity : MonoBehaviour @@ -16,6 +18,8 @@ public class MapUnity : MonoBehaviour public int cubeS; public int cubeR; + public bool canChange=true; + public bool compalte;//标识已完成 [Header("UI效果范围控件")] @@ -201,6 +205,44 @@ public class MapUnity : MonoBehaviour public void switchColor(int newColor) { + if (canChange==false) + { + return; + } + if (whoColour == newColor) + { + return; + } + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_BloodBorne)&&enemyNode!=null) + { + enemyNode.sufferAbnormalCondition(AbnormalCondition.bleed, 4); + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_Filter)&&whoColour==Name.NodeColor.Black) + { + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(1); + } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_PurityBadge) && whoColour == Name.NodeColor.Black) + { + SettlementManager.Instance.damageWork(4, getNodeTools.getAllNodes().ToList(), 0); + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_PurityBadge].isUseful=false; + } + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_ChaosTrigger)) + { + LegacyNode_ChaosTrigger legacyNode_ChaosTrigger = (LegacyNode_ChaosTrigger)LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_ChaosTrigger]; + switch (newColor) + { + + case Name.NodeColor.Yellow: + legacyNode_ChaosTrigger.yellowTrigger=true; + break; + case Name.NodeColor.Blue: + legacyNode_ChaosTrigger.blueTrigger = true; + break; + case Name.NodeColor.Red: + legacyNode_ChaosTrigger.redTrigger = true; + break; + } + } if (whoColour!=6&& whoColour != 10) { whoColour = newColor; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs index f93e766d..12666489 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Player.cs @@ -261,7 +261,8 @@ public class Player : MonoBehaviour Usermanager.Instance.ParasitismnRealize(movePath [i]);//传入当前node Usermanager.Instance.bleedRealize(); //减体力 - GameManager.Instance.playerState.currentStepRange -= 1; + GameManager.Instance.playerState.currentStepRange -= 1; + LegacyManager.Instance.tryUseLegacy(Name.Legacy.LegacyNode_PlatedSteelcaps); } this.gameObject.transform.position = new Vector3(mapNode.transform.position.x, 0.5f, mapNode.transform.position.z); @@ -280,6 +281,10 @@ public class Player : MonoBehaviour // moveLineRenderer.enabled = false; playerMoveDestination.SetActive(false); destinationCannotUpdate = false; + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_Bipod)) + { + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_Bipod].ResetCount(); + } } else { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/PlayerManager/PlayerStatsManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/PlayerManager/PlayerStatsManager.cs index 9d583c8d..9562417f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/PlayerManager/PlayerStatsManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/PlayerManager/PlayerStatsManager.cs @@ -118,7 +118,7 @@ public class PlayerStatsManager : Singleton public void gainMoney(int value) { playerState.money += value; - MathTool.keepNature(playerState.money); + MathTool.keepNature(ref playerState.money); if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_GoldVines)) { playerState.currentHP += 2; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/AbnormalCondition.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/AbnormalCondition.cs index 70a57904..39af5daa 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/AbnormalCondition.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/AbnormalCondition.cs @@ -73,12 +73,45 @@ public class AbnormalCondition : Singleton public const string armor = "51"; //脱落 public const string shedding = "52"; + //流血伤害 + public const string bleedDamage = "57"; + //致残 + public const string disable = "58"; + //无法获得护盾 + public const string cantShield = "70"; + //血疗:目标单位的下次流血伤害会治疗玩家 + public const string bleedHeal = "74"; + //回合内触发4次流血,获得1点能量 + public const string bleed4TurnCost = "75"; + //回合内触发3次流血,获得1点能量 + public const string bleed3TurnCost = "76"; + //使下一张牌消耗改为血量 + public const string nextCardCostHp = "77"; + //使下一张牌消耗-1 + public const string nextCardCostMinusOne = "78"; + //本回合无法释放效果牌 + public const string cantUserEffectCaed = "79"; + //手牌涂色牌费用-1 + public const string dyeingCardCostMinusOne = "80"; + //下张涂色牌施法距离+2 + public const string nextDyeingCardRangeAddTwo = "81"; + //下一张效果牌结算两次 + public const string nextEffectCardDoubleSettle = "82"; + //死亡印记 + public const string deathMark = "83"; + //1回合临时狂热 + public const string tempEmberOneRound = "87"; + //2回合临时狂热 + public const string tempEmberTwoRound = "88"; + //下张涂色牌消耗为0 + public const string nextDyeingCardCostZero = "92"; public static readonly List canNegativeNumberList = new List { angerUpperDamage, shieldUpperValue, addDrawCard }; - public static readonly List playBuffList = new List {firm, addDrawCard, upSpeed , immunity, fireShield, doubleSettle, nextTurnExtraOneCost ,tempCastRange}; + public static readonly List playBuffList = new List {firm, addDrawCard, upSpeed , immunity, fireShield, doubleSettle, nextTurnExtraOneCost ,tempCastRange, bleedDamage, bleed3TurnCost, bleed4TurnCost, nextCardCostMinusOne, nextCardCostHp, dyeingCardCostMinusOne + ,nextDyeingCardRangeAddTwo,nextEffectCardDoubleSettle}; public static readonly List playUndeterminedBuffList = new List { angerUpperDamage, shieldUpperValue }; - public static readonly List enemyDebuffList = new List { wet, banStep , fireSeed , levelSleep , vulnerable , bleed , sleep ,disarm, posion , weak ,coma}; + public static readonly List enemyDebuffList = new List { wet, banStep , fireSeed , levelSleep , vulnerable , bleed , sleep ,disarm, posion , weak ,coma, disable ,bleedHeal, deathMark }; } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardFunction.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardFunction.cs index cd36ce7b..b8e0aa77 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardFunction.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/CardFunction.cs @@ -105,4 +105,85 @@ public static class CardFunction public const string placeTrees = "51"; //击退 public const string repel = "52"; + //x*y点伤害 + public const string damagexy = "53"; + //对红色地块造成伤害 + public const string damageForRedNode = "54"; + //对红色地块造成流血 + public const string bleedForRedNode = "55"; + //抽取涂色牌 + public const string drawDyeingCard = "56"; + //流血伤害 + public const string bleedDamage = "57"; + //致残 + public const string disable = "58"; + //消耗所有黄,获得对应数量的护盾 + public const string turnYellowNodesToShield = "59"; + //获得黄对应数量的护盾,流下一半黄色 + public const string turnHalfYellowNodesToShield = "60"; + //消耗玩家周围2范围地块,每消耗3红获得1层狂热 + public const string turn3RedNodesToEmber = "61"; + //消耗玩家周围2范围地块,每消耗3红获得1层狂热 + public const string turn2RedNodesToEmber = "62"; + //对目标造成护盾的伤害 + public const string shieldToDamage = "63"; + //若目标身上有流血,获得护盾 + public const string ifBleedThenShield = "64"; + //失去生命 + public const string lostHp = "65"; + //使得目标流血翻倍 + public const string doubleBleed = "66"; + //使得目标流血翻3倍 + public const string tripleBleed = "67"; + //结算单位一半流血层数 + public const string settleHalfBleed = "68"; + //结算单位全部流血层数 + public const string settleAllBleed = "69"; + //无法获得护盾 + public const string cantShield = "70"; + //获得生命值上限一半的护盾 + public const string halfHpShield = "71"; + //消耗玩家2范围颜色,每消耗1红对1范围内所有敌人施加1流血 + public const string turnRedNodesToBleed = "72"; + //消耗玩家2范围颜色,每消耗1红对2范围内所有敌人施加1流血 + public const string turnRedNodesToBleedInTwoCirCle = "73"; + //血疗:目标单位的下次流血伤害会治疗玩家 + public const string bleedHeal = "74"; + //回合内触发4次流血,获得1点能量 + public const string bleed4TurnCost = "75"; + //回合内触发3次流血,获得1点能量 + public const string bleed3TurnCost = "76"; + //使下一张牌消耗改为血量 + public const string nextCardCostHp = "77"; + //使下一张牌消耗-1 + public const string nextCardCostMinusOne = "78"; + //本回合无法释放效果牌 + public const string cantUserEffectCaed = "79"; + //手牌涂色牌费用-1 + public const string dyeingCardCostMinusOne = "80"; + //下张涂色牌施法距离+2 + public const string nextDyeingCardRangeAddTwo = "81"; + //下一张效果牌结算两次 + public const string nextEffectCardDoubleSettle = "82"; + //死亡印记 + public const string deathMark = "83"; + //玩家出现在周围随机1格 + public const string teleportAround = "84"; + //无限施法距离 + public const string infCastRange = "85"; + //卡牌本身释放距离+1 + public const string castRangePlusOne = "86"; + //1回合临时狂热 + public const string tempEmberOneRound = "87"; + //2回合临时狂热 + public const string tempEmberTwoRound = "88"; + //抽取效果牌 + public const string drawEffectCard = "89"; + //使流血伤害翻倍 + public const string doublebleedDamage = "90"; + //抽一张牌;获得这张牌的复制 + public const string drawAndCopyCard = "91"; + //下张涂色牌消耗为0 + public const string nextDyeingCardCostZero = "92"; + } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs index 44549056..2af39efa 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/MathTool.cs @@ -134,22 +134,54 @@ public class MathTool public static (int x, int y) CubeToAxial(int q, int s, int r) { - + int x; int y = -r; - int x = q - (y + 1) / 2; + if (y % 2 == 0) + { + x = q - y / 2; + } + else + { + x = q - (y + 1) / 2; + } + return (x, y); } // 从轴向坐标转换为立方坐标 public static (int q, int s, int r) AxialToCube(int x, int y) { - - int q = (y+1)/2+x; + int q; + if (y % 2 == 0) + { + q = x + y / 2; + } + else + { + q = x + (y+1) / 2; + } + + + int r = -y; int s = -q - r; return (q, s, r); } + // 生成一个大小为 size 的随机颜色列表 + public static List GenerateRandomPlayerColorList(int size) + { + System.Random rand = new System.Random(); + List result = new List(); + for (int i = 0; i < size; i++) + { + // 随机从 PlayerColor 中选择一个元素 + int randomColor = Name.NodeColor.PlayerColor[rand.Next(Name.NodeColor.PlayerColor.Count)]; + result.Add(randomColor); + } + return result; + } + public static List<(int x, int y, int z)> TranslateHexesToNewOrigin(List<(int x, int y, int z)> hexList, (int x, int y, int z) newOrigin) { List<(int x, int y, int z)> translatedHexes = new List<(int x, int y, int z)>(); @@ -178,7 +210,7 @@ public class MathTool return (newX,newY,newZ); } - public static void keepNature(int number) + public static void keepNature(ref int number) { if (number < 0) { @@ -209,7 +241,8 @@ public class MathTool } else { - Console.WriteLine($"要添加的值 '{value}' 不是有效的整数,无法添加。"); + dictionary.Add(key, value); + //Console.WriteLine($"要添加的值 '{value}' 不是有效的整数,无法添加。"); } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/Name.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/Name.cs index c3748302..3e21b4e7 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/Name.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/Name.cs @@ -1,5 +1,6 @@ using System.Collections; using System.Collections.Generic; +using System.Linq; using UnityEngine; public static class Name { @@ -51,6 +52,30 @@ public static class Name public const string LegacyNode_SuspiciousMushroom = "LegacyNode_SuspiciousMushroom"; public const string LegacyNode_SnakeGall = "LegacyNode_SnakeGall"; + public const string LegacyNode_BloodBorne = "LegacyNode_BloodBorne"; + public const string LegacyNode_WasteReconstructor = "LegacyNode_WasteReconstructor"; + public const string LegacyNode_BloodTax = "LegacyNode_BloodTax"; + public const string LegacyNode_Parasol = "LegacyNode_Parasol"; + public const string LegacyNode_Sneakers = "LegacyNode_Sneakers"; + public const string LegacyNode_BigBackpack = "LegacyNode_BigBackpack"; + public const string LegacyNode_FreeBullet = "LegacyNode_FreeBullet"; + public const string LegacyNode_PlatedSteelcaps = "LegacyNode_PlatedSteelcaps"; + public const string LegacyNode_Cheese = "LegacyNode_Cheese"; + public const string LegacyNode_SpeedLoader = "LegacyNode_SpeedLoader"; + public const string LegacyNode_LightningBoots = "LegacyNode_LightningBoots"; + public const string LegacyNode_MeatSaw = "LegacyNode_MeatSaw"; + public const string LegacyNode_Prism = "LegacyNode_Prism"; + public const string LegacyNode_ActivatedCarbon = "LegacyNode_ActivatedCarbon"; + public const string LegacyNode_PerpetualMotionPump = "LegacyNode_PerpetualMotionPump"; + public const string LegacyNode_PortableReactor = "LegacyNode_PortableReactor"; + public const string LegacyNode_Filter = "LegacyNode_Filter"; + public const string LegacyNode_NurturingBloom = "LegacyNode_NurturingBloom"; + public const string LegacyNode_PurityBadge = "LegacyNode_PurityBadge"; + public const string LegacyNode_ChaosTrigger = "LegacyNode_ChaosTrigger"; + public const string LegacyNode_AegisOfTheImmortal = "LegacyNode_AegisOfTheImmortal"; + public const string LegacyNode_Bipod = "LegacyNode_Bipod"; + public const string LegacyNode_PainContract = "LegacyNode_PainContract"; + @@ -101,7 +126,8 @@ public static class Name public const int White = 2; public const int Black = 5; public const int Metal = 6; - public static readonly List PlayerColor = new() { Red, Green, Blue }; + public const int Yellow = 7; + public static readonly List PlayerColor = new() { Red, Blue, Yellow }; public static readonly List EnemyColor = new() { Black }; } @@ -116,6 +142,8 @@ public static class Name intcolor = NodeColor.Green; break; case Color.Blue: intcolor = NodeColor.Blue; break; + case Color.Yellow: + intcolor = NodeColor.Yellow; break; case Color.White: intcolor = NodeColor.White; break; case Color.Black: @@ -125,6 +153,29 @@ public static class Name } return intcolor; } + + public static int stringAroundColorToint(string color) + { + int intcolor = 10; + switch (color) + { + case AroundColor.Red: + intcolor = NodeColor.Red; break; + case AroundColor.Green: + intcolor = NodeColor.Green; break; + case AroundColor.Blue: + intcolor = NodeColor.Blue; break; + case AroundColor.Yellow: + intcolor = NodeColor.Yellow; break; + case AroundColor.White: + intcolor = NodeColor.White; break; + case AroundColor.Black: + intcolor = NodeColor.Black; break; + case AroundColor.Metal: + intcolor = NodeColor.Metal; break; + } + return intcolor; + } public static string intColorTostring(int color) { string stringColor = Color .White ; @@ -136,6 +187,8 @@ public static class Name stringColor = Color.Green; break; case NodeColor.Blue: stringColor = Color.Blue; break; + case NodeColor.Yellow: + stringColor = Color.Yellow; break; case NodeColor.White: stringColor = Color.White; break; case NodeColor.Black: @@ -150,10 +203,25 @@ public static class Name public const string Red = "red"; public const string Green = "green"; public const string Blue = "blue"; + public const string Yellow = "yellow"; public const string White = "white"; public const string Black = "black"; public const string Metal = "metal"; - + public static readonly List AllColor = new() { Red, Green, Blue, Yellow ,White, Black , Metal }; + + } + + public static class AroundColor + { + public const string Red = "aroundred"; + public const string Green = "aroundgreen"; + public const string Blue = "aroundblue"; + public const string Yellow = "aroundyellow"; + public const string White = "aroundwhite"; + public const string Black = "aroundblack"; + public const string Metal = "aroundmetal"; + public static readonly List AllColor = new() { Red, Green, Blue, Yellow, White, Black, Metal }; + } public static class Faction @@ -171,6 +239,14 @@ public static class Name public const string node = "4"; } + public static class Regex + { + //1*** + public const string pattern1xxx = @"^1\d{3}$"; + //2*** + public const string pattern2xxx = @"^2\d{3}$"; + } + public static class CardFunctionString { public const string damage = "damage"; diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs index 3b42ee3c..5e51ea7a 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Tool/getNodeTools.cs @@ -5,6 +5,8 @@ using System.Linq; using Unity.VisualScripting; using UnityEngine; using UnityEngine.UIElements; +using static TMPro.SpriteAssetUtilities.TexturePacker_JsonArray; +using static Unity.Collections.AllocatorManager; using static UnityEditor.Experimental.AssetDatabaseExperimental.AssetDatabaseCounters; using static UnityEditor.FilePathAttribute; @@ -303,6 +305,22 @@ public class getNodeTools return colorCount; } + public static int getPlayerAroundNodesCount(string color) + { + MapUnity playerNode = GameManager.Instance.playerOn; + HashSet set = new HashSet { playerNode }; + getCircleNode(set, 1); + int colorCount = 0; + foreach(MapUnity mapUnity in set) + { + if (mapUnity.whoColour.Equals(Name.stringAroundColorToint(color))) + { + colorCount++; + } + } + return colorCount; + } + public static bool tryGetNodeFroPlayer(MapUnity currentNode, HashSet results) { bool canPass = true; @@ -734,6 +752,39 @@ public class getNodeTools }*/ } + public static HashSet getNodesWithColor(string color) + { + var nodes = new HashSet(); + for (int i = 0; i < GameManager.Instance.X.Count; i++) + { + for (int j = 0; j < GameManager.Instance.X[i].Y.Count; j++) + { + if (GameManager.Instance.X[i].Y[j].whoColour.Equals(Name.stringColorToint(color))) + { + nodes.Add(GameManager.Instance.X[i].Y[j]); + } + + + } + } + return nodes; + } + + public static HashSet getNodesWithColor(string color,HashSet mapUnities) + { + var nodes = new HashSet(); + foreach(MapUnity mapUnity in mapUnities) + { + if (mapUnity.whoColour.Equals(Name.stringColorToint(color))) + { + nodes.Add(mapUnity); + } + } + + + return nodes; + } + public static void setEffectRangePreviewTest(CardOriginalData cardOriginalData, float euler, MapUnity currentNode, CardEntity cardEntity) { Debug.Log("currentNode的X是" + currentNode.locationX + "currentNode的Y是" + currentNode.locationY); diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/BuffDataManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/BuffDataManager.cs index 296acf27..fa80248f 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/BuffDataManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/BuffDataManager.cs @@ -41,6 +41,20 @@ public class BuffDataManager : Singleton abnormalCondition.Add("50", new Buff_TempCastRange()); abnormalCondition.Add("51", new Buff_Armor()); abnormalCondition.Add("52", new Buff_Shedding()); + abnormalCondition.Add("57", new Buff_BleedDamage()); + abnormalCondition.Add("58", new Buff_Disable()); + abnormalCondition.Add("70", new Buff_CantShield()); + abnormalCondition.Add("74", new Buff_BleedHeal()); + abnormalCondition.Add("75", new Buff_Bleed4TurnCost()); + abnormalCondition.Add("76", new Buff_Bleed3TurnCost()); + abnormalCondition.Add("77", new Buff_NextCardCostHp()); + abnormalCondition.Add("78", new Buff_NextCardCostMinusOne()); + abnormalCondition.Add("79", new Buff_CantUserEffectCaed()); + abnormalCondition.Add("80", new Buff_DyeingCardCostMinusOne()); + abnormalCondition.Add("81", new Buff_NextDyeingCardRangeAddTwo()); + abnormalCondition.Add("82", new Buff_NextEffectCardDoubleSettle()); + abnormalCondition.Add("83", new Buff_DeathMark()); + abnormalCondition.Add("92", new Buff_NextDyeingCardCostZero()); abnormalCondition.Add("106", new Buff_flashPoint()); diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/CardManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/CardManager.cs index c69067ed..c2cd44c1 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/CardManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/CardManager.cs @@ -6,7 +6,9 @@ using System.Linq; using System.Text; using System.Text.RegularExpressions; using Newtonsoft.Json; +using TMPro; using Unity.VisualScripting; +using UnityEditor.Experimental.GraphView; using UnityEngine; using UnityEngine.Rendering; using static GameManager; @@ -122,10 +124,14 @@ public class CardManager : Singleton { currentOperation = component; } - else + else if(Name.Color.AllColor.Contains(component)) { currentNumber = getNodeTools.getNodesCount(component); } + else + { + currentNumber = getNodeTools.getPlayerAroundNodesCount(component); + } // 如果没有操作符,设置初始值为 currentNumber if (result == 0 && string.IsNullOrEmpty(currentOperation)) @@ -222,7 +228,7 @@ public class CardManager : Singleton } public static void createCardImageMap() { - MapUnity currentNode = CardPictureManager.Instance.ToolX[3].Y[3]; + MapUnity currentNode = CardPictureManager.Instance.ToolX[4].Y[4]; foreach (CardOriginalData cardOriginalData in CardOriginalDataList.Instance.existCardOriginalDataList.Values) { Debug.Log("createcardimage!"); @@ -263,14 +269,19 @@ public class CardManager : Singleton { } } List<(int, int, int)> rotatedCubeList = new List<(int, int, int)>(); + for (int i = 0; i < cubeList.Count; i++) + { + Debug.Log("cubeList的Q是" + cubeList[i].Item1 + "cubeList的S是" + cubeList[i].Item2 + "cubeList的R是" + cubeList[i].Item3); + } rotatedCubeList = MathTool.RotateCoordinates(cubeList, intEuler); for (int i = 0; i < rotatedCubeList.Count; i++) { Debug.Log("rotatedCube的Q是" + rotatedCubeList[i].Item1 + "rotatedCube的S是" + rotatedCubeList[i].Item2 + "rotatedCube的R是" + rotatedCubeList[i].Item3); } List<(int, int, int)> trueCubeList = new List<(int, int, int)>(); - Debug.Log("currentNode的Q是" + currentNode.cubeQ + "currentNode的S是" + currentNode.cubeS + "currentNode的R是" + currentNode.cubeR); + Debug.Log("坐标中心是X:" + currentNode.locationX + "Y:" + currentNode.locationY); trueCubeList = MathTool.TranslateHexesToNewOrigin(rotatedCubeList, (currentNode.cubeQ, currentNode.cubeS, currentNode.cubeR)); + List endNodeList= new List(); for (int i = 0; i < trueCubeList.Count; i++) { MapUnity endNode = new MapUnity(); @@ -280,7 +291,8 @@ public class CardManager : Singleton { Debug.Log("染色成功" + cardOriginalData.nodesColor[i]); endNode.switchColorWithoutFX(Name.stringColorToint(cardOriginalData.nodesColor[i])); - endNode.gameObject.SetActive(true); + endNode.gameObject.SetActive(true); + endNodeList.Add(endNode); //endNode.influenced = true; } } @@ -292,6 +304,26 @@ public class CardManager : Singleton int maxXDiff = xCoords.Max() - xCoords.Min(); int maxYDiff = yCoords.Max() - yCoords.Min(); + //直接计算图形的几何中心 + Vector3 sum = Vector3.zero; + foreach (MapUnity mapUnity in endNodeList) + { + Vector3 targetPosition = mapUnity.transform.position; + sum += mapUnity.transform.position; + } + Vector3 target=sum/ endNodeList.Count; + // 计算 q, r, s 坐标的平均值 + int count = trueCubeList.Count; + int sumQ = trueCubeList.Sum(p => p.Item1); + int sumS = trueCubeList.Sum(p => p.Item2); + int sumR = trueCubeList.Sum(p => p.Item3); + double divisionAveQ = sumQ /count; + double divisionAveS = sumS / count; + double divisionAveR = sumR / count; + int aveQ= (int)Math.Round(divisionAveQ); + int aveS = (int)Math.Round(divisionAveS); + int aveR = (int)Math.Round(divisionAveR); + Debug.Log("QSRCOUNT是" + count); // 比较最大差值 int maxDiff = Math.Max(maxXDiff, maxYDiff); @@ -299,7 +331,10 @@ public class CardManager : Singleton Camera renderCamera = CardPictureManager.Instance.cameraObject.GetComponent(); renderCamera.targetTexture = renderTexture; Texture2D texture = new Texture2D(renderTexture.width, renderTexture.height, TextureFormat.ARGB32, false); - cameraAdjust(maxDiff, renderCamera, currentNode); + Debug.Log("相机中心是Q:" + aveQ + "S:" + aveS + "R:" + aveR); + MapUnity camearNode=changeCameraCenter(aveQ, aveS, aveR); + //cameraAdjust(maxDiff, renderCamera, camearNode); + cameraAdjustTest(maxDiff, renderCamera, target); RenderTexture.active = renderCamera.targetTexture; renderCamera.Render(); texture.ReadPixels(new Rect(0, 0, renderTexture.width, renderTexture.height), 0, 0); @@ -314,16 +349,42 @@ public class CardManager : Singleton } + public static MapUnity changeCameraCenter(int q,int s,int r) + { + GameObject camera = CardPictureManager.Instance.cameraObject; + MapUnity endNode = new MapUnity(); + endNode = getNodeTools.getToolNodeWithCube(q, s, r); + Debug.Log("相机中心是X:" + endNode.locationX+"Y:"+endNode.locationY); + /*Vector3 targetPosition = endNode.transform.position; + camera.transform.position = targetPosition + new Vector3(0, 10.0f, 0);*/ + return endNode; + } + public static void cameraAdjust(int distance, Camera camera,MapUnity target) { // 设置最大差值对应的摄像机距离范围 float minDistance = 1.5f; float maxDistance = 12f; Debug.Log("distance是" + distance); - float newDistance = Mathf.Lerp(minDistance, maxDistance, distance / 20f); // 假设最大差值不超过100 + float newDistance = Mathf.Lerp(minDistance, maxDistance, distance / 15f); // 假设最大差值不超过100 Debug.Log("newDistance是" + newDistance); + camera.transform.position = target.transform.position + new Vector3(0, 10.0f, 0); Vector3 direction = (camera.transform.position - target.transform.position).normalized; camera.transform.position = target.transform.position + direction * newDistance; camera.orthographicSize = newDistance; } + + public static void cameraAdjustTest(int distance, Camera camera, Vector3 target) + { + // 设置最大差值对应的摄像机距离范围 + float minDistance = 1.5f; + float maxDistance = 12f; + Debug.Log("distance是" + distance); + float newDistance = Mathf.Lerp(minDistance, maxDistance, distance / 15f); // 假设最大差值不超过100 + Debug.Log("newDistance是" + newDistance); + camera.transform.position = target + new Vector3(0, 10.0f, 0); + Vector3 direction = (camera.transform.position - target).normalized; + camera.transform.position = target + direction * newDistance; + camera.orthographicSize = newDistance; + } } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs index 81347ab8..4fd7b4ad 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/DestructionManager.cs @@ -5,6 +5,7 @@ using System.Text.RegularExpressions; using UnityEngine; using UnityEngine.Rendering; using UnityEngine.Windows; +using static Name; public class DestructionManager : Singleton { @@ -17,6 +18,11 @@ public class DestructionManager : Singleton } else { + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_PortableReactor)) + { + StartCoroutine(TurnMaster.Instance.drawCards(1)); + yield return StartCoroutine(TurnMaster.Instance.MoveCards()); + } TurnMaster.Instance.usedCard.deleteCardList.Add(target.GetComponent().CardId); } TurnMaster.Instance.handCard.cardEntityList.Remove(target.GetComponent()); @@ -37,7 +43,7 @@ public class DestructionManager : Singleton foreach (string condition in cardOriginalData.conditionAndFunctionVal.Keys) { Debug.Log("外面condition是" + condition); - Match match = Regex.Match(condition, pattern); + Match match = System.Text.RegularExpressions.Regex.Match(condition, pattern); if (match.Success) { Debug.Log("match成功"); @@ -98,6 +104,7 @@ public class DestructionManager : Singleton { bool canAdv = GameManager.Instance.SyncColourCountUI(); int leftCost = GameManager.Instance.playerState.currentCost; + string trueCostType; /*if (cardOriginalData.FunctionVal.ContainsKey(CardFunction.xCost)) { GameManager.Instance.playerState.currentCost = 0; @@ -119,13 +126,27 @@ public class DestructionManager : Singleton } else {*/ - int trueCost = cardOriginalData.Cost; - //灰色地块效果 - if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Black)) + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextDyeingCardRangeAddTwo)&& cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + Usermanager.playerAbnormalCondition[AbnormalCondition.nextDyeingCardRangeAddTwo].value -= 1; + } + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.tempCastRange)) { - trueCost++; + Usermanager.playerAbnormalCondition[AbnormalCondition.tempCastRange].value--; } - switch (cardOriginalData.costType) + if (cardOriginalData.CardType.Equals(Name.CardType.dyeing)) + { + LegacyManager.Instance.tryAddCount(Name.Legacy.LegacyNode_FreeBullet,1); + } + if (cardOriginalData.CardType.Equals(Name.CardType.effect)) + { + LegacyManager.Instance.tryAddCount(Name.Legacy.LegacyNode_SpeedLoader, 1); + LegacyManager.Instance.tryAddCount(Name.Legacy.LegacyNode_LightningBoots, 1); + } + + int trueCost; + (trueCost, trueCostType) = CardResourcesManager.Instance.getCardCostForSettle(cardOriginalData); + switch (trueCostType) { case Name.CostType.energy: GameManager.Instance.playerState.currentCost -= trueCost; @@ -143,12 +164,12 @@ public class DestructionManager : Singleton //} yield return StartCoroutine(settleStage2(cardOriginalData, influencePreviewPool, cardIndex, leftCost, targetNode)); - if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.doubleSettle)) + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.nextEffectCardDoubleSettle)&&cardOriginalData.CardType.Equals(Name.CardType.effect)) { - Usermanager.playerAbnormalCondition[AbnormalCondition.doubleSettle].value--; - if (Usermanager.playerAbnormalCondition[AbnormalCondition.doubleSettle].value <= 0) + Usermanager.playerAbnormalCondition[AbnormalCondition.nextEffectCardDoubleSettle].value--; + if (Usermanager.playerAbnormalCondition[AbnormalCondition.nextEffectCardDoubleSettle].value <= 0) { - Usermanager.playerAbnormalCondition.Remove(AbnormalCondition.doubleSettle); + Usermanager.playerAbnormalCondition.Remove(AbnormalCondition.nextEffectCardDoubleSettle); } yield return StartCoroutine(settleStage2(cardOriginalData, influencePreviewPool, cardIndex, leftCost, targetNode)); } @@ -188,7 +209,13 @@ public class DestructionManager : Singleton { yield return StartCoroutine(SettlementManager.Instance.settle(cardOriginalData, influencePreviewPool, cardIndex, targetNode)); } - + if (LegacyManager.Instance.relicClassNameList.Contains(Name.Legacy.LegacyNode_PurityBadge)) + { + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_PurityBadge].isUseful = true; + } + + + } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs index 2cee6d61..fb33b447 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnityManager.cs @@ -17,6 +17,8 @@ public class MapUnityManager : Singleton public int metalNodeCount; + public int yellowNodeCount; + public int playerNodeCount; public int neutralNodeCount; @@ -102,7 +104,7 @@ public class MapUnityManager : Singleton { if(GameManager .Instance .complete ==true ) { - int red = 0, blue = 0, green = 0, white = 0, black = 0,metal=0; + int red = 0, blue = 0, green = 0, white = 0, black = 0,metal=0,yellow=0; for (int i = 0; i < GameManager.Instance.X.Count; i++) { for (int j = 0; j < GameManager.Instance.X[i].Y.Count; j++) @@ -127,11 +129,15 @@ public class MapUnityManager : Singleton case Name.NodeColor.Metal: metal++; break; + case Name.NodeColor.Yellow: + yellow++; + break; } } } redNodeCount = red; blueNodeCount = blue; greenNodeCount = green; whiteNodeCount = white; blackNodeCount = black;metalNodeCount =metal; - playerNodeCount = redNodeCount + blueNodeCount + greenNodeCount; + yellowNodeCount= yellow; + playerNodeCount = redNodeCount + blueNodeCount + greenNodeCount+yellowNodeCount; neutralNodeCount = whiteNodeCount + metalNodeCount; enemyNodeCount = blackNodeCount; @@ -209,4 +215,14 @@ public class MapUnityManager : Singleton mapUnity.playerMark.meshRenderer.material = mapUnity.red; } } -} + + public void getCastPoolForInfRange() + { + castPool= getNodeTools.getAllCanUseNode(); + foreach (MapUnity mapUnity in castPool) + { + mapUnity.PlayerInfluenced(castPool); + mapUnity.playerMark.meshRenderer.material = mapUnity.red; + } + } + } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnitySettleManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnitySettleManager.cs index 26ad5638..2559d2b4 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnitySettleManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/MapUnitySettleManager.cs @@ -72,8 +72,8 @@ public class MapUnitySettleManager : Singleton public void MapGridsBeginSettle() { - PlayerMudGridBeginSettle(1); + } public void MapGridsEndSettle() diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs index 74203025..959ebe69 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/SettlementManager.cs @@ -1,9 +1,11 @@ using System; using System.Collections; using System.Collections.Generic; +using System.Linq; using Unity.VisualScripting; using UnityEditor.Experimental.GraphView; using UnityEngine; +using static Name; public class SettlementManager : Singleton @@ -23,6 +25,36 @@ public class SettlementManager : Singleton } } } + + public void doubleBleed(List influencePreviewPool) + { + if (influencePreviewPool[0].enemyNode != null && influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + int originCount = influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value; + int result = originCount * 2; + influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value=result; + } + } + + public void doubleBleedDamage() + { + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.bleedDamage)) + { + int val= Usermanager.playerAbnormalCondition[AbnormalCondition.bleedDamage].value; + val= val * 2; + Usermanager.playerAbnormalCondition[AbnormalCondition.bleedDamage].value=val; + } + } + + public void tripleBleed(List influencePreviewPool) + { + if (influencePreviewPool[0].enemyNode != null && influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + int originCount = influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value; + int result = originCount * 3; + influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value = result; + } + } //造成伤害 //染色 @@ -273,22 +305,50 @@ public class SettlementManager : Singleton GameManager.Instance.playerState.currentCost += nodeCount/val; } - /* private void consumePlayerNodesForHealthWork(List influencePreviewPool) + private void settleHalfBleed(List influencePreviewPool) { - int successNodeCount = 0; - Debug.Log("influencePreviewPool" + influencePreviewPool.Count); - for (int i = 0; i < influencePreviewPool.Count; i++) + if (influencePreviewPool[0].enemyNode != null && influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) { - if(influencePreviewPool[i].whoColour == MapUnity.WhoColour.playerColour) + int originCount = influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value; + int result = originCount/2; + int settleCount = originCount = result; + for (int i = 0; i < settleCount; i++) { - successNodeCount++; - influencePreviewPool[i].whoColour= MapUnity.WhoColour.noneColour; - Debug.Log("successNodeCount是" + successNodeCount); + influencePreviewPool[0].enemyNode.bleedRealize(); } + + } - GameManager.Instance.SyncColourCountUI(); - Usermanager.Instance.recoverHp(successNodeCount); - }*/ + } + + private void settleAllBleed(List influencePreviewPool) + { + if (influencePreviewPool[0].enemyNode != null && influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + int originCount = influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition[AbnormalCondition.bleed].value; + for (int i = 0; i < originCount; i++) + { + influencePreviewPool[0].enemyNode.bleedRealize(); + } + } + } + + /* private void consumePlayerNodesForHealthWork(List influencePreviewPool) + { + int successNodeCount = 0; + Debug.Log("influencePreviewPool" + influencePreviewPool.Count); + for (int i = 0; i < influencePreviewPool.Count; i++) + { + if(influencePreviewPool[i].whoColour == MapUnity.WhoColour.playerColour) + { + successNodeCount++; + influencePreviewPool[i].whoColour= MapUnity.WhoColour.noneColour; + Debug.Log("successNodeCount是" + successNodeCount); + } + } + GameManager.Instance.SyncColourCountUI(); + Usermanager.Instance.recoverHp(successNodeCount); + }*/ private void clearAllAbnormalConditons() { @@ -403,11 +463,24 @@ public class SettlementManager : Singleton attackCardOriginalDataList.Add(cardId); } } - TurnMaster.Instance.createCardWithoutMove(targetCardNum); + //TurnMaster.Instance.createCardWithoutMove(targetCardNum); CardActiveSort.Instance.ReflashCardPoint(); } + /*private void addNewestCardToHand() + { + int targetCardNum = 0; + int handCardCount = TurnMaster.Instance.handCard.cardEntityList.Count; + if(handCardCount== TurnMaster.Instance.handCard.maxHandCard) + { + return ; + } + TurnMaster.Instance.createCardWithoutMove(targetCardNum); + CardActiveSort.Instance.ReflashCardPoint(); + + }*/ + private void categorizeCardsByCarType() { @@ -439,26 +512,66 @@ public class SettlementManager : Singleton } } - - private void repel(List influencePreviewPool, MapUnity targetNode,int count) + private void teleportAround(List influencePreviewPool) + { + HashSet targets = new HashSet { influencePreviewPool[0] }; + getNodeTools.getCircleNode(targets, 1); + HashSet targetNode = MathTool.GetRandomElements(targets, 1); + + getNodeTools.playerTeleportToNode(targetNode.ElementAt(0)); + } + + + private void repelFromPlayer (List influencePreviewPool, MapUnity targetNode,int count) { - List pool= new List(influencePreviewPool); + targetNode = GameManager.Instance.playerOn; + List pool= new List(influencePreviewPool); pool.Remove(targetNode); List sortedPool = MathTool.sortByCubeDistance(pool, targetNode); foreach (MapUnity mapUnity in sortedPool) { if (mapUnity.enemyNode != null&& mapUnity.enemyNode.enemyType == EnemyNode.EnemyType.enemy) { - (int q,int s,int r)=MathTool.findRepelNode(mapUnity, targetNode); - MapUnity result = getNodeTools.getNodeWithCube(q, s, r); - GameObject enemy = mapUnity.enemyNode.GameObject(); - Debug.Log(enemy); - enemyMoveToNode(enemy, result, mapUnity.enemyNode); + MapUnity repelNode = mapUnity; + for (int i = 0; i < count; i++) + { + + (int q, int s, int r) = MathTool.findRepelNode(repelNode, targetNode); + MapUnity result = getNodeTools.getNodeWithCube(q, s, r); + GameObject enemy = repelNode.enemyNode.GameObject(); + Debug.Log(enemy); + enemyMoveToNode(enemy, result, repelNode.enemyNode); + repelNode = result; + } + } } } + private void repelFromNode(List influencePreviewPool, MapUnity targetNode, int count) + { + List pool = new List(influencePreviewPool); + pool.Remove(targetNode); + List sortedPool = MathTool.sortByCubeDistance(pool, targetNode); + foreach (MapUnity mapUnity in sortedPool) + { + if (mapUnity.enemyNode != null && mapUnity.enemyNode.enemyType == EnemyNode.EnemyType.enemy) + { + MapUnity repelNode = mapUnity; + for (int i = 0; i < count; i++) + { + + (int q, int s, int r) = MathTool.findRepelNode(repelNode, targetNode); + MapUnity result = getNodeTools.getNodeWithCube(q, s, r); + GameObject enemy = repelNode.enemyNode.GameObject(); + Debug.Log(enemy); + enemyMoveToNode(enemy, result, repelNode.enemyNode); + repelNode = result; + } + } + } + } private void pullFirstEnemyToSelf(List influencePreviewPool) { /*List ememyList = new List(); @@ -567,7 +680,7 @@ public class SettlementManager : Singleton else if (val < 0) { int trueStep = GameManager.Instance.playerState.currentStepRange + val; - MathTool.keepNature(trueStep); + MathTool.keepNature(ref trueStep); GameManager.Instance.playerState.currentStepRange = trueStep; } } @@ -618,10 +731,10 @@ public class SettlementManager : Singleton } else {*/ - trueFunctionVal.AddRange(cardOriginalData.testTrueFunctionVal); + trueFunctionVal.AddRange(cardOriginalData.TrueFunctionVal); foreach (KeyValuePair kvp in trueFunctionVal) { - Debug.Log("结算了" + kvp.Key); + Debug.Log("结算了" + kvp.Key+"数值是"+kvp.Value); } //弃牌不能先结算 foreach (KeyValuePair kvp in trueFunctionVal) @@ -640,6 +753,42 @@ public class SettlementManager : Singleton } break; + case CardFunction.drawDyeingCard: + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.banDrawCard)) + { + } + else + { + StartCoroutine(TurnMaster.Instance.drawDyeingCards(int.Parse(kvp.Value))); + + yield return StartCoroutine(TurnMaster.Instance.MoveCards()); + + } + break; + case CardFunction.drawEffectCard: + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.banDrawCard)) + { + } + else + { + StartCoroutine(TurnMaster.Instance.drawEffectCards(int.Parse(kvp.Value))); + + yield return StartCoroutine(TurnMaster.Instance.MoveCards()); + + } + break; + case CardFunction.drawAndCopyCard: + if (Usermanager.playerAbnormalCondition.ContainsKey(AbnormalCondition.banDrawCard)) + { + } + else + { + StartCoroutine(TurnMaster.Instance.drawAndCopyOneCard()); + + yield return StartCoroutine(TurnMaster.Instance.MoveCards()); + + } + break; } } @@ -650,6 +799,19 @@ public class SettlementManager : Singleton case CardFunction.cardDamage: damageWork(int.Parse(kvp.Value), influencePreviewPool, pierceNum); break; + case CardFunction.damagexy: + string[] values = kvp.Value.Split("-"); + int damageVal=int.Parse(values[0]); + int damageCount = int.Parse(values[1]); + for (int i = 0; i < damageCount; i++) + { + damageWork(damageVal, influencePreviewPool, pierceNum); + } + break; + case CardFunction.damageForRedNode: + List redList = new List(getNodeTools.getNodesWithColor(Name.Color.Red)); + damageWork(int.Parse(kvp.Value), redList, pierceNum); + break; case CardFunction.nodeDiffDamage: if (GameManager.Instance.getNodeDiffForPlayer() > 0) { @@ -663,6 +825,54 @@ public class SettlementManager : Singleton case CardFunction.cardShield: Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(int.Parse(kvp.Value)); break; + case CardFunction.halfHpShield: + int shidldVal =(int)GameManager.Instance.playerState.maxHP / 2; + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(shidldVal); + break; + case CardFunction.turnYellowNodesToShield: + List yellowList = new(getNodeTools.getNodesWithColor(Name.Color.Yellow)); + foreach(MapUnity mapUnity in yellowList) + { + mapUnity.switchColor(Name.NodeColor.White); + } + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(yellowList.Count); + break; + case CardFunction.turnHalfYellowNodesToShield: + List yellowListA = new(getNodeTools.getNodesWithColor(Name.Color.Yellow)); + yellowListA.Shuffle(); + for(int i = 0; i < yellowListA.Count/2;) + { + yellowListA[i].switchColor(Name.NodeColor.White); + } + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(yellowListA.Count); + break; + + case CardFunction.turn3RedNodesToEmber: + HashSet nearby2Nodes= new HashSet(); + HashSet nearby2RedNodes = new HashSet(); + nearby2Nodes.Add(GameManager.Instance.playerOn); + getNodeTools.getCircleNode(nearby2Nodes, 2); + nearby2RedNodes = getNodeTools.getNodesWithColor(Name.Color.Red, nearby2Nodes); + foreach (MapUnity mapUnity in nearby2Nodes) + { + mapUnity.switchColor(Name.NodeColor.White); + } + int emberCount=nearby2RedNodes.Count/3; + Usermanager.Instance.SufferPlayerAbnormalCondition(AbnormalCondition.angerUpperDamage, emberCount); + break; + case CardFunction.turn2RedNodesToEmber: + HashSet nearby2NodesA = new HashSet(); + HashSet nearby2RedNodesA = new HashSet(); + nearby2NodesA.Add(GameManager.Instance.playerOn); + getNodeTools.getCircleNode(nearby2NodesA, 2); + nearby2RedNodes = getNodeTools.getNodesWithColor(Name.Color.Red, nearby2NodesA); + foreach (MapUnity mapUnity in nearby2NodesA) + { + mapUnity.switchColor(Name.NodeColor.White); + } + int emberCountA = nearby2RedNodes.Count / 2; + Usermanager.Instance.SufferPlayerAbnormalCondition(AbnormalCondition.angerUpperDamage, emberCountA); + break; case CardFunction.posion: case CardFunction.weak: case CardFunction.coma: @@ -673,8 +883,26 @@ public class SettlementManager : Singleton case CardFunction.vulnerable: case CardFunction.banStep: case CardFunction.wet: + case CardFunction.disable: + case CardFunction.bleedHeal: + case CardFunction.deathMark: abnormalConditionWork(kvp.Key, int.Parse(kvp.Value), influencePreviewPool); break; + case CardFunction.doubleBleed: + doubleBleed(influencePreviewPool); + break; + case CardFunction.tripleBleed: + tripleBleed(influencePreviewPool); + break; + case CardFunction.settleHalfBleed: + settleHalfBleed(influencePreviewPool); + break; + case CardFunction.settleAllBleed: + settleAllBleed(influencePreviewPool); + break; + case CardFunction.bleedForRedNode: + abnormalConditionWork(CardFunction.bleed, int.Parse(kvp.Value), new List(getNodeTools.getNodesWithColor(Name.Color.Red))); + break; case CardFunction.step: currentStepChange(int.Parse(kvp.Value)); break; @@ -691,7 +919,7 @@ public class SettlementManager : Singleton // break; case CardFunction.repel: - repel(influencePreviewPool, targetNode,int.Parse(kvp.Value)); + repelFromPlayer(influencePreviewPool, targetNode,int.Parse(kvp.Value)); break; case CardFunction.dyeingAround: dyeingAroundWork(influencePreviewPool); @@ -711,6 +939,9 @@ public class SettlementManager : Singleton break; case CardFunction.teleport: break; + case CardFunction.teleportAround: + teleportAround(new List { targetNode }); + break; case CardFunction.pullFirstEnemyToSelf: pullFirstEnemyToSelf(influencePreviewPool); break; @@ -719,9 +950,22 @@ public class SettlementManager : Singleton case CardFunction.recoverHp: Usermanager.Instance.recoverHp(int.Parse(kvp.Value)); break; + case CardFunction.lostHp: + Usermanager.Instance.lostHp(int.Parse(kvp.Value)); + break; case CardFunction.spreadColorToAround: spreadColorToAround(int.Parse(kvp.Value),targetNode); break; + case CardFunction.shieldToDamage: + damageWork(Usermanager.Instance.Shield, influencePreviewPool, pierceNum); + break; + case CardFunction.ifBleedThenShield: + if (influencePreviewPool[0].enemyNode!=null&& + influencePreviewPool[0].enemyNode.EnemyState.abnormalCondition.ContainsKey(AbnormalCondition.bleed)) + { + Usermanager.Instance.Shield += Usermanager.Instance.ShieldCalculation(int.Parse(kvp.Value)); + } + break; case CardFunction.ember: case CardFunction.enhanceShield: case CardFunction.firm: @@ -734,9 +978,24 @@ public class SettlementManager : Singleton case CardFunction.nextTurnExtraOneCost: case CardFunction.immunity: case CardFunction.tempCastRange: + case CardFunction.bleedDamage: + case CardFunction.cantShield: + case CardFunction.bleed4TurnCost: + case CardFunction.bleed3TurnCost: + case CardFunction.nextCardCostHp: + case CardFunction.nextCardCostMinusOne: + case CardFunction.cantUserEffectCaed: + case CardFunction.dyeingCardCostMinusOne: + case CardFunction.nextDyeingCardRangeAddTwo: + case CardFunction.nextEffectCardDoubleSettle: Usermanager.Instance.SufferPlayerAbnormalCondition(kvp.Key, int.Parse(kvp.Value)); break; + case CardFunction.doublebleedDamage: + doubleBleedDamage(); + break; case CardFunction.discard: + LegacyManager.Instance.tryUseLegacy(Name.Legacy.LegacyNode_WasteReconstructor); + LegacyManager.Instance.tryUseLegacy(Name.Legacy.LegacyNode_BigBackpack); yield return StartCoroutine(TurnMaster.Instance.randomDiscard(int.Parse(kvp.Value))); //yield return StartCoroutine(TurnMaster.Instance.MoveCards()); /*yield return new WaitForEndOfFrame(); @@ -766,6 +1025,39 @@ public class SettlementManager : Singleton case CardFunction.bleed: abnormalConditionWork(kvp.Value, int.Parse(kvp.Value), influencePreviewPool); break; + case CardFunction.turnRedNodesToBleed: + HashSet targetRedNodes = new HashSet { GameManager.Instance.playerOn }; + HashSet targetNodes = new HashSet { GameManager.Instance.playerOn }; + getNodeTools.getCircleNode(targetRedNodes, 2); + getNodeTools.getCircleNode(targetNodes, 1); + int bleedCount = 0; + foreach (MapUnity mapUnity in targetRedNodes) + { + if (Name.NodeColor.PlayerColor.Contains(mapUnity.whoColour)) + { + bleedCount++; + mapUnity.switchColor(Name.NodeColor.White); + } + + } + abnormalConditionWork(AbnormalCondition.bleed, bleedCount, new List(targetNodes)); + break; + case CardFunction.turnRedNodesToBleedInTwoCirCle: + HashSet targetRedNodesA = new HashSet { GameManager.Instance.playerOn }; + HashSet targetNodesA = new HashSet { GameManager.Instance.playerOn }; + getNodeTools.getCircleNode(targetRedNodesA, 2); + getNodeTools.getCircleNode(targetNodesA, 2); + int bleedCountA = 0; + foreach (MapUnity mapUnity in targetRedNodesA) + { + if (Name.NodeColor.PlayerColor.Contains(mapUnity.whoColour)) + { + bleedCountA++; + mapUnity.switchColor(Name.NodeColor.White); + } + } + abnormalConditionWork(AbnormalCondition.bleed, bleedCountA, new List(targetNodesA)); + break; } } @@ -802,7 +1094,7 @@ public class SettlementManager : Singleton { Dictionary trueFunctionVal = new Dictionary(); - trueFunctionVal.AddRange(cardOriginalData.testTrueFunctionVal); + trueFunctionVal.AddRange(cardOriginalData.TrueFunctionVal); Usermanager.Instance.expectDamage = 0; foreach (KeyValuePair kvp in trueFunctionVal) { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/Usermanager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/Usermanager.cs index 1dca0ed3..b1c9d1c0 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/Usermanager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/Usermanager.cs @@ -123,6 +123,13 @@ public class Usermanager : Singleton float trueHp = Math.Min(recoverHp, GameManager.Instance.playerState.maxHP); GameManager.Instance.playerState.currentHP = trueHp; } + + public void lostHp(int val) + { + float trueHp = GameManager.Instance.playerState.currentHP-val; + GameManager.Instance.playerState.currentHP = trueHp; + checkDeath(); + } public void SufferPlayerAbnormalCondition(string condition, int value) { if (immunityCal(condition,value)) @@ -311,7 +318,6 @@ public class Usermanager : Singleton AbnormalConditionEndCheck(); RefreshPlayerBuffIcon(); } - } public void PlayerTurnBeginSettle() @@ -355,6 +361,10 @@ public class Usermanager : Singleton { if (playerAbnormalCondition[key].CheckValue() <= 0) { + if(playerAbnormalCondition[key].Equals(AbnormalCondition.tempEmberOneRound)|| playerAbnormalCondition[key].Equals(AbnormalCondition.tempEmberOneRound)) + { + //SufferPlayerAbnormalCondition(AbnormalCondition.angerUpperDamage + } playerAbnormalCondition.Remove(key); } } @@ -446,9 +456,18 @@ public class Usermanager : Singleton //死亡 if(GameManager.Instance.playerState.currentHP<=0) { - GameManager.Instance.DeathPanel.SetActive(true); - HideUIBarManager.Instance.HideUIBar(); + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_AegisOfTheImmortal)) + { + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_AegisOfTheImmortal].Use(); + } + else + { + GameManager.Instance.DeathPanel.SetActive(true); + HideUIBarManager.Instance.HideUIBar(); + } + } + } public void SufferDamage(int damage,EnemyNode enemyNode) @@ -456,7 +475,7 @@ public class Usermanager : Singleton if (MapUnityManager.Instance.isPlayerOn(Name.NodeColor.Blue)) { damage -= 2; - MathTool.keepNature(damage); + MathTool.keepNature(ref damage); } if (enemyNode != null) { @@ -478,12 +497,29 @@ public class Usermanager : Singleton { shield -= trueDamage; } + checkDeath(); + + } + + public void checkDeath() + { //死亡 if (GameManager.Instance.playerState.currentHP <= 0) { - GameManager.Instance.DeathPanel.SetActive(true); - HideUIBarManager.Instance.HideUIBar(); + if (GameManager.Instance.playerState.currentHP <= 0) + { + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_AegisOfTheImmortal)) + { + LegacyManager.Instance.legacyNodesList[Name.Legacy.LegacyNode_AegisOfTheImmortal].Use(); + } + else + { + GameManager.Instance.DeathPanel.SetActive(true); + HideUIBarManager.Instance.HideUIBar(); + } + + } } } @@ -531,6 +567,10 @@ public class Usermanager : Singleton { angerUpperDamage = playerAbnormalCondition[AbnormalCondition.angerUpperDamage].value; } + if (LegacyManager.Instance.isUseful(Name.Legacy.LegacyNode_ChaosTrigger)) + { + damage += 2; + } if(playerAbnormalCondition.ContainsKey(AbnormalCondition.weak)) { damagemultiply = 0.75f; @@ -539,7 +579,7 @@ public class Usermanager : Singleton damagemultiply = 1f; } damage = (int)((damage + angerUpperDamage ) * damagemultiply); - MathTool.keepNature(damage); + MathTool.keepNature(ref damage); return damage; } @@ -553,9 +593,14 @@ public class Usermanager : Singleton { shieldValue += playerAbnormalCondition[AbnormalCondition.shieldUpperValue].value; } + shield += shieldValue; - MathTool.keepNature(shield); + if (playerAbnormalCondition.ContainsKey(AbnormalCondition.cantShield)) + { + shield = 0; + } + MathTool.keepNature(ref shield); return shield; } @@ -581,7 +626,7 @@ public class Usermanager : Singleton stepRangeMultiply = 1f; } stepRange = (int)((stepRange + addStepRange) *stepRangeMultiply); - MathTool.keepNature(stepRange); + MathTool.keepNature(ref stepRange); return stepRange; } //受伤计算函数 diff --git a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/Relic.csv b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/Relic.csv index 294419a9..a8929dde 100644 --- a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/Relic.csv +++ b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/Relic.csv @@ -1,8 +1,23 @@ -锘1001,LegacyNode_AgnisTorch,RelicsIcon/LegacyNode_AgnisTorch,闃胯嗗凹鐨勭伀鐐,鐏瑙﹀彂鏀逛负8灞傦紝涓庢矁鑲殑閿ゅ瓙浜掔浉鏇挎崲 -1002,LegacyNode_VulcanHammer,RelicsIcon/LegacyNode_VulcanHammer,娌冭偗鐨勯敜瀛,鐏瑙﹀彂鏀逛负15灞傦紝瑙﹀彂浼ゅ鏀逛负25锛屼笌闃胯嗗凹鐨勭绂忎簰鐩告浛鎹 -1003,LegacyNode_AncientSilverCoin,RelicsIcon/LegacyNode_AncientSilverCoin,鍙よ侀摱甯,绗竴鍥炲悎棰濆鎷ユ湁1鐐硅垂鐢 -1004,LegacyNode_EnchantedConch,RelicsIcon/LegacyNode_EnchantedConch,绁炲娴疯灪,閫氳繃娼箍瑙﹀彂鐪╂檿鏃跺欙紝棰濆闄勫姞涓灞傛槗浼 -1005,LegacyNode_GoldVines,RelicsIcon/LegacyNode_GoldVines,榛勯噾钘ゆ浖,姣忓綋鑾峰緱閲戝竵鏃讹紝鎭㈠2鐐圭敓鍛藉 -1006,LegacyNode_Starfish,RelicsIcon/LegacyNode_Starfish,娴锋槦,钃濊壊鐨勫垽瀹氬鏉1 -1007,LegacyNode_SuspiciousMushroom,RelicsIcon/LegacyNode_SuspiciousMushroom,鍙枒鐨勮槕鑿,杩涜缁胯壊鏌撹壊鐨勬椂鍊欏鎬墿鏂藉姞涓灞備腑姣 -1008,LegacyNode_SnakeGall,RelicsIcon/LegacyNode_SnakeGall,铔囪儐,濡傛灉鎬墿甯︾潃瓒呰繃10灞備腑姣掓鍘伙紝閭d箞鐜╁鍥炲1鐐圭敓鍛 +锘5001,LegacyNode_BloodBorne,RelicsIcon/LegacyNode_AgnisTorch,椴滆鍦f澂,绾㈣鏀瑰彉棰滆壊鏃讹紝瀵瑰綋鍓嶅湴鍧楁柦鍔4灞傛祦琛 +5002,LegacyNode_WasteReconstructor,RelicsIcon/LegacyNode_VulcanHammer,搴熺墿鍐嶇敓鍣,姣忔湁鍗$墝琚涪寮冩椂锛屽湪闅忔満鏁屼汉鑴氫笅鐢熸垚绾 +5003,LegacyNode_BloodTax,RelicsIcon/LegacyNode_AncientSilverCoin,琛绋,姣忔湁涓涓崟浣嶆浜★紝娴佽浼ゅ+1 +5004,LegacyNode_Parasol,RelicsIcon/LegacyNode_EnchantedConch,闃充紴,"鐜╁鍥炲悎娑傝壊鏍兼暟>9,鑾峰緱7鐐规姢鐩" +5005,LegacyNode_Sneakers,RelicsIcon/LegacyNode_GoldVines,杩愬姩闉,姣忓綋鏈夊崟浣嶆浜★紝绉诲姩鍔涙仮澶嶈嚦涓婇檺锛1鍥炲悎鍙Е鍙戜竴娆 +5007,LegacyNode_BigBackpack,RelicsIcon/LegacyNode_Starfish,澶ц儗鍖,姣忎涪寮冧竴寮犵墝鑾峰緱3鐐规姢鐢 +5008,LegacyNode_FreeBullet,RelicsIcon/LegacyNode_SuspiciousMushroom,鍏嶈垂瀛愬脊,绗5娆¢噴鏀剧殑娑傝壊鐗屾秷鑰椾负0 +5009,LegacyNode_PlatedSteelcaps,RelicsIcon/LegacyNode_SuspiciousMushroom,甯冪敳闉,姣忕Щ鍔1鏍硷紝鑾峰緱3鐐规姢鐩 +5010,LegacyNode_Cheese,RelicsIcon/LegacyNode_SuspiciousMushroom,濂堕叒,璐拱鏃舵仮澶30鐐圭敓鍛藉 +5011,LegacyNode_AegisOfTheImmortal,RelicsIcon/LegacyNode_SuspiciousMushroom,涓嶆溄涔嬪畧鎶,褰撲綘姝讳骸鏃讹紝鍏嶆鎭㈠30%鐢熷懡鍊硷紝鏁堟灉娑堝け +5012,LegacyNode_SpeedLoader,RelicsIcon/LegacyNode_SuspiciousMushroom,鍙屽彂瑁呭~鍣,姣10寮犳晥鏋滅墝灏嗘墦鍑2娆 +5013,LegacyNode_LightningBoots,RelicsIcon/LegacyNode_SuspiciousMushroom,闂數闈,鍚屼竴鍥炲悎鎵撳嚭3寮犳晥鏋滅墝鑾峰緱2鐐圭Щ鍔ㄥ姏 +5015,LegacyNode_MeatSaw,RelicsIcon/LegacyNode_SuspiciousMushroom,鑲夐敮,娴佽瑙﹀彂娑堣椾袱灞 +5016,LegacyNode_Prism,RelicsIcon/LegacyNode_SuspiciousMushroom,涓夋1闀,鍦轰笂鍚屾椂瀛樺湪涓夌鍙嬫柟棰滆壊锛屾秱鑹茬墝璐圭敤-1 +5017,LegacyNode_Bipod,RelicsIcon/LegacyNode_SuspiciousMushroom,涓よ剼鏋,鏈洖鍚堟湭绉诲姩锛屼笅鍥炲悎鏂芥硶璺濈+4 +5018,LegacyNode_ActivatedCarbon,RelicsIcon/LegacyNode_SuspiciousMushroom,娲绘х偔,鍑昏触涓涓晫浜哄悗锛屽皢鏁屼汉鑴氫笅鐨勮壊鍧楁案涔呬繚鐣欐棤娉曟秱鑹 +5019,LegacyNode_PerpetualMotionPump,RelicsIcon/LegacyNode_SuspiciousMushroom,姘稿姩娉,鍥炲悎缁撴潫鏃讹紝鑳介噺鏈楀敖锛屽皢鍓╀綑鑳介噺杞寲涓轰笅鍥炲悎涓存椂鑳介噺 +5021,LegacyNode_PortableReactor,RelicsIcon/LegacyNode_SuspiciousMushroom,渚挎惡寮忓弽搴斿爢,姣忔湁涓寮犵墝琚秷鑰楋紝鎶藉彇涓寮犵墝 +5022,LegacyNode_ChaosTrigger,RelicsIcon/LegacyNode_SuspiciousMushroom,娣锋矊鏉挎満,鏈洖鍚堟秱鍑3绉嶉鑹诧紝鑾峰緱2灞備复鏃剁媯鐑 +5024,LegacyNode_Filter,RelicsIcon/LegacyNode_SuspiciousMushroom,杩囨护缃,姣忔竻闄1鍧楁薄鏌撳湴鍧楄幏寰1鐐规姢鐩 +5025,LegacyNode_NurturingBloom,RelicsIcon/LegacyNode_SuspiciousMushroom,婊嬪吇涔嬭姳,鍥炲悎缁撴潫鏃剁珯鍦ㄦ薄鏌撳湴鍧椾笂锛岃幏寰2灞傜媯鐑紝澶卞幓5鐐圭敓鍛 +5026,LegacyNode_PurityBadge,RelicsIcon/LegacyNode_SuspiciousMushroom,鍑鍖栧窘绔,娓呴櫎鍦板潡鏃讹紝瀵规墍鏈夋晫浜洪犳垚4鐐逛激瀹 +5027,LegacyNode_PainContract,RelicsIcon/LegacyNode_SuspiciousMushroom,鑻︾棝濂戠害,鍥炲悎寮濮嬫椂锛屽け鍘2鐐圭敓鍛斤紝瀵瑰懆鍥1鑼冨洿闅忔満鏌撹壊 diff --git a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv deleted file mode 100644 index 2c534d39..00000000 --- a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv +++ /dev/null @@ -1,4 +0,0 @@ -锘縄D,璐圭敤绫诲瀷,璐圭敤,鏂芥硶鑼冨洿,浣滅敤鑼冨洿,鏉′欢,鍔熻兘,鏁板,鍦板潡鏍囪,鍦板潡棰滆壊,鍥剧墖璺緞,鍚嶇О -1001,1,1,2,3_1,none,1,5,0_0;1_0;2_0,white;white;white,CardIcon/1010,灏勫嚮 -1002,1,1,2,3_1,none,2,4,0_0;-1_1;-1_-1,white;white;white,CardIcon/1010,灞忛殰 -1003,1,1,2,3_1,none,,,0_0;1_0;2_0;3_0;4_0,white;white;white;white;white,CardIcon/1010,鍠峰皠 diff --git a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv new file mode 100644 index 00000000..7b350999 --- /dev/null +++ b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv @@ -0,0 +1,16 @@ +锘縄D,璐圭敤绫诲瀷,璐圭敤,鏂芥硶鑼冨洿,浣滅敤鑼冨洿,鏉′欢,鍔熻兘,鏁板,鍦板潡鏍囪,鍦板潡棰滆壊,鍥剧墖璺緞,鍚嶇О,绋鏈夊害 +1001,1,1,1,3_1,none,1,5,0_0;1_0;2_0,white;white;white,CardIcon/1010,鎸ョ爫,1 +1002,1,1,1,3_1,none,2,4,0_0;-1_1;-1_-1,white;white;white,CardIcon/1010,鏍兼尅,1 +1003,1,1,1,3_1,none,40,1,1_0;0_1;0_-1;-1_0;-1_1;-1_-1,white;white;white;white;white;white,CardIcon/1010,鐑熷湀,1 +1004,1,2,1,3_1,none,12_13,2_2,0_0;1_0;0_-1;0_1,blue;blue;red;red,CardIcon/1011,鎼滅储,1 +1005,1,1,1,3_1,none,1_12,8_1,1_0;0_1;0_-1;-1_0;-1_1;-1_-1,red;red;red;red;red;red,CardIcon/1012,鍒鎵,2 +1006,1,0,1,3_1,none,13,2,1_0;0_-1;0_1;2_0;1_-1;1_1,red;red;red;blue;blue;blue,CardIcon/1013,鍠峰悙,2 +1009,1,1,1,3_1,none,23,1,0_0;1_0;2_0,yellow;yellow;yellow,CardIcon/1016,绐佸埡,2 +1010,1,2,1,3_1,none,19,2,0_0;1_0;2_0;1_1;1_-1,blue;blue;blue;blue;blue,CardIcon/1017,閲嶉敜,1 +1011,1,1,1,3_1,none,5,1,0_0;1_0;2_0;3_0;4_0,blue;blue;blue;blue;blue,CardIcon/1018,闀块灜,2 +1012,1,0,1,3_1,none,none,none,0_0;1_0;0_1,yellow;red;blue,CardIcon/1019,褰╃悆,1 +1013,1,2,1,3_1,none,2,10,1_0;0_-1;0_1;2_0;1_-1;1_1;3_0;2_1;2_-1,red;red;red;blue;blue;blue;yellow;yellow;yellow,CardIcon/1020,涔濆鏍,2 +1014,1,2,1,3_1,none,1,7,0_0;1_0;2_0;-1_1;-1_2;-2_3;-1_-1;-2_-2;-3_-3,red;red;red;yellow;yellow;yellow;blue;blue;blue,CardIcon/1021,涓夎壊绾,2 +1016,1,1,1,3_1,none,53,2鏈3鏃,0_0;1_0;2_0;0_1;0_-1;1_2;1_-2,red;red;red;red;red;red;red,CardIcon/1021,鏁e皠,1 +1017,1,2,1,3_1,none,17,1,0_0;1_0;2_0;3_0;2_1;2_-1;2_2;2_-2,blue;blue;blue;blue;blue;blue;blue;blue,CardIcon/1021,鍗曞悜绠ご,2 +1007,1,3,1,3_1,none,1,32,0_0;1_0;0_1;0_-1;1_1;1_-1;1_2;1_-2,black;black;black;black;black;black;black;black,CardIcon/1021,榛戠伀鑽,3 diff --git a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv.meta b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv.meta similarity index 74% rename from ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv.meta rename to ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv.meta index d74d6715..b5595ee7 100644 --- a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_4 - 鍓湰.csv.meta +++ b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_5.csv.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 0c939aa3ecbdd9c44b6b59502ed35b35 +guid: a47fc21bae9906a47bf4ab3d37735b1a DefaultImporter: externalObjects: {} userData: diff --git a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_effect_4.csv b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_effect_4.csv index 1e46fb9e..44fb14bf 100644 --- a/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_effect_4.csv +++ b/ColorlessWorld-2024-4-2/Assets/StreamingAssets/card_data_effect_4.csv @@ -1,3 +1,33 @@ -锘縄D,娑堣楃被鍨,娑堣楁暟鍊,鏉′欢,鍔熻兘,鏁板,鍦板潡鏍囪,鍥剧墖璺緞,鏂芥硶鑼冨洿 -2001,1,1,none,49,1,0_0,CardIcon/1010,2 -2002,1,1,none,40_50,-2_4,none,CardIcon/1010,0 +锘縄D,娑堣楃被鍨,娑堣楁暟鍊,鍩虹鍔熻兘,鏁板,鏉′欢,浜掓枼鍔熻兘,鏁板,鍦板潡鏍囪,鍥剧墖璺緞,鏂芥硶鑼冨洿,绋鏈夊害,娑堣,鍚嶅瓧 +2006,1,2,54,9,red>9,55,3,0_0,CardIcon/1010,0,2,0,琛灞 +2014,1,1,57,4,blue>9,57,2,0_0,CardIcon/1010,0,2,0,鍓茶 +2026,1,1,40,2,blue>5,16,1,0_0,CardIcon/1010,0,2,0,鐤捐窇 +2029,1,1,59,1,blue>11,60,1,0_0,CardIcon/1010,0,2,1,鏆撮鍚稿叆 +2030,1,1,60,1,yellow>10,61,1,0_0,CardIcon/1010,0,2,0,姹插彇 +2032,1,2,49,1,none,none,none,0_0,CardIcon/1010,1,1,0,鐐圭紑 +2034,1,1,63,1,none,none,none,0_0,CardIcon/1010,1,2,0,鐩惧嚮 +2035,1,1,1,7,none;blue>9,64;64,8;10,0_0,CardIcon/1010,1,1,0,鎾曟壇 +2036,1,1,65,5,none;yellow>10,66;67,1;1,0_0,CardIcon/1010,1,3,1,琛铔 +2037,1,2,18,1,red>9,33,1,0_0,CardIcon/1010,0,2,1,鐩惧瀿 +2039,1,0,65,5,none;red>19,11;11,2;3,0_0,CardIcon/1010,0,3,1,鎴樺惣 +2023,1,1,none,none,none;yellow>5,52;52,2;3,0_0,CardIcon/1010,1,1,0,韪㈠嚮 +2022,1,3,none,none,none;red>5,68;69,1;1,0_0,CardIcon/1010,1,3,0,鎶借 +2019,1,3,none,none,none;red>12,1;53,10;5-2,0_0,CardIcon/1010,1,2,0,褰辫垶姝 +2004,1,3,71,1,none;red>10,70;70,2;1,0_0,CardIcon/1010,0,3,0,琛鐩 +2002,1,2,none,none,none;blue>10,72;73,1;1,0_0,CardIcon/1010,0,2,0,鐚╃孩椋庢毚 +2003,1,1,none,none,none;red>9,74;74,2;3,0_0,CardIcon/1010,1,2,1,琛鐤 +2007,1,2,none,none,none;red>12,75;76,1;1,0_0,CardIcon/1010,0,2,1,璧嬭兘 +2012,1,1,40;50,-1;2,none,none,none,0_0,CardIcon/1010,0,1,0,鍐烽潤 +2015,1,2,none,none,none;yellow>4,1;53,15;5-3,0_0,CardIcon/1010,1,3,0,宸﹀彸寮寮 +2027,1,2,none,none,none;blue>10,5_58;5_58,2_2;3_3,0_0,CardIcon/1010,1,2,0,绌疯拷鐚涚爫 +2024,1,1,none,none,none;red>10,52;52,1;2,0_1;1_0;0_-1;-1_0;-1_1;-1_-1,CardIcon/1010,0,1,0,灞曠繀 +2001,1,0,77,1,red>8,78,1,0_0,CardIcon/1010,0,1,0,琛绁 +2005,1,1,79;80,1;1,yellow>11,33,1,0_0,CardIcon/1010,0,2,0,绛変环浠f崲 +2009,1,0,11;81,1;1,none,none,none,0_0,CardIcon/1010,0,1,1,鐜懓鑼 +2008,1,1,56,2,none;yellow>4,13;none,1;none,0_0,CardIcon/1010,0,1,0,鐐奸噾灏忓寘 +2016,1,1,82,1,none,none,none,0_0,CardIcon/1010,0,3,1,娑堝け +2017,1,1,83,3,yellow>4,86,1,0_0,CardIcon/1010,1,3,0,姝讳骸鍗拌 +2018,1,1,84;85,1;1,yellow>5,33,1,0_0,CardIcon/1010,1,2,0,鏆楀奖姝 +2021,1,1,90,1,blue>7,89,1,0_0,CardIcon/1010,0,3,1,琛鎬 +2028,1,1,none,none,none;aroundblue=4,53;53,6-2;6-4,0_1;1_0;0_-1;-1_0;-1_1;-1_-1,CardIcon/1010,1,3,0,鍓戝垉椋庢毚 +2031,1,0,none,none,none;red>9,12;91,1;1,0_0,CardIcon/1010,0,2,0,鍐嶆潵涓鏉 diff --git a/ColorlessWorld-2024-4-2/obj/Debug/Assembly-CSharp-Editor.csproj.AssemblyReference.cache b/ColorlessWorld-2024-4-2/obj/Debug/Assembly-CSharp-Editor.csproj.AssemblyReference.cache index 74a3362c..2385357c 100644 Binary files a/ColorlessWorld-2024-4-2/obj/Debug/Assembly-CSharp-Editor.csproj.AssemblyReference.cache and b/ColorlessWorld-2024-4-2/obj/Debug/Assembly-CSharp-Editor.csproj.AssemblyReference.cache differ