1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
function addConstraint(blaat) { return blaat.v1 } function ScaleConstraint() { this.direction = null this.v1 = {}; addConstraint(this); } function EqualityConstraint() { this.v1 = {}; addConstraint(this); } function deltaBlue() { new EqualityConstraint(); new ScaleConstraint(); } for (var n = 0; n<100; n++) { deltaBlue() }