- A* version: 5.4.5
- Unity version: 6000.0.58f2
Hi there.
Reproduction steps:
- Set up a fresh project (URP in my case), import A* and its samples and Burst and Entities etc.
- Add the A* sample scene “Recast3D” to the Build scene list.
- Set up a scene so it only contains a gameobject with this script component:
using System.Collections;
using UnityEngine;
using UnityEngine.SceneManagement;
public class LoadRecastScene : MonoBehaviour
{
void Start()
{
StartCoroutine(LoadCo());
}
private IEnumerator LoadCo()
{
yield return new WaitForSeconds(2.0f);
SceneManager.LoadScene("Recast3D", LoadSceneMode.Additive);
}
}
The Gizmos of the AStarPath component will never render, this is because of the line here:
if (!script.gameObject.scene.IsValid()) {
// The object is likely part of a persistent prefab asset. We will never have to draw any gizmos for it, because it will never become enabled, and it will never show up in the scene view.
continue;
}
in DrawingManager.cs:615
This will cause it to never be queued into the custom Gizmo rendering system.
Best regards
Alex Nogueira