Giter Club home page Giter Club logo

flockai's Introduction

FlockAI

Implementation of flocking behavior AI developed in Unreal Engine 4.

Author: Pablo Rodriguez (parmandorc)

Relevant links

Engine Verion used

Unreal Engine 4.7.6

Instructions for the game

  • Basic movement using WASD or arrows. (Note: You don't control the agents, you can just move the camera around)
  • Mouse wheel to zoom in and out.
  • Mouse left clic to spawn new Agents to the scene. (Hold left clic and move the mouse to orient the starting direction of the agent, or right clic to cancel spawning).
  • Press 2 in order to spawn Positive Stimuli (or food) instead when left clicking.
  • Press 3 in order to spawn Negative Stimuli (or enemies) instead when left clicking.
  • Press 1 again to spawn new Agents.

About this project

This project implements a traditional flocking AI algorithm, with its 3 traditional components:

  • Alignment: agents will face the same direction as their neighbors.
  • Cohesion: agents will try to stay together as a group.
  • Separation: agents will try to steer away from very close neighbors so the group doesn't collapse.

Nevertheless, while the traditional algorithm uses normalized vectors, this project takes a different approach by taking into account the distance between agents. This means for instance that an agent will try to separate from its neighbors more intensely if they are about to collide than if they are rather far away, which provides a much more realistic behavior.

Another new aspect is the introduction of external stimuli to the agents. This means they will react to points of interest in their field of view, simulating behaviors like going towards food or avoiding an enemy.

The purpose of this project is purely academic, and so its focus was to implement an Artificial Intelligence algorithm in a real time environment, but also to gain experience with Unreal Engine as a game development environment, and that is why the majority of the funcionalities of the game are developed using C++ programming, except for the main algorithm which is developed using Blueprint programming so as to gain experience with this technology.

flockai's People

Contributors

parmandorc avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.