Quick Search for:  in language:    
BOID,program,uses,three,simple,rules,each,whi
   Code/Articles » |  Newest/Best » |  Community » |  Jobs » |  Other » |  Goto » | 
CategoriesSearch Newest CodeCoding ContestCode of the DayAsk A ProJobsUpload
Visual Basic Stats

 Code: 3,014,970. lines
 Jobs: 119. postings

 How to support the site

 
Sponsored by:

 

You are in:

 
Login



Latest Code Ticker for Visual Basic.
Mp3 Paker
By Michael McMullen on 7/2


Suppress Run Time Script Errors
By Nuclear_1000G on 7/2


Click here to see a screenshot of this code!List Maker
By KBM-00 on 7/1

(Screen Shot)

Web Update Checker
By knormalnight on 7/1


A*Beginners API*
By Michael Nipper on 7/1


source hog v1.1
By Robert Justason on 7/1


Click here to see a screenshot of this code!AdAlert® Spyware/Adware Remover UPDATED
By Intrepid Software on 7/1

(Screen Shot)

Click here to see a screenshot of this code!a--CONTROL WINAMP--
By Konrad Beckmann on 7/1

(Screen Shot)

Click here to see a screenshot of this code!BlueCam
By Marshall H. on 7/1

(Screen Shot)

Click here to put this ticker on your site!


Add this ticker to your desktop!


Daily Code Email
To join the 'Code of the Day' Mailing List click here!





Affiliate Sites



 
 
   

vbBoid

Print
Email
 
winzip icon
Submitted on: 9/26/1999
By: Richard Lowe 
Level: Not Given
User Rating: By 103 Users
Compatibility:VB 5.0, VB 6.0

Users have accessed this code 10196 times.
 
 
     This program uses three simple rules for each BOID, which when applied in the correct proportion produce emergent flocking behaviour. This program is entirely based on the work of Craig Reynolds (http://htm.com/cwr/boid.htm). I developed this program after a debate with a c++ programmer, who said that VB wasn't up to the job. See what you think.
 
winzip iconDownload code

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. Afterdownloading it, you will need a program like Winzipto decompress it.

Virus note:All files are scanned once-a-day by Planet Source Code for viruses,but new viruses come out every day, so no prevention program can catch 100% of them.

FOR YOUR OWN SAFETY, PLEASE:
1)Re-scan downloaded files using your personal virus checker before using it.
2)NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.
3)Scan the source code with Minnow's Project Scanner

If you don't have a virus scanner, you can get one at many places on the net including:McAfee.com

 
Terms of Agreement:   
By using this code, you agree to the following terms...   
1) You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.   
2) You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
4) You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.


Other 2 submission(s) by this author

 

 
Report Bad Submission
Use this form to notify us if this entry should be deleted (i.e contains no code, is a virus, etc.).
Reason:
 
Your Vote!

What do you think of this code(in the Not Given category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor See Voting Log
 
Other User Comments
9/27/1999 7:05:00 AM:Richard Lowe
If you would like any further 
information....please mail me
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/1999 7:17:00 AM:Bruce Reid
Excellent work! I'm also a huge Craig 
Reynolds fan.  I've been working on my 
own boids for a few months now and was 
having trouble with making Collision 
Detection work in a fast enough way.  
Hopefully your code will help me fill 
in some blanks.  Haven't looked at your 
code yet, but your EXE looks great!   
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/1999 7:36:00 AM:Richard Lowe
Note : You can also add more obstacles 
by clicking in the picture !!!
I 
Should have mentioned that somewhere....
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/27/1999 9:57:00 PM:Jeffrey Haluska
About 5 years ago I wrote a program in 
VB that
was very similiar to this. (I 
was 14)
In many ways this is 
superior.
I always had problems with 
the boids 
flying through complex 
objects too.
Keep up the great work.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/28/1999 6:52:00 AM:l_marvin
"I did this when I was 14" or "It was 
my Year 1 work" is, not only 
irrelevant, but a bit distasteful; 
would people refrain from doing that.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/3/1999 7:51:00 PM:Herman
A marvelous piece indeed.  To me it has 
the kind of beauty of Kevino's 3D 
Mathematical Plot(beyond my grasp 
though, as I come from a different 
profession).
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/4/1999 3:02:00 PM:JOe
It Rocks!!!!!!!!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 7:16:00 AM:Jeffrey Haluska
Well I did make this in the past and if 
you dont like me saying so then dont 
read my comments.  And i didnt say it 
before because i was being nice, but 
mine was actually much better than this 
one!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 8:53:00 AM:Richard Lowe
Jeffrey. I did not take offense to your 
comment, in fact I was quite impressed 
that you did this at the age of 14.
I 
would be interested to see your version 
- please post it on this site
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 11:40:00 AM:Eric Miles
The correct web address for Craigs work 
is
http://hmt.com/cwr/boid.htm
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 11:43:00 AM:Eric Miles
whoops I 
meant:
http://hmt.com/cwr/boids.html
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 6:45:00 PM:Andrew
Wow!  Although I don't know much about 
boids, I am still very impressed with 
what I am seeing.  This is very cool.  
Great work!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/5/1999 6:54:00 PM:Andrew
After visiting Craigs' web site on 
boids, I have a better understanding of 
boids.  All I can say is that this is 
probably beyond my skills at this time; 
however, I am motivated to research 
more on this.  I think this is really 
great stuff!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 11:08:00 AM:l_marvin
(1) Re: Jeffrey's comment - This time 
it is not distasting, it has become 
disgusting now. (2) What make Richard's 
posting outstanding is that it has 
refresh input, hence it has live, 
forget about technical aspect for a 
moment (look at the many repeated old 
topics every day on this site).  3. 
Richard: Would you please take a look 
of "Clear" button; a minor point 
though, seems not working?
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 2:07:00 PM:Richard Lowe
Thanks for all the great comments 
guys.
The Clear button does work - but 
only when the boids are running - a 
minor bug I know....
Please mail me 
with any other bugs, suggestions....
I 
intend to implement some of the other 
grouping behaviours discussed by Craig 
reynolds (seek, avoid, dock, etc) in 
the next version.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 2:30:00 PM:Paul
Way Cool... Richard! And I to would 
like to see Jeffey's code! 5 years ago 
---right????
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 5:10:00 PM:Bruce Johnson
Very very Nice.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 5:36:00 PM:Jonathan Feucht
This is great! GREAT!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 7:37:00 PM:Andrew
Hi Richard,
I think I have found 
something interesting in this boids 
simulation.  This is what I have 
discovered:
When I place more than a 
dozen circular obstacles in a way 
similar to a bowling pins placement 
tightly with only a little room for the 
boids (30 of them) to manuver, some of 
boids actually would go through the 
obstacles close to the curve area of 
the obstacles (basically the boids 
would go inside the obstacle a little 
bit and come out quickly)!  Is this 
suppose to happen or is this because I 
have not given them enough room to 
avoid obstacles?  If you can give me 
some hints, that would be great.  
Thanks.
Andrew
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 10:37:00 PM:Jeffrey Haluska
I sincerely did not try to be 
distastesful.  If you took it that way 
(which Richard didn't) it is your 
problem.
After rooting around for a 
couple minutes, I actually DID manage 
to find the code along with an email 
reply I got from Craig Reynolds, a very 
nice guy.  I was wrong it was only 4 
years ago.
As right now it doesn't 
compile, cause it was written for VB 
4.0 (I have VB 6.0 now), and my EXE 
requires a VB40032.DLL.
If I get 
time, I'll try to get it to work in 
6.0, and upload it.
Also, if you 
think it runs slow on your computer 
with lots of boids, I originally had to 
write it on a 486 66.
Jeff
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/6/1999 11:34:00 PM:suresh
good program
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/7/1999 3:46:00 PM:Richard Lowe
Andrew - It is quite possible that the 
boids will go into an object. The 
Calculations TRY to make them avoid 
this - but if other obstacle or boids 
get in the way - BANG. This is also 
true in Nature - birds, fish etc will 
try to avoid hitting and obstacle - but 
don't always succeed - If you read the 
multitude of documentation on the net 
about boids - you will find this is 
very common. If you change the maths to 
try to ensure they boids avoid the 
obstacles - the flocking behavoiur 
falls apart.
Jeff - glad you found 
the code - look forward to seeing it - 
let me know if you need any help in the 
conversion.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/8/1999 12:30:00 AM:Bryan Cairns
That's one of the most amazing things i 
have seen done in VB - great job
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/8/1999 10:21:00 AM:Richard Lowe
Jeff - Thanks for the code - It looks 
great. I too was inspired by Steven 
Levy's book Artifical Life - a great 
read.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/16/1999 8:44:00 AM:122
GREAT WORK!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/16/1999 8:45:00 AM:John Doe
COOL!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/16/1999 5:38:00 PM:Russ Smith
What an incredible piece of work - I am 
fascinated by these "BOID" things and 
have begun to research them.  Sadly I 
didn't even realize such a thing could 
be done in VB - not to mention it being 
done in so very few lines of code.  
GREAT JOB!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/21/1999 9:12:00 AM:Lupine
i have seen this before on the site. i 
like it alot very good work
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/25/1999 2:06:00 AM:Shambler
Very slick indeed. Time for a group 
session of "screw you!" to all the C++ 
snobs...
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/26/1999 7:45:00 PM:Chen Gang
A Bug. When set Sensor Range to 0,a 
runtime error arises and the app exits.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/31/1999 4:58:00 AM:Alexandre Moro
Guys,
Apart from any bug, I think MANY 
congratulations go to Richard by 
implementing such algorithm in 
VB.
This is EXTREME DIFFICULT, I know 
what I'm talking about...
Richard, 
parabéns!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
1/24/2000 10:19:40 AM:OmarSwan
Great Work.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
3/23/2000 6:51:56 PM:Armen Nalian
It is great!!!!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
9/25/2000 1:43:07 AM:Craig Reynolds
Despite the fact that it was almost 
a
year ago that Richard Lowe told me 
about
his VB boids implementation, I 
am just
now getting around to updating 
my boids
page to include a link to 
this page.
(BTW after two domain 
changes my page is
now at 
http://www.red3d.com/cwr/boids/)
Sorry 
for the delay, and happy flocking!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
7/30/2001 10:25:13 PM:brewguru99
Wow! a celeb!
BTW - I recently 
re-downloaded this program and am 
currently implementing my own version, 
with added AI attributes... Oohhhhh I'm 
so excited about this.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
Add Your Feedback!
Note:Not only will your feedback be posted, but an email will be sent to the code's author in your name.

NOTICE: The author of this code has been kind enough to share it with you.  If you have a criticism, please state it politely or it will be deleted.

For feedback not related to this particular code, please click here.
 
Name:
Comment:

 

Categories | Articles and Tutorials | Advanced Search | Recommended Reading | Upload | Newest Code | Code of the Month | Code of the Day | All Time Hall of Fame | Coding Contest | Search for a job | Post a Job | Ask a Pro Discussion Forum | Live Chat | Feedback | Customize | Visual Basic Home | Site Home | Other Sites | About the Site | Feedback | Link to the Site | Awards | Advertising | Privacy

Copyright© 1997 by Exhedra Solutions, Inc. All Rights Reserved.  By using this site you agree to its Terms and Conditions.  Planet Source Code (tm) and the phrase "Dream It. Code It" (tm) are trademarks of Exhedra Solutions, Inc.