Worklog for Nate the Great
Verlet Max
Return to Worklogs
| ||
well its surprising how fast things go some days. I just spent about
an hour adding a physics body type with parent/child abilities as well
as rotation movement and different physics manipulations. Its actually
really cool to be able to write something in such a short time because
of my physics engine and my math.bmx (so helpful) It handled so much of
the stuff I needed for physics body type through its useful random
functions that I included that instead of 5 hours, i only needed 1. :) ok new vids up http://www.youtube.com/watch?v=WgWCU1Uiol4 http://www.youtube.com/watch?v=DnmVKhI4kyI ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
ok so I have improved the physics engine a little bit now although I
have taken a long break. I added and am working on a physics body type
(pbody for short) that will allow the user to easily load and save
physics bodies as well as giving them rotational speed, and other 'high
level' physics engine features These features will allow me to make FLOOD much better and will increase dev time dramaticly. They will also allow others to easily do things in one line that took many lines before such as creating boxes. On a side note as it does not mean much for most people, I also implemented a simple GC system... actually its VERY simple and I will stick to using the same system to collect the garbage and pile it up for the bmax gc to take away ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
Well the fluid engine is pretty much done with surface tension and
other properties now easily adjustable (with a little trial and error) I
think I may add more functionality later. You can see this
functionality in my game FLOOD (on my website in my sig) ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
ok so here is the comparison... not much different from my last worklog update with ONE exception...![]() about a month ago this took my physics engine 11 milliseconds to update 200 blocks. now it takes 3 milliseconds non-threaded. I cant wait till I get fluids working. But for now I will have to work on my blitz max community framework entry. edit: here is a link to download a quick little demo I made so you can see how fast it is on your computer! http://naillproductions.synthasite.com/resources/verletcount%20test.zip ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
so I had been rearanging the collision method and response of verlet
max to make it more stable. I had not run my verlet stress/speed test
in a while but when i did, I was shocked by the results. Without any
optimizing algorithms (all are incomplete atm), it handled 200 blocks,
or 800 point masses using only 11-12 milliseconds to update
everything... I was completely shocked because last time I remember, it
was hanging around 17-18 ms to update (since it was over 16, it was
killing the framerate to 30 fps rather than 60... now I have a few ms to
spare! :) I also (intentionally this time) got rid of the crushed
boxes problem completely and solved some of the jitters... now all thats
left are the one-pixel jitters that come from using floating point vars
for x,y coords which I have not found a solution to unfortunately....
Sometimes I wish bmax drawing functions would draw 2d sprites at say 1.5
pixels rather than rounding up to 2 or down to 1 anyway. for now here is a screenshot with exactly 200 blocks that had a few minutes to settle. ![]() ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
so I have been working on this on and off for a while and discovered some things in the process: 1. physics is so much fun to play with, I spend so much time playing around with demos that I hardly have any time to add to the engine. 2. sometimes it is best to just take a month off and everything looks much better when you come back... I swear it must have programmed itself better 3. stay organized. it got messy so I organized it and since then verlet max has come along much faster than before so thats what I learned. I haven't done a lot of stuff that is noticable if you are using the engine but I have used the past few months to organize and change the way many things work to make it easier to work with and more organized. Goals for 09 -learn about function pointers so I can add some more powerful features -make polygon-polygon collisions -have realistic friction -add fluids -make some nice threshold filters for fluids -finish a shifted grid algorithm for once ( I keep messing up and having to start over ) well thats all for now ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
I just added breaking-point constraints and am working on a little
fluid engine to go with it. Threading now looks quite nice rather than
the mess it was the last time I tried it so I will look into it again. Here are some screenies for now: Breaking constraints in the ragdoll demo ![]() fluid test... not the best rendering but the engine works ![]() ______________________________ -NTG http://naillproductions.synthasite.com |
| ||
I have been working on Verlet Max for a few months now, however it has just recently gotten a lot faster. Here is a link to the demos. Keep in mind the demos at the top of the page are very old, slow, and unstable. The demos at the very bottom of the page are the most recent and fastest. http://naillproductions.synthasite.com/verlet-max-2d.php I plan to release it sometime this summer. Ill post a more detailed worklog and possibly some documentatoin later this month. ______________________________ -NTG http://naillproductions.synthasite.com |