Fix bug in history restoring where the lastActiveIndex is not updated leading to incomplete restoring

This commit is contained in:
Simon Robertshaw 2012-08-27 13:33:15 +01:00
parent 0ca680f4c8
commit dd2fc64793

View File

@ -238,7 +238,7 @@ Snapshot * Simulation::CreateSnapshot()
void Simulation::Restore(const Snapshot & snap)
{
parts_lastActiveIndex = NPART-1;
parts_lastActiveIndex = NPART-1;
std::copy(snap.AirPressure.begin(), snap.AirPressure.end(), &pv[0][0]);
std::copy(snap.AirVelocityX.begin(), snap.AirVelocityX.end(), &vx[0][0]);
std::copy(snap.AirVelocityY.begin(), snap.AirVelocityY.end(), &vy[0][0]);