You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think we should edit this to be the other way around, so that the solvers returned if they handle is correctly. We can either do this, or have an output doBreak bool to the solve method, so firstly we know if the solver actually executed and the second whether the solver wants us to break from all other solvers.
Something like:
private void ExecuteSolvers(IEntity entity, TileChangedArgs e)
{
foreach (ISolver solver in solvers)
{
bool dobreak;
solver.Solve(entity, e, doBreak);
if (doBreak)
{
break;
}
}
}
We could also have the return value still to do any logging, or other business that is required.
We also need to have tests written for this.
Ideas?
The text was updated successfully, but these errors were encountered:
I think we should edit this to be the other way around, so that the solvers returned if they handle is correctly. We can either do this, or have an output doBreak bool to the solve method, so firstly we know if the solver actually executed and the second whether the solver wants us to break from all other solvers.
Something like:
We could also have the return value still to do any logging, or other business that is required.
We also need to have tests written for this.
Ideas?
The text was updated successfully, but these errors were encountered: