Skip to content

Commit

Permalink
Fix non-leaf recycle probability
Browse files Browse the repository at this point in the history
If the work-net cannot be found, the default 0 productivity still needs
to be passed through the hyper curve otherwise the probability of
non-leaf parts being recycled went to 1, which was not the intention
  • Loading branch information
taniwha committed Dec 15, 2020
1 parent 6a88192 commit d69e210
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Source/Recycler/StateMachine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -401,8 +401,9 @@ Part SelectPart ()
}
double prod = 0;
if (workNet != null) {
prod = ELWorkshop.HyperCurve (workNet.Productivity);
prod = workNet.Productivity;
}
prod = ELWorkshop.HyperCurve (prod);
Part p;
do {
var ar = recycle_parts.ToArray ();
Expand Down

0 comments on commit d69e210

Please sign in to comment.