mirror of
https://github.com/IvarK/AntimatterDimensionsSourceCode.git
synced 2024-11-10 06:02:13 +00:00
Fix bugs with EC! and respec+load
This commit is contained in:
parent
561c8cfc9c
commit
d0a167a5fd
@ -177,8 +177,7 @@ export default {
|
||||
if (this.respecAndLoad && Player.canEternity) {
|
||||
player.respec = true;
|
||||
const tree = new TimeStudyTree(this.truncatedInput);
|
||||
animateAndEternity(() =>
|
||||
TimeStudyTree.commitToGameState(tree.purchasedStudies, false, this.combinedTree.startEC));
|
||||
animateAndEternity(() => TimeStudyTree.commitToGameState(tree.purchasedStudies, false, tree.startEC));
|
||||
return;
|
||||
}
|
||||
this.importTree();
|
||||
|
@ -240,7 +240,8 @@ export class TimeStudyTree {
|
||||
if (checkOnlyStructure) {
|
||||
return reqSatisfied && !hasForbiddenStudies;
|
||||
}
|
||||
const hasEnoughTT = Currency.timeTheorems.value.subtract(this.spentTheorems[0]).gte(study.cost);
|
||||
const totalTT = player.timestudy.theorem.plus(TimeTheorems.calculateTimeStudiesCost());
|
||||
const hasEnoughTT = totalTT.subtract(this.spentTheorems[0]).gte(study.cost);
|
||||
const secondaryGoal = Perk.studyECRequirement.isBought || study.isEntryGoalMet;
|
||||
return reqSatisfied && !hasForbiddenStudies && (study.isBought || (secondaryGoal && hasEnoughTT));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user