Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Help] Yet Another Problem with Placing Stuff in Box2D... #18

Open
danielx-art opened this issue May 14, 2017 · 0 comments
Open

[Help] Yet Another Problem with Placing Stuff in Box2D... #18

danielx-art opened this issue May 14, 2017 · 0 comments

Comments

@danielx-art
Copy link

Hello people,
Just to introduce the situation, I am a physics teacher and educator and I am also an aspiring artist, so you can imagine the power I felt in my hands when I first discovered Processing from Shiffman's YT channel and then I the videos on Box2D.

So in my skecth I have a gas container with a piston (to show the kinetic theory of gases) and this container position is determined by the Vec2 pos_pote. The problem is that when I try to place it elsewhere from the middle of the scene (width/2, height/2), the rectangles are draw properly but the fixtures of Box2D become a little bit shifted. The farther from the center of the screen pos_pote is, the more shifted the box2D fixtures become. I've been trying to debugg this for over three days, and I still don't know what is going on. Well, see for yourself:

kinetic_gas.zip
[click on the screen to place particles and notice the collision hitboxes are all shifted to the right from the containers perspective, in this case, pos_pote = (width/2+100, height/2), so things are misplaced only on the x axis.]

I did not found anyone on the web with the same problem, so I'm desperate. If anyone could help me it would be totally awesome. Thanks very much,
Daniel.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant