Fix negative artifact point values (#15748)

This commit is contained in:
Nemanja
2023-04-25 09:18:30 -04:00
committed by GitHub
parent fda607b2f6
commit 3ee99961fd

View File

@@ -74,9 +74,8 @@ public sealed partial class ArtifactSystem : EntitySystem
var sumValue = component.NodeTree.Sum(n => GetNodePointValue(n, component, getMaxPrice));
var fullyExploredBonus = component.NodeTree.All(x => x.Triggered) || getMaxPrice ? 1.25f : 1;
sumValue -= component.ConsumedPoints;
return (int) (sumValue * fullyExploredBonus);
return (int) (sumValue * fullyExploredBonus) - component.ConsumedPoints;
}
/// <summary>