Questions tagged [boids]

Boids is a computer model of coordinated animal motion such as bird flocks and fish schools.

The algorithm itself is simple. The flock is modeled as a group of individuals, and the behavior of each individual "boid" is governed by three rules:

  1. Separation: steer to avoid crowding local flockmates
  2. Alignment: steer towards the average heading of local flockmates
  3. Cohesion: steer to move toward the average position of local flockmates

These rules are applied independently to each boid, such that there is no assigned leader.

Some useful resources for implementation:

  • Craig Reynold's boids page is the canonical reference, and contains links to many implementations and articles discussing uses of the algorithm.
  • Boids pseudocode gives an overview of the basic algorithm and various tweaks to model effects like wind, targeting and scattering.
54 questions
0
votes
1 answer

Adding aging to boids simulation

I am working on expanding this sketch: http://www.openprocessing.org/sketch/11045 Trying to add aging to boids agents using frameCount. I initialise ArrayList with age inbuilt: boids = new ArrayList(); for (int i = 0; i < boidNum; i++) { Agent…
CatNamedKat
  • 97
  • 1
  • 1
  • 7
0
votes
1 answer

Boid flocking to correctly follow target?

I'm trying to convert the boid flocking script found here: http://wiki.unity3d.com/index.php?title=Flocking To work in my 2D game, it works but the flock does not follow the target at all. the flock seems to just want to go right and up on about a…
Early73
  • 473
  • 3
  • 7
  • 23
0
votes
0 answers

How to create a simple Boids model with Canvas and JavaScript?

I need to create a simple behavior model, but nowhere find a detailed manual. Some resources give me a code on other programming languages, but practically is no one write full details of this. Help, please.
J_V
  • 1
  • 2
0
votes
1 answer

Javafx canvas not clearing correctly.

I've written a java implementation of Craig Reynolds Boids. I recently updated each object to be represented by a .png image. Ever since I've been having the display issue in the image. What's the best way to fix the issue? I've tried using a…
user1334616
0
votes
0 answers

Processing - Flock Boids avoid draggable objects

I'm working on a boids flocking project. My goal is to have several draggable objects which have to be avoided by the boids. There are several different flocks with a different starting position. I managed to get the boids to avoid one draggable…
0
votes
0 answers

Processing: Creating additonal shape in class

I have a project, in processing, where I want to scrape twitter tweets, then create a flock of boids based on the words of the tweets. Using the flocking example here as base: https://processing.org/examples/flocking.html, I have about 95% of the…
Travis
  • 19
  • 4
0
votes
0 answers

How to add up the steering forces to achieve flocking behavior

I am trying to implement a flocking boids program based on Cornrad Prkers' algorithm. I seem to be having problems with summing up all the forces (alignment, cohesion and separation). I keep getting a weird behavior. The alignment part of the…
0
votes
1 answer

counting neighbors of boids in python

I am making a program to simulate a flock of birds in python by means of boids. One of the tasks is to count the neighboring boids (distance <= 50). I tried to do it like this (see code) but I don't get good results. The 'print distance' gives 20x…
-2
votes
2 answers

Bird Animation customization

I am trying to create a website. The link for the website is: http://www.eclectika.org/test3 I want the birds in the following link: http://mrdoob.github.io/three.js/examples/canvas_geometry_birds.html to be in my background. Please someone suggest…
1 2 3
4