[Bug] Behavior Designer : error CS0006: Metadata file could not be found

Le Gromp

New member
Full error
error CS0006: Metadata file 'Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll' could not be found
error CS0006: Metadata file 'Assets/Behavior Designer/Runtime/BehaviorDesigner.Runtime.dll' could not be found
Imported plugin, moved the plugin to Assets\Plugins\Behavior Designer\Editor and it seems it still try to reference the old one. Tried to reinstal the plugin to root folder, the exeption disapeared, but when i reimported it - it appeared again, though the file is in the place.
Unity version 2022.2.17f1
OS Windows 10
 
Last edited:
The Plugins directory has a different compilation order so that's why you are getting the error. Instead you should import the runtime source and use assembly definitions so you can have separate assemblies for the files.
 
Yea, but editor.dll is still in this package
error CS0006: Metadata file 'Assets/Behavior Designer/Editor/BehaviorDesigner.Editor.dll' could not be found
1688031175339.png
 
Last edited:
The editor can work with the runtime source code. With assembly definitions Unity is moving away from having special folders so I recommend just using assembly definitions.
 
But how do i use asmdef if i only have dll for editor? I mean there is no sourse code so i cant just create asmdef for editor, more over, if i do, it will refrence itself. But if i dont do asmdef - then i will have this error.
 
The editor doesn't need an assembly definition. Have you tried updating to an LTS release? That error is coming from Unity and I'm not sure what causes it. My guess is that it's a bug in the current version that you are using. Using 2022.3 I don't get the error with the Asset Store version or the runtime source version.
 
So should i delete the editor folder and just leave runtime with asmdef? I mean i do have runtime code and i do have asmdef for it, but the error referencing editor dll, i just dont understand how can i solve it? If i make asmdef for editor folder then i get "refrence itself" issue.
 
To import the runtime source you should delete the entire Behavior Designer folder from the Asset Store and then import the downloaded package. Using the Unity 2022.3 LTS release I do not get any errors by following this process. You could also try importing it into a fresh project just to see if another asset is somehow causing a conflict, though I'm not sure how that would happen.
 
Top