How to tell if an agent is on a grid graph before trying to update movement?

I have a grid graph that is updated as player moves around procedurally generated world using the provided tutorial. I have certain agents spawn randomly as the world is created around the player. I would like the agents to only search and move if they are currently on a grid graph. Any solution to this? Thanks!

1 Like