备份,准备做双端

This commit is contained in:
2026-07-30 23:15:58 +08:00
parent add675e45d
commit ec4ec53545
88 changed files with 4050 additions and 872 deletions
@@ -171,7 +171,8 @@ public class iBudeffPrefabController : MonoBehaviour
if (enemy == null || buff == null) return;
if (!Application.isPlaying) return;
if (!IsTrackableEnemyBuff(buff)) return;
Debug.LogWarning($"[iBudeffPrefabController] Enemy buff applied: enemy={enemy.name} id={enemy.GetInstanceID()} buffId={buff.buffId} desc={buff.description} atkMult={buff.attackMultiplier} healMult={buff.healReceivedMultiplier} scoreMult={buff.scoreMultiplier}");
if (GameConfig.verboseLogs)
Debug.LogWarning($"[iBudeffPrefabController] Enemy buff applied: enemy={enemy.name} id={enemy.GetInstanceID()} buffId={buff.buffId} desc={buff.description} atkMult={buff.attackMultiplier} healMult={buff.healReceivedMultiplier} scoreMult={buff.scoreMultiplier}");
RegisterEnemyEntry(enemy, GetGroupForEnemyBuff(buff), buff.buffId, 0f, GameplayNow);
}
@@ -189,7 +190,8 @@ public class iBudeffPrefabController : MonoBehaviour
if (!Application.isPlaying) return null;
var group = GetGroupForIconType(type);
string id = Guid.NewGuid().ToString();
Debug.LogWarning($"[iBudeffPrefabController] Enemy timed effect: enemy={enemy.name} id={enemy.GetInstanceID()} type={type} value={value} duration={duration} group={group}");
if (GameConfig.verboseLogs)
Debug.LogWarning($"[iBudeffPrefabController] Enemy timed effect: enemy={enemy.name} id={enemy.GetInstanceID()} type={type} value={value} duration={duration} group={group}");
RegisterEnemyEntry(enemy, group, id, value, GameplayNow);
return id;
}
@@ -652,7 +654,9 @@ public class iBudeffPrefabController : MonoBehaviour
display.Add((Group.LuckyChance, PlayerBudeffIconType.ot_luckyChance, string.Empty, GetOrderKeyEnemy(s, Group.LuckyChance)));
}
if (hasEntries)
// 诊断日志:仅在 verboseLogs 时才拼接(尤其 GetHierarchyPath 会遍历父级构造字符串)。
// RefreshEnemy 在战斗中每次 buff/计时效果注册与注销都会触发,常开会持续产生字符串 GC。
if (hasEntries && GameConfig.verboseLogs)
{
if (display.Count == 0)
{