Usually Ant Colony Optimization is used to solve problems such as the Traveling Salesman problem. This demo is an experiment that attempts to use ACO  in a more unconventional way, as a means of pathfinding  in a grid-based videogame literally using virtual ants, that eventually find their way to a target or targets.

OPTIONS:

Ants Per Generator - Max number of ants per generation for each generator

Ant Speed - Speed of each ant

Pheromone Life Span - The amount of pheromone each gridspace receives each time an ant has hit a target

Gridspace Life Ceiling - The maximum amount of pheromone a gridspace can receive (for example Life*1 means a gridspace can only receive a pheromone one, essentially either being on or off, Life*2 means a gridspace can receive a pheromone boost a maximum of 2 times, Life*3 means a grridspace can receive a pheromone boost a maximum of 3 times, and so on)

Move Randomness - At 0, an ant will always choose the gridspace with the highest value, except in the event of a tie, in which a random space will be chosen among the values tied for highest. At larger values, a gridspace with a higher value is more likely to be chosen, but it is not guaranteed.  In theory, less move randomness should result in a less efficient path, but a better chance of connecting to a new target that has not yet been reached.

Move Towards Target - If checked, if a gridspace is closer to the target  or further from the startpoint of the ant, it will receive a higher value). In the case of multiple targets, one is initially chosen at random, and after that is switched to the last target hit by an ant for all ants belonging to that generator. In theory, if this option is turned on, the ant will reach a target more easily, but is likely to spend more time in the corner opposite the generator. This should also be turned off for more of a "pure" ACO test.

Toggle: Show/Hide gridspaces.

StatusPrototype
PlatformsHTML5
Authorze-e
GenreEducational
Made withUnity

Leave a comment

Log in with itch.io to leave a comment.