From 099cf259dd8dfd7c44a434dd6c6dbac4bee7f462 Mon Sep 17 00:00:00 2001 From: Shubham kashyap <110350667+Shubhamkyup@users.noreply.github.com> Date: Wed, 11 Oct 2023 01:44:54 +0530 Subject: [PATCH] Update AStarExample.cs Corrected initialization of parentPos in GetSuccessors() method of MapSearchNode to (-1, -1). --- cs/AStarExample.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cs/AStarExample.cs b/cs/AStarExample.cs index a85bc7a..5246cf5 100644 --- a/cs/AStarExample.cs +++ b/cs/AStarExample.cs @@ -132,7 +132,7 @@ void AddNeighbourNode(int xOffset, int yOffset, NodePosition parentPos, AStarPat // is specific to the application public bool GetSuccessors(AStarPathfinder aStarSearch, MapSearchNode parentNode) { - NodePosition parentPos = new NodePosition(0, 0); + NodePosition parentPos = new NodePosition(-1, -1); if (parentNode != null) {