Fluid Simulator - Google's Liquidfun
I searched everywhere for sample javascript code for this (based on Box2D which is a C++ library) and finally found something functional.
The only things I added were html controls for the objects.
Most of it is based off of https://github.com/doebi/liquidfun.js-demo/tree/master
If you want faster framerate, shrink your window.
Hotkeys:
• B : Create physics box
• W : Create blob of fluid
• Left mouse: Create Blob of Fluid
• Right mouse: Create frozen box
• Middle mouse: Create physics box
Man this is cool
My friends: So what do you do in your free time?
Me: It's complicated...
I don't recommend jitter click spawning in the water or else the repl will crash. Also i get 45cps so it might just be me lol
9.8/10 could use more features
Whats middle click
this is so fun
glad you think so
I have only ran this on my machine, how is the framerate on your computer?
runs nicely on a (older)chromebook as long as i dont spawn in to many objects (aka spawn like 100 blobs)
@mwilki7and 50 fps
@mwilki7if u want me to i can be ur tester and push it to its limits
@mwilki7ocd mode activated
ok so what i found is that you can completely push it with the physics blocks buut the blob slow it down pretty quickly. will that be cash or credit lol
umm do you accept upvotes (´・ω・`)?
if anyone could tell me how to change the darn fluid color that would be rly nice
sadly ive tried all sorts of combinations of stuff so far
i can change the color of the boxes but not the fluid
even commenting out the line: pgd.set_color(color);
doesn't change the color
i think me mind is going ded
ngl I'm pretty sure if you tried hard enough you could conceivably make something similar without basing it on something.
pls not partial derivatives
ಥ_ಥ
lol
@SixBeeps