I'm having an issue with Box2D.
For some odd reason, as shown in the screenshot below, objects aren't colliding correctly.
Snapshot:
http://sufr.in/i/lRfW50x.png - See how the ball isn't touching the ground? Well, that gray block does this at random times, no idea why.
Could someone review the source and see what's up?
Fixtures are not attached to body correctly
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Fixtures are not attached to body correctly
Last edited by Bannana97 on Mon Jun 04, 2012 5:44 am, edited 1 time in total.
Re: Fixtures are not attached to body correctly
The ball isn't touching the ground because there are bodies under it that don't get drawn.
Instance.new calls the setup function with the default values of the object. The :update() method then calls the setup function again, apparently with the correct values.
Instance.new calls the setup function with the default values of the object. The :update() method then calls the setup function again, apparently with the correct values.
Shallow indentations.
Re: Fixtures are not attached to body correctly
Okay, so on update() is there a method to remove the old body?
Re: Fixtures are not attached to body correctly
Thanks, everyone here rocks. I LÖVE this.
I used :destroy() to remove the old bodies if exist. Now, tons of bugs are fixed and I got callbacks working.
Thanks so much! <3 <3 <3
I used :destroy() to remove the old bodies if exist. Now, tons of bugs are fixed and I got callbacks working.
Thanks so much! <3 <3 <3
Who is online
Users browsing this forum: No registered users and 2 guests