Skip to content

Unity Project to simulate obstacle avoidance and path finding (using A star search algorithm) to help the agent (robot) solve any maze

Notifications You must be signed in to change notification settings

shaimaaK/a-star-search-algorithm-unity

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Path Finding Algorithm : A Star Algorithm

This project is implemented as part of the Robotics Course in my masters degree. The project simulates the shortest path problem in the setting of a maze where several issues of mobile robots encounters:

  1. Obstacle Avoidance
  2. Find the path leading out of the maze
  3. Finding the shortest route

Demo

unity-simulation a-star-unity

Table of contents

Description

The purpose of this project is simulating the path finding algorithm embedded into Unity Game Engine, by creating a NavMesh agent. Unity engine renders the game area to define walkable and non-walkable areas for the agent then find the shortest path to the target location as in the official unity documentation. I developed an algorithm that optimizes the shorest path by:

  1. defines the obstacles to avoid
  2. Find the soltuion to the maze
  3. finds the shortest route using A star search algorithm The player is indicated by the red cylinder, and the target location (out of the maze) is represented by the blue sphere. The floor of the maze is composed of small cube unit that is color coded as the following :
  • 🟥 -> collision area
  • ◻️ -> walkable area
  • 🟦 -> agent initial location
  • ⬛ -> shortest route out of the maze, which is computed using A star search algorithm

A Guide to Installation and Use

To try the project, clone the repository and run the A star algo scene.
For comparision purposes the NavMesh Agent in simple maze scene.

About

Unity Project to simulate obstacle avoidance and path finding (using A star search algorithm) to help the agent (robot) solve any maze

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages