Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ju1ce/collectivebehaviour-project
The project for the Collective Behaviour course
https://github.com/ju1ce/collectivebehaviour-project
Last synced: 15 days ago
JSON representation
The project for the Collective Behaviour course
- Host: GitHub
- URL: https://github.com/ju1ce/collectivebehaviour-project
- Owner: ju1ce
- Created: 2021-10-16T09:47:31.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2022-01-06T22:34:04.000Z (almost 3 years ago)
- Last Synced: 2024-11-01T05:27:05.750Z (2 months ago)
- Language: C#
- Size: 73.7 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Collective Behaviour project
The project was mainly based on works Demšar J, Hemelrijk CK, Hildenbrandt H, Bajec IL (2015) Simulating predator attacks on schools: Evolving composite tactics and Demšar J, Lebar Bajec I (2014) Simulated predator attacks on flocks: a comparison of tactics.
We wanted to reimplement and extend the predator-prey models presented, but without focusing on genetic algorithms. We have successfuly implemented the prey model, extended it to 3D and implemented a version that uses topological distance instead of metric. The predator behaviour was also successfuly implemented, but using rules from the 2014 paper.
# How to run
The project should be opened in Unity game engine (version 2020.3). If they do not get installed automatically, the Entities and Hybrid Renderer packages may have to be installed through the package manager.
The settings for prey behaviour are located in the fish_spawner GameObject, where any of the parameters can be set. The number of prey agents that will be spawned is defined as Count^2. Other parameters are all set to be in line with the 2015 paper by default.
The settings for the predator are in SharkV1 GameObject. Its Mode defines its target selection tactic, 0 being attack closest, 1 being attack center and 2 being attack isolated.
To set the speed of simulation, set the timestep variable of the Globals class, in file FishSpawnerAuthoring.cs. A timestep of 0.1, which results in a 10x speedup, seems to work best for visualizations.
To run the simulation, press play button on the top. The simulation will run for 600 timesteps with the selected parameters, then stop.