Fix single steps not updating simulation

This commit is contained in:
Unknown 2018-10-18 11:04:23 +02:00
parent de1aa46743
commit c3244b085e
1 changed files with 1 additions and 2 deletions

View File

@ -101,7 +101,6 @@ class Engine {
/// directly, since it is automatically taken care of by the processing function.
/// If simulation should be advanced manually one time, prefer using step().
void update() {
// TODO: create hasUpdated/hasAdvanced method in simulation to abstract actual updating away
Map<int, bool> simulationUpdate = _simulation.update();
_simulation.mergeStateChanges(simulationUpdate);
@ -114,8 +113,8 @@ class Engine {
/// simulation. Does not automatically re-render the new state
/// (though this should usually not pose a problem).
void step() {
update();
running = false;
_simulation.update();
}
/// Renders the Current Simulation State