Need to make a swaying flower?
Monkey Forums/Monkey Programming/Need to make a swaying flower?
| ||
Hi, I need to create a simple flower & stem that sways and can be affected by force, i'm think Box2D, any other ideas? Thanks. |
| ||
There's a zombie on your lawn... |
| ||
We don't want zombies on our lawn... |
| ||
On a serious note, you should be able to do it with a spring in Box2D. I have very little experience with it since I've only really used Chipmunk, and that was ages ago. |
| ||
Thanks, I'll have to mow my lawn! |
| ||
I have got something basic working in box2d, does anyone know how you get the x,y and r of each fixture in a collection of joints, like the bridge demo? I need to draw an image over each part. Thanks. |
| ||
Look at b2World.DrawDebugData(). |
| ||
Thanks Mr shoes your Box2D implementation is great and I am getting to slowly know my way round it. I am putting together a helper module that includes a loader for http://www.physicseditor.de/ will release it for others when it does somthing useful. |
| ||
Right I have a stem made from a vertical bridge of joints that works quite well, but to get it to sway I need to move the anchors? I can't seem to find a way to affect them? Thanks. |
| ||
I think you would need to apply a force to a joint to make it move. |
| ||
Thanks, sorted it now, I had to remove one of the end joints so it could sway about. |