feat: 实现药水卡限时强化功能,支持自定义数值覆写
1. 新增Buff数值覆写机制,支持药水卡自定义buff效果数值 2. 重构属性计算逻辑,支持读取药水卡传递的覆写值 3. 新增多组限时强化Buff与药水卡配置 4. 优化UI数值显示,实时展示最终属性值 5. 新增多维度调试日志方便排查问题
This commit is contained in:
@@ -355,8 +355,9 @@ export class HInfoComp extends CCComp {
|
||||
}
|
||||
|
||||
// ---- 数值标签 ----
|
||||
// 攻击力显示最终值(含计时 buff 修饰),实时反映药水等限时强化
|
||||
if (this.apLabel) {
|
||||
const currentAp = Math.max(0, Math.floor(this.model.ap ?? 0));
|
||||
const currentAp = Math.max(0, Math.floor(this.model.getFinalAp()));
|
||||
const baseAp = Math.max(0, Math.floor(this.model.base_ap ?? 0));
|
||||
this.apLabel.string = `${currentAp}`;
|
||||
if (this.apPlusLabel) {
|
||||
@@ -370,7 +371,7 @@ export class HInfoComp extends CCComp {
|
||||
}
|
||||
}
|
||||
if (this.hpLabel) {
|
||||
const currentHp = Math.max(0, Math.floor(this.model.hp_max ?? 0));
|
||||
const currentHp = Math.max(0, Math.floor(this.model.getFinalHpMax()));
|
||||
const baseHp = Math.max(0, Math.floor(this.model.base_hp ?? 0));
|
||||
this.hpLabel.string = `${currentHp}`;
|
||||
if (this.hpPlusLabel) {
|
||||
|
||||
Reference in New Issue
Block a user