You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Unity 2021.3.32f1, in a new project
Packages imported: CIVIL-AI, Synthy PolygonFarm
I put a Synthy character in my scene, unpacked the prefab then applied the NPC template to it.
A Null exception is raised, pointing to "Resources.Load("System/Objects/AI");" in AIOverviewManager.AddInNPCTemplate()
This is because Resources.Load search in a "Resources" directory which doesn't exist.
The RuntimeAnimatorController "AI.controller" is in "Assets/CIVIL-AI-SYSTEM/Animation Controller/Controller", so I fixed the issue by replacing
Also, I made another change, but it's not technically a bug. Since the Synthy character already has an animator component with an avatar defined, I also replaced
Hi Sanglyon,
Any chance you can tell me which version you have downloaded of the tool? You can find this out in the package manager. Also did you import the file using the package manager into your project or did you download it from another and then copied it across?
Thanks,
Isaac
On Saturday, 20 April 2024 at 23:19:03 BST, Sanglyon ***@***.***> wrote:
In Unity 2021.3.32f1, in a new project
Packages imported: CIVIL-AI, Synthy PolygonFarm
I put a Synthy character in my scene, unpacked the prefab then applied the NPC template to it.
A Null exception is raised, pointing to "Resources.Load("System/Objects/AI");" in AIOverviewManager.AddInNPCTemplate()
This is because Resources.Load search in a "Resources" directory which doesn't exist.
The RuntimeAnimatorController "AI.controller" is in "Assets/CIVIL-AI-SYSTEM/Animation Controller/Controller", so I fixed the issue by replacing
animator.runtimeAnimatorController = Resources.Load<RuntimeAnimatorController>("System/Objects/AI");
with
animator.runtimeAnimatorController = AssetDatabase.LoadAssetAtPath<RuntimeAnimatorController>("Assets/CIVIL-AI-SYSTEM/Animation Controller/Controller/AI.controller");
------------------------------------------------------
Also, I made another change, but it's not technically a bug. Since the Synthy character already has an animator component with an avatar defined, I also replaced
Animator animator = selected.AddComponent<Animator>();
with
Animator animator;
if(!selected.TryGetComponent<Animator>(out animator))
{
animator = selected.AddComponent<Animator>();
}
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
In Unity 2021.3.32f1, in a new project
Packages imported: CIVIL-AI, Synthy PolygonFarm
I put a Synthy character in my scene, unpacked the prefab then applied the NPC template to it.
A Null exception is raised, pointing to "Resources.Load("System/Objects/AI");" in AIOverviewManager.AddInNPCTemplate()
This is because Resources.Load search in a "Resources" directory which doesn't exist.
The RuntimeAnimatorController "AI.controller" is in "Assets/CIVIL-AI-SYSTEM/Animation Controller/Controller", so I fixed the issue by replacing
animator.runtimeAnimatorController = Resources.Load<RuntimeAnimatorController>("System/Objects/AI");
with
animator.runtimeAnimatorController = AssetDatabase.LoadAssetAtPath<RuntimeAnimatorController>("Assets/CIVIL-AI-SYSTEM/Animation Controller/Controller/AI.controller");
------------------------------------------------------
Also, I made another change, but it's not technically a bug. Since the Synthy character already has an animator component with an avatar defined, I also replaced
Animator animator = selected.AddComponent<Animator>();
with
Animator animator;
if(!selected.TryGetComponent<Animator>(out animator))
{
animator = selected.AddComponent<Animator>();
}
The text was updated successfully, but these errors were encountered: