kripken / box2d.js

Port of Box2D to JavaScript using Emscripten
1.32k stars 198 forks source link

using customizeVTable #51

Closed manideepabc closed 10 years ago

manideepabc commented 10 years ago

Box2D.customizeVTable(debugDraw, [{ original: Box2D.b2Draw.prototype.DrawSegment, replacement: function(ths, vert1, vert2, color) { alert('called'); } }]); In the above code I'm not knowing how the parameters "ths" is a pointer .I want to know to what "ths" parameter is pointing to.

kripken commented 10 years ago

The customizeVTable stuff is tricky and deprecated. We should update box2d to use the new webidl bindings approach (bullet has been updated), which would avoid this problem.

On Fri, Jun 20, 2014 at 3:40 AM, D.Manideep notifications@github.com wrote:

Box2D.customizeVTable(debugDraw, [{ original: Box2D.b2Draw.prototype.DrawSegment, replacement: function(ths, vert1, vert2, color) { alert('called'); } }]); In the above code I'm not knowing how the parameters "ths" is a pointer .I want to know to what "ths" parameter is pointing to.

— Reply to this email directly or view it on GitHub https://github.com/kripken/box2d.js/issues/51.