Fix bug in history restoring where the lastActiveIndex is not updated leading to incomplete restoring
This commit is contained in:
parent
0ca680f4c8
commit
dd2fc64793
@ -238,7 +238,7 @@ Snapshot * Simulation::CreateSnapshot()
|
|||||||
|
|
||||||
void Simulation::Restore(const Snapshot & snap)
|
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.AirPressure.begin(), snap.AirPressure.end(), &pv[0][0]);
|
||||||
std::copy(snap.AirVelocityX.begin(), snap.AirVelocityX.end(), &vx[0][0]);
|
std::copy(snap.AirVelocityX.begin(), snap.AirVelocityX.end(), &vx[0][0]);
|
||||||
std::copy(snap.AirVelocityY.begin(), snap.AirVelocityY.end(), &vy[0][0]);
|
std::copy(snap.AirVelocityY.begin(), snap.AirVelocityY.end(), &vy[0][0]);
|
||||||
|
Loading…
Reference in New Issue
Block a user