我也不知道在做什么 反正做的东西不少....

This commit is contained in:
DESKTOP-5RP3AKU\Jisol
2023-12-01 02:08:21 +08:00
parent e73cf98ff4
commit 088e91a32b
58 changed files with 4506 additions and 122 deletions

View File

@@ -31,6 +31,20 @@ export default class GPetAttribute extends GAttributeBase{
this.attributes[attr.id] = baseAttribute[attr.sign] || 0;
});
//计算升级成长属性
let level = this.pet.petLevel; //宠物等级
let grow = TD.TbGRoleUpGrow.get(this.pet.petId) || TD.TbGRoleUpGrow.get(0); //成长
TD.TbGAttribute.getDataList().forEach(attr => {
//过滤没有的属性
if(!baseAttribute[attr.sign] || !grow[attr.sign]) return;
//计算 累加 ((base * value) * level)
this.attributes[attr.id] += (baseAttribute[attr.sign] * grow[attr.sign]) * level;
})
}
//刷新属性