Optimizations (from @wolfcomp)
This commit is contained in:
@@ -2,18 +2,25 @@ namespace Craftimizer.Simulator.Actions;
|
||||
|
||||
internal sealed class Groundwork : BaseAction
|
||||
{
|
||||
public override ActionCategory Category => ActionCategory.Synthesis;
|
||||
public override int Level => 72;
|
||||
public override uint ActionId => 100403;
|
||||
public Groundwork()
|
||||
{
|
||||
Category = ActionCategory.Synthesis;
|
||||
Level = 72;
|
||||
ActionId = 100403;
|
||||
IncreasesProgress = true;
|
||||
DurabilityCost = 20;
|
||||
}
|
||||
|
||||
public override bool IncreasesProgress => true;
|
||||
public override int DurabilityCost => 20;
|
||||
public override void CPCost(Simulator s, ref int cost)
|
||||
{
|
||||
cost = 18;
|
||||
}
|
||||
|
||||
public override int CPCost(Simulator s) => 18;
|
||||
public override int Efficiency(Simulator s)
|
||||
public override void Efficiency(Simulator s, ref int eff)
|
||||
{
|
||||
// Groundwork Mastery Trait
|
||||
var ret = s.Input.Stats.Level >= 86 ? 360 : 300;
|
||||
return s.Durability < s.CalculateDurabilityCost(DurabilityCost) ? ret / 2 : ret;
|
||||
eff = s.Input.Stats.Level >= 86 ? 360 : 300;
|
||||
if (s.Durability < s.CalculateDurabilityCost(DurabilityCost))
|
||||
eff /= 2;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user