mirror of
https://github.com/VickScarlet/lifeRestart.git
synced 2026-04-10 09:59:00 +08:00
change talent replace before property allocate
This commit is contained in:
@@ -41,9 +41,11 @@ export default class Property extends ui.view.DefaultTheme.PropertyUI {
|
||||
|
||||
init({talents}) {
|
||||
this.listSelectedTalents.array = talents;
|
||||
const talentIds = talents.map(talent => talent.id);
|
||||
// core.talentReplace(talentIds);
|
||||
this.#propertyPoints = core.getPropertyPoints(talentIds);
|
||||
const replace = core.remake(talents.map(talent => talent.id));
|
||||
if(replace.length > 0) {
|
||||
$$event('message', [replace.map(v => ['F_TalentReplace', v])]);
|
||||
}
|
||||
this.#propertyPoints = core.getPropertyPoints();
|
||||
this.#propertyAllocateLimit = core.propertyAllocateLimit;
|
||||
this.labLeftPropertyPoint.text = this.#propertyPoints;
|
||||
this.#propertyAllocate = {
|
||||
@@ -51,7 +53,6 @@ export default class Property extends ui.view.DefaultTheme.PropertyUI {
|
||||
[this.#types.INT]: 0,
|
||||
[this.#types.STR]: 0,
|
||||
[this.#types.MNY]: 0,
|
||||
[this.#types.TLT]: talentIds,
|
||||
}
|
||||
this.updateAllocate();
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ export default class Trajectory extends ui.view.DefaultTheme.TrajectoryUI {
|
||||
this.#trajectoryItems = [];
|
||||
this.#isEnd = false;
|
||||
this.#talents = talents;
|
||||
core.restart(propertyAllocate);
|
||||
core.start(propertyAllocate);
|
||||
this.updateProperty();
|
||||
this.onNext();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user