Hi, I use Pathfinding Beta with a Texture Rule to make my Terrain-Mountains unwalkable. This works pretty good, but everytime I update and save my Rule Texture, I need to “Generate Reference”, otherwise “Scan” won’t respect any changes. Is this really necessary?
Hmm, that shouldn’t be necessary. Generate reference doesn’t do anything other than to save a new reference image. It shouldn’t affect the generated graph…
A quick loom of the behaviour Loom | Free Screen & Video Recording Software | Loom
Additional Infos:
- Using Beta
- My Texture and Grid are both 100x100
- I always get “Couldn’t create reference image since width*depth != nodes.Length” after clicking “Generate Reference”
Hi
Thanks!
The code did indeed not check if the contents of the image had changed. I’ll fix this in the next beta update.
I always get “Couldn’t create reference image since width*depth != nodes.Length” after clicking “Generate Reference”
Thanks! I’ll fix this error as well in the next update. Now it will use the first layer for layered grid graphs instead of complaining.
Ah, great. No hurry, it works.
3 suggestions
- More/better documentation for “Generate Reference”. For me, it is not clear why I could need it.
- Rename the texture rule to something like “Texture Mask”
- Maybe add a simple b/w Mode for walkable to the rule. I just need it for that and I am not sure if my current setup is correct (as seen in the loom) with RGBA
Thank you for the feedback!
Your setup should work for that. Black => red channel is 0 => unwalkable node. White => red channel is not 0 => walkable.