2D Physics Engine
#21
(07-06-2023, 03:08 PM)justsomeguy Wrote: I've added another demo to my 2d physics engine. Its a soft-body simulation using mesh of joints and circles. Use the UP and Down arrow keys to adjust the bias on the joints. The bias is how stiff the joints are.

I have included everything in the zip, obviously no assets.

I'm still working on the documentation.

More demos (in various phases of functionality) are available on my github.

[Image: Screenshot.png]
This is impressive stuff!
Software and cathedrals are much the same — first we build them, then we pray.
QB64 Tutorial
Reply
#22
Quote:This is impressive stuff!
Thanks. I'm glad you enjoyed it.

Along the same lines as the soft-body simulation. I've created a cutting board type simulation. Perhaps a cooking game type mechanic?

I've also added a new command to create a poly object. You can create multi-sided polygons. I used it to make the knife.
Code: (Select All)
temp = fzxCreatePolyBodyEx("knife", 100, 30, 3) 
Sorry, I forgot to include in the demo instructions, that you can rotate the knife using the mouse wheel.

I've included a GIF so you can see it without downloading it. And of course its on the github, if you just want to look at the code.


[Image: out.gif]


Attached Files
.7z   CuttingBoard.7z (Size: 588.29 KB / Downloads: 20)
Reply
#23
Hello all,

I did a little gear train demo with the physics engine. Its a little slow and a bit janky, but it helped identify several bugs in the engine, which helps make it better.

It highlights a workaround for one of the weakness of the engine, and that is no concave objects, but nothing prevents attaching multiple objects together, also highlighted in the cutting board demo. The gears are made of a circle object and a bunch of triangles (gear teeth) attached to it. That's why if you look closely you can see the teeth twist a bit.

Before anyone asks, no you probably wont be able to simulate a whole clock. The escapement would be very tricky and it would be extremely slow.

Of course I've posted this to my github as well.


[Image: gear.gif]


Attached Files
.7z   fzxGears.7z (Size: 588.51 KB / Downloads: 26)
Reply
#24
The last documentation I have is dated June 17th 2023. Has there been any updates since then?
Software and cathedrals are much the same — first we build them, then we pray.
QB64 Tutorial
Reply
#25
Yes, unfortunately that is the latest. Most is still relevant, some things have changed, and its still incomplete. I got side tracked with a740g's raylib library among other things.

However, I have been working on the physics engine and I push anything relevant to the github.

I will start working on updating the docs. Is their something in particular that you would like to me focus on in the documentation? If you have any ideas to make it more clear, Ill be happy to work on it.

Thanks for reminding me that I need to get back to that.
Reply
#26
(08-07-2023, 10:47 AM)justsomeguy Wrote: Yes, unfortunately that is the latest. Most is still relevant, some things have changed, and its still incomplete. I got side tracked with a740g's raylib library among other things.

However, I have been working on the physics engine and I push anything relevant to the github.

I will start working on updating the docs. Is their something in particular that you would like to me focus on in the documentation? If you have any ideas to make it more clear, Ill be happy to work on it.

Thanks for reminding me that I need to get back to that.
I have been downloading the latest updates from Github and the work you've been doing is fascinating. I'm learning a lot from the examples you have included in the docs and the example code. I completely understand about getting distracted with new shiny objects as well. Smile No worries and I certainly don't want to rush you.

On page 5 the docs show a bare bone implementation. Breaking this down into well explained sections would be very helpful with detailed explanations of the commands used and how they interact with the environment.

A command index, much like the QB64 Wiki, detailing each command and its use, setup, and example. There are so many commands to choose from, I want to know about them all. Cool 

Thank you for continuing the work on the engine. I have so many ideas floating around in my head. I can't wait to start playing with them.
Software and cathedrals are much the same — first we build them, then we pray.
QB64 Tutorial
Reply
#27
Quote:On page 5 the docs show a bare bone implementation. Breaking this down into well explained sections would be very helpful with detailed explanations of the commands used and how they interact with the environment.
Since the last update I've made, making a scene, a little easier by making some things default.  The demo still works and has no issues, but I need to fully update it in the documentation. I'm trying to keep from breaking user space, so most of the things you learn about the engine will still work.

Quote:A command index, much like the QB64 Wiki, detailing each command and its use, setup, and example. There are so many commands to choose from, I want to know about them all. Cool 
I'm focusing on fleshing out the command list now. Its slow going, there is over 200 subs and functions, 95% of which you will probably never use.

Thanks for your continued support!
Reply




Users browsing this thread: 8 Guest(s)