Remove ref passing, but keep devirtualizations

This commit is contained in:
Asriel Camora
2024-03-16 13:24:26 -07:00
parent 3223bdcbfb
commit ec77f1d021
48 changed files with 411 additions and 787 deletions
+9 -23
View File
@@ -1,28 +1,14 @@
namespace Craftimizer.Simulator.Actions;
internal sealed class RapidSynthesis : BaseAction
internal sealed class RapidSynthesis() : BaseAction(
ActionCategory.Synthesis, 9, 100363,
increasesProgress: true,
defaultCPCost: 0,
defaultEfficiency: 250,
defaultSuccessRate: 0.50f
)
{
public RapidSynthesis()
{
Category = ActionCategory.Synthesis;
Level = 9;
ActionId = 100363;
IncreasesProgress = true;
}
public override void CPCost(Simulator s, ref int cost)
{
cost = 0;
}
// Rapid Synthesis Mastery Trait
public override void Efficiency(Simulator s, ref int eff)
{
eff = s.Input.Stats.Level >= 63 ? 500 : 250;
}
public override void SuccessRate(Simulator s, ref float success)
{
success = 0.50f;
}
public override int Efficiency(Simulator s) =>
s.Input.Stats.Level >= 63 ? 500 : 250;
}