Fix bug in Tadpoles example.

Fixes a bug where the segments array of a path was being changed directly, which caused the bounds to not be updated.
This commit is contained in:
Jonathan Puckey 2012-11-22 19:20:30 +01:00
parent 1f5af06e74
commit d12c680be6

View file

@ -78,9 +78,7 @@
this.head.rotate(rot - this.lastRot);
this.lastRot = rot;
var shortSegments = this.shortPath.segments;
for (var i = 0; i < 3; i++)
shortSegments[i] = segments[i].clone();
this.shortPath.segments = segments.slice(0, 3);
},
// We accumulate a new acceleration each time based on three rules