Questions tagged [path-finding]

Pathfinding generally refers to the problem of finding the shortest route between two points, subject to any obstacles. Pathfinding has application in a wide range of areas including robotics and game development. Algorithms for pathfinding tend to be closely related to graph and tree search algorithms.

Pathfinding generally refers to the problem of finding the shortest route between two points, subject to any obstacles. Pathfinding has application in a wide range of areas including robotics and game development. Algorithms for pathfinding tend to be closely related to graph and tree search algorithms.

Significant Literature

External Links

Related Tags

1746 questions
7
votes
3 answers

How could revise the recursive algorithm to find the shortest path?

https://vimeo.com/70999946 I implemented a recursive path finding algorithm. This recursive algorithm works based on a pre-set of nodes connected together. Each node has four pointers containing further direction: Top, Button, Left and Right. The…
7
votes
2 answers

How to optimize A* (AStar) Search for Concave Shapes? (includes screenshots)

I am writing a fairly simple top down, 2D game. It uses an evenly spaced 2D grid of tiles for all collision data. Each tile in the grid is either solid or empty. For path finding I am using A* (A Star), and have tried both Manhattan and Diagonal…
Goose
  • 1,307
  • 2
  • 14
  • 28
7
votes
5 answers

How to find where to cast a ray to avoid collision in Bullet?

Say we have an object at point A. It wants to find out if it can move to point B. It has limited velocity so it can only move step by step. It casts a ray at direction it is moving to. Ray collides with an object and we detect it. How to get a way…
myWallJSON
  • 9,110
  • 22
  • 78
  • 149
7
votes
1 answer

rapid exploring random trees

http://msl.cs.uiuc.edu/rrt/ Can anyone explain how rrt works with simple wording that is easy to understand? I read the description in the site and in wikipedia. What I would like to see, is a short implementation of a rrt or a thorough explanation…
AturSams
  • 7,568
  • 18
  • 64
  • 98
7
votes
1 answer

3D search using A* JPS

How can I generalize Jump Point Search to a 3D search volume? So far, I have defined pruning rules for a 3D cube involving each of the three movements- straight (0,0,1), first-order diagonal (0,1,1) and second-order (1,1,1). What I'm mostly…
Puppy
  • 144,682
  • 38
  • 256
  • 465
7
votes
3 answers

What's a fast and stable algorithm for a random path in a node graph?

I have a graph which consists of nodes and I need a fast algorithm that generates a random path between two nodes. I designed several algorithms from scratch for this but can't seem to get it right. Either the algorithm gets stuck in loops, or when…
Marnix v. R.
  • 1,638
  • 4
  • 22
  • 33
7
votes
3 answers

A* Jump Point Search - how does pruning really work?

I've come across Jump Point Search, and it seems pretty sweet to me. However, I'm unsure as to how their pruning rules actually work. More specifically, in Figure 1, it states that we can immediately prune all grey neighbours as these can be…
Puppy
  • 144,682
  • 38
  • 256
  • 465
6
votes
7 answers

Finding the path with the maximum minimal weight

I'm trying to work out an algorithm for finding a path across a directed graph. It's not a conventional path and I can't find any references to anything like this being done already. I want to find the path which has the maximum minimum weight. I.e.…
Martin
  • 12,469
  • 13
  • 64
  • 128
6
votes
6 answers

Pathfinding while forcing unique node attributes -- which algorithm should I use?

Update 2011-12-28: Here's a blog post with a less vague description of the problem I was trying to solve, my work on it, and my current solution: Watching Every MLB Team Play A Game I'm trying to solve a kind of strange pathfinding challenge. I…
Plutor
  • 2,867
  • 2
  • 25
  • 29
6
votes
1 answer

How to deal with different sized objects in a pathfinding situation (A*, A-star)

I'm working on a game that uses A-star (A*) for path finding but I've come to a point where by I have some objects that are larger than a single grid square. I'm running on a grid of 16*16px. wall segments are 16*16 and so make a single square…
Greg B
  • 14,597
  • 18
  • 87
  • 141
6
votes
2 answers

I don't understand A* Pathfinding

From what I understand: Add the current node to the closed list. Find adjacent nodes to the current node, and if they are not unwalkable nodes and not on the closed list, add that node to the open list with the parent being the current node and…
apscience
  • 7,033
  • 11
  • 55
  • 89
6
votes
1 answer

How to move objects from node to node? Libgdx Box2d A*Pathfinding

I can't succeed in making the enemies move from node to node. I managed to set up the whole pathfinding, I'm getting a full path to the player and the position of the next node all the way to the end. How do I move the box2d body from node to…
Deso2121
  • 99
  • 8
6
votes
7 answers

Path finding in a Java 2d Game?

Essentially its a pacman clone game I'm working on. I have an Enemy class, and 4 instances of this class created which all represent 4 ghosts of the game. All ghosts start up in random areas of the screen and then they have to work their way towards…
Ali
  • 261,656
  • 265
  • 575
  • 769
6
votes
1 answer

Finding the globally shortest path in non-degenerate trapezoidations

I'm searching for an efficient algorithm that finds the globally shortest path between two points in a 2-dimensional space with polygonal obstacles. The source data is in the form of a non-degenerate vertical trapezoidation consisting of up to 10^4…
xDD
  • 3,443
  • 1
  • 15
  • 12
6
votes
2 answers

Is best first search optimal and complete?

I have some doubts regarding best first search algorithm. The pseudocode that I have is the following: best first search pseudocode First doubt: is it complete? I have read that it is not because it can enter in a dead end, but I don't know when can…