0
0
Fork 0
mirror of https://github.com/liabru/matter-js.git synced 2024-11-27 09:50:52 -05:00

fixed removal bug in pair manager

This commit is contained in:
liabru 2014-03-14 16:11:04 +00:00
parent cab5091212
commit 9153c7b836

View file

@ -109,7 +109,7 @@ var Manager = {};
// remove marked pairs // remove marked pairs
for (i = 0; i < indexesToRemove.length; i++) { for (i = 0; i < indexesToRemove.length; i++) {
pairIndex = indexesToRemove[i]; pairIndex = indexesToRemove[i] - i;
pair = pairsList[pairIndex]; pair = pairsList[pairIndex];
delete pairsTable[pair.id]; delete pairsTable[pair.id];
pairsList.splice(pairIndex, 1); pairsList.splice(pairIndex, 1);