Can't access a script from Inside AILerp script

Hello,
I am trying to access a script from inside the AILerp script. But it’s showing this error:
The type or namespace name ‘MapNodes’ could not be found (are you missing a using directive or an assembly reference?)

I think this is something to do with the namespace, but I don’t know much about namespace.

Here is my script:

                      void OnTriggerEnter2D(Collider2D other)
		       {
				other.GetComponent<MapNodes>().GoToSelectedScene();
		       }

and error is showing on . How to access MapNodes?

Thanks.

Hi

The pathfinding scripts are compiled separately by unity (see assembly definition files in the unity docs). I’d recommend that you create a new script outside the A* package and edit that. There, you will be able to access both the pathfinding scripts and your other scripts. You can inherit from AILerp if you want (though unless you really need to, I recommend a separate script).