A veeery old thing I did in 2013 when I didn't really know how to program yet.
I was bored in math class so I did this thingy on my calculator.
I pretty much copy-pasted the whole thing and applied a few fixes for pico8, but it's really the same old code (ewww...)
At the time, the thing blurted out a frame every 28 seconds. Needless to say I was REALLY bored.
nostalgia link to the original code
A friend of mine already adapted it for Love2D a while ago, with much better results (video).
For fun times, try doing what I first did when I wrote this code: setting elasticity above 1/2.
EDIT: oh, yeah, you can control the camera with the arrow keys and reset the cloth with x
Really cool! Simple but super effective... A version colliding against a triangle mesh would be sick, but inevitably kill performance.
to be honest I could probably improve performance if I rewrote the code but I'm lazy.
I also wanted to add rigidity at some point but the effects wouldn't be very visible on a 15*15 cloth.
ARE YOU A WIZARD? DO YOU WEAR A POINTY HAT AND COLORFUL ROBES AND WAVE A POINTY STICK AT YOUR COMPUTER?
@matt: I think is related to a bug https://www.lexaloffle.com/bbs/?tid=2278 and https://www.lexaloffle.com/bbs/?tid=2194
[Please log in to post a comment]