Welcome Guest.   Make a donation to an author on the site September 09, 2010, 01:26:09 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
Learn about the DonationCoder.com microdonation system (DonationCredits).
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: timns' Wobbly Blobby bits  (Read 3556 times)
timns
Supporting Member
**
Posts: 187



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« on: March 10, 2008, 03:00:06 PM »

Evening all,

I just uploaded some old old code that I wrote which models blobby things bouncing around and merging / splitting. Think amoeba or those old lava lamps.

I'm putting it on DC because I always wanted to use this effect in a game but lacked the imagination to come up with anything. The source code is freely available to anyone who asks, in the hope they will be able to do something clever with it where I could not!

http://timns.dcmembers.com/Blobs.html



timns
Logged

f0dder
Charter Honorary Member
***
Posts: 6,905



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #1 on: March 10, 2008, 06:53:09 PM »

Oooh, sqrt(x) blobs? smiley

Why not post the source public for everybody?
Logged

- carpe noctem
timns
Supporting Member
**
Posts: 187



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #2 on: March 11, 2008, 01:34:24 AM »

Yes, sort of.  Have you written something similar then? I'd love to see it.

The algorithm I used treats each blob as a circular field - when 2 or more blobs get close enough, the fields add up to (or beyond) a trigger value, after which I assign a colour based on the sum of the fields' strengths. I dug the idea out of Foley and Van Damme a long time ago... probably when most of the readers of this forum were still sperm.

Anyway, I'll provide the source when someone asks for it, by all means. I'm trying to get interactive here, man!  cheesy

timns
Logged

f0dder
Charter Honorary Member
***
Posts: 6,905



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #3 on: March 11, 2008, 07:07:54 AM »

It's been quite a while since I played with this stuff, probably around ~1998 or so. I remember initially using the distance formula (including sqrt(x)), and then realizing that since I didn't need to, like, print a correct value to an end-user, there wasn't really any good reason for the sqrt. With a few adjustments, the distance value could be kept squared, and that gave a pretty big speed increase smiley

Don't have the source (or binary, for that matter) anymore, though.
Logged

- carpe noctem
Pages: [1]   Go Up
  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
SMF © 2006-2009, Simple Machines LLC

social bookmark this page