默认无法反击,增加允许反击状态

This commit is contained in:
xianyi
2025-09-01 11:30:21 +08:00
parent 4e05e3d87f
commit 4adfba03f3
9 changed files with 126 additions and 5 deletions

View File

@@ -0,0 +1,38 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 8ce5f81e5cc37f547af6923758602c8c, type: 3}
m_Name: activate_counterattack_2turns
m_EditorClassIdentifier:
id: activate_counterattack_2turns
trigger: 5
conditions_trigger: []
target: 1
conditions_target: []
filters_target: []
effects:
- {fileID: 11400000, guid: 4c4c317ae3dd4cf4982e8d7c7f1043b9, type: 2}
status:
- {fileID: 11400000, guid: e536240f3421c48a49c3ef0eb19b1042, type: 2}
value: 0
duration: 2
chain_abilities: []
mana_cost: 3
exhaust: 0
board_fx: {fileID: 0}
caster_fx: {fileID: 0}
target_fx: {fileID: 0}
projectile_fx: {fileID: 0}
cast_audio: {fileID: 0}
target_audio: {fileID: 0}
charge_target: 0
title: "\u5141\u8BB8\u53CD\u51FB"
desc: "\u5141\u8BB8\u53CD\u51FB \u6301\u7EED2\u56DE\u5408"

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a7e1a976297b94e0b935f5e6126d8d11
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,37 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 8ce5f81e5cc37f547af6923758602c8c, type: 3}
m_Name: alwaysCounterattack
m_EditorClassIdentifier:
id: alwaysCounterattack
trigger: 2
conditions_trigger: []
target: 1
conditions_target: []
filters_target: []
effects: []
status:
- {fileID: 11400000, guid: e536240f3421c48a49c3ef0eb19b1042, type: 2}
value: 0
duration: 0
chain_abilities: []
mana_cost: 0
exhaust: 0
board_fx: {fileID: 0}
caster_fx: {fileID: 0}
target_fx: {fileID: 0}
projectile_fx: {fileID: 0}
cast_audio: {fileID: 0}
target_audio: {fileID: 0}
charge_target: 0
title: "\u59CB\u7EC8\u53CD\u51FB"
desc: "\u59CB\u7EC8\u53CD\u51FB"

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: f2db8435fd93e4777a91deee49c478b4
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,20 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 7edf116efdfa73646a6de43812f81a4a, type: 3}
m_Name: counterattack
m_EditorClassIdentifier:
effect: 38
title: counterattack
icon: {fileID: 0}
desc: "\u5141\u8BB8\u53CD\u51FB"
status_fx: {fileID: 0}
hvalue: 1

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: e536240f3421c48a49c3ef0eb19b1042
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -32,8 +32,7 @@ namespace TcgEngine
Paralysed = 32, //Cant do any actions for X turns
Poisoned = 34, //Lose hp each start of turn
Sleep = 36, //Doesnt untap at the start of turn
Counterattack = 38, // 允许反击
}
/// <summary>

View File

@@ -569,7 +569,10 @@ namespace TcgEngine.Gameplay
DamageCard(attacker, target, datt1);
//Counter Damage
if (!attacker.HasStatus(StatusType.Intimidate))
// if (!attacker.HasStatus(StatusType.Intimidate)) // 威慑时不会反击
// DamageCard(target, attacker, datt2);
if (attacker.HasStatus(StatusType.Counterattack)) // 允许反击
DamageCard(target, attacker, datt2);
//Save attack and exhaust

View File

@@ -117,10 +117,10 @@ namespace TcgEngine
return false;
}
Debug.Log($"版本匹配开始检查MD5校验... 当前版本: {currentVersion} 目标版本: {targetVersion} 当前MD5: {currentMd5} 目标MD5: {targetMd5}");
string localMd5 = await CalculateDirectoryMd5(spritesPath);
Debug.Log($"版本匹配开始检查MD5校验... 当前版本: {currentVersion} 目标版本: {targetVersion} 当前MD5: {localMd5} 目标MD5: {targetMd5}");
if (localMd5 != targetMd5)
{
Debug.Log("MD5校验失败正在删除损坏的文件并重新下载...");