Curved Isometric Patrol

I have a problem trying to figure out how to implement a path finding system for a chess isometric map.

I read the A * algorithm and tried to see how it appears on the isometric map, and the results brought me here.

So the problem is here (I'm sorry about the cheap display)

enter image description here

So, I am now on the green roof tile (2,3), and I'm trying to find a way to the red roof tile (3,1).

Based on the A * algorithm, I am trying to calculate the F value of neighboring tiles (I did this only for these 3 tiles).
 Since the image displays the value of F (2,1) below (2,2), and this is the mother of all problems, diagonal tiles with j + 2 and j-2 will have (almost) every time lower F than “logical” a choice.
 Thus, instead of going over to (2.2), he goes over to (2.1).

How can I solve this problem? Can someone give me some advice on what to do?

+4
source share
1 answer

, , H admissible. (2,3) (2,2) 10, , 10, (2,2) (3,1), H , 20 (.. ).

H - ( - ).

. G : (G= , R= )

    14
  10  10
14   R  14
  10  10
G   14

H , 14 - , 10 - . , , . , .

H :

    34
  24  30
14   R  34
  10  24
G   14

, F (= G + H) :

    48
  34  40
28   R  48
  20  34
G   28

, 20, () , .

, , - , node, . , , .

+3

All Articles