A Small Box2D Physics Test

Previous topic - Next topic

backslider

Hi guys,

I played around with Box2D and GLBasic and this is the result:
http://www.youtube.com/watch?v=5iDxDnS0JK4

I´ve tested on Palm Pré, it works pretty well! :)

Sorry for the ultra low quali ;)

cheers

Ian Price

It might be small, but it looks like it's well formed!

Nice one :)

Any chance of posting the code?
I came. I saw. I played.

backslider

Thanks Ian!

Maybe I will post the code. But not yet, first I want to change some things. :)
But you can "play" the alpha demo that you can see in the video.

Info:
- Don´t add more than 7 vertices per shape, otherwise the app crashes. (work in progress)
- Draw the shapes clockwise, otherwise the shape won´t interact with the world.
- If you press only mousebutton left then the shape has mass and will fall down
    - if you press "S" AND mousebutton left then you will have a static shape without mass.

Have fun... Next time I will add more videos OR the code. :P or both^^

cheers


[attachment deleted by admin]

erico

nice demo, will try when I get home!

msx

I wait impatiently for the code, I want to work with these libraries a long time ago but I do not understand very well.

If the code is finally public, I will rejoice.

Thanks  anyway.

erico

tried the code, it works pretty fine! great :O

D2O

I7 2600K; 8 GB RAM ; Win10 Pro x64 | NVidia GTX 750 TI 2048MB ; Realtec OnBoard Sound;
Lenovo ThinkPad T400: XP Pro
GLB Premium-immer Aktuell

Neurox

Quote from: D2O on 2011-Mar-19
Dont work. See movie:
http://www.deuteriumoxid.com/glbasic/shape.wmv

You have used twelve vertices for the shape but Backslider wrote :
Don´t add more than 7 vertices per shape, otherwise the app crashes. (work in progress)

Paolo Borzini | paolo@borzini.it
The WhiteFly Software | www.thewhitefly.it
Service on line for screen printers | www.4pellicole.it

matchy

That's very cool. I suppose the way to create shapes with more that 7 sides is to weld addition shapes to make the final shape.

D2O

Quote from: Neurox on 2011-Mar-19
You have used twelve vertices for the shape but Backslider wrote :
Don´t add more than 7 vertices per shape, otherwise the app crashes. (work in progress)

Oops, thank you. I come exactly from the night shift, must want be somewhat blind =D
I7 2600K; 8 GB RAM ; Win10 Pro x64 | NVidia GTX 750 TI 2048MB ; Realtec OnBoard Sound;
Lenovo ThinkPad T400: XP Pro
GLB Premium-immer Aktuell

bigsofty

Nice demo!  :good:


Was the callback issue sorted with Box2D?


Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

backslider

Thanks,

bigsofty, I don´t understand your question, sorry. :D

Ian Price

That is really cool, however items drawn clockwise have no effect on those drawn anti-clockwise, other than a brief pause on collision. Is this intentional?
I came. I saw. I played.

backslider

This is the Box2D Engine, not my code. I´m only drawing the line and then I pass the point coordinates array to the b_CreatePoly function. ;)
But I will try to use the shape edges from Box2D. Than it should work in both directions and with more than 7 vertices per line.

cheers.

Ian Price

I came. I saw. I played.