UnityUtils icon indicating copy to clipboard operation
UnityUtils copied to clipboard

Pathfinding - Grid Component same as Built in Unity Component

Open markymark501998 opened this issue 6 years ago • 3 comments

Hello there,

I haven't tried your pathfinding yet but it looks solid. However when I dropped the code in my game project I saw that the grid component is giving me a warning since Unity introduced its tilemap system.

Just thought I'd let you know!

Sincerely, Mark H.

markymark501998 avatar Mar 06 '18 02:03 markymark501998

Thanks! Maybe I'll fix it one day.. leaving this issue opened for now :)

RonenNess avatar Aug 12 '18 20:08 RonenNess

An easy fix would be to just update the Grid.cs script to GridScript.cs.

fisheraf avatar Jul 03 '19 00:07 fisheraf

I am offering a possible solution to this with PR #8, which changes the library to use an interface GridI. Then, the user can just change the concrete class name from Grid to SquaresGrid or whatever and avoid this problem. At the same time, it also allows for lazy evaluation of the Node costs (and setup) plus hex-shaped "grids" with a different implementation of Neighbors (for examples, please see https://www.redblobgames.com/grids/hexagons/).

buddhisthead avatar Oct 11 '19 18:10 buddhisthead