fix crash when SOAP gets changed into another element, fixes #186

This commit is contained in:
jacob1 2014-04-12 15:52:12 -04:00
parent 35d97eb14d
commit 75034de5a4

View File

@ -2827,7 +2827,7 @@ int Simulation::create_part(int p, int x, int y, int tv)
} }
else if (parts[p].type == PT_SOAP) else if (parts[p].type == PT_SOAP)
{ {
detach(i); detach(p);
} }
i = p; i = p;
} }