添加addSubPlayer默认继承原武将name属性

This commit is contained in:
mengxinzxz 2024-05-22 20:07:36 +08:00
parent a4f3493a36
commit 314d383093
1 changed files with 1 additions and 1 deletions

View File

@ -7329,7 +7329,7 @@ export class Player extends HTMLDivElement {
subplayer: true, subplayer: true,
}, },
}; };
lib.character[skill] = [cfg.sex, cfg.group, parseFloat(cfg.hp) + "/" + parseFloat(cfg.maxHp) + "/" + parseFloat(cfg.hujia), cfg.skills, lib.character[cfg.name].trashBin || []]; lib.character[skill] = [cfg.sex, cfg.group, parseFloat(cfg.hp) + "/" + parseFloat(cfg.maxHp) + "/" + parseFloat(cfg.hujia), cfg.skills, ["tempname:" + cfg.name].concat(lib.character[cfg.name].trashBin || [])];
if (Array.isArray(cfg.image)) { if (Array.isArray(cfg.image)) {
cfg.image.forEach(image => lib.character[skill][4].push(image)); cfg.image.forEach(image => lib.character[skill][4].push(image));
} else if (typeof cfg.image == "string") { } else if (typeof cfg.image == "string") {