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
Hi! I've been following the Wiki to better understand this project, but I was unable to successfully complete the instructions on building the project.
When I attempt to build from the main branch I receive this error:
Assets\Scripts\Dialogues\DialogueDataSO.cs(6,19): error CS0234: The type or namespace name 'Localization' does not exist in the namespace 'UnityEditor' (are you missing an assembly reference?)
Here's a screenshot showing the error:
This is very similar to the error that a user reported in #403, but it's not clear to me if the solution presented there applies to my situation as I haven't made any code changes.
Steps I followed
I cloned the repository
Making no code changes, I followed the instructions from the build wiki:
The first step was packaging the game's asset bundles, which I was able to complete without any build errors
I then tried to run "Build" from the "Build Settings" panel. The folder I tried to build to was ./Build (a new folder within the root directory of the repo)
Here's a git status showing the files that have been changed since my clone. I believe these changes are due to packaging the asset bundle.
As a quick check, I reverted all of these changes (via git checkout -- .) and tried to run a build with a completely clean install. The same error occurred.
Does anyone have any tips or advice on what might be causing this problem? Thank you so much for taking the time to read this issue!
Operating System:
Tested on both:
Windows 10 Home 20H2 19042.1165
macOS Big Sur 11.5.2
Unity version: 2020.3.12f1
The text was updated successfully, but these errors were encountered:
jamesplease
changed the title
Build error:
Build error: type or namespace 'Localization' does not exist in the namespace 'UnityEditor'
Aug 30, 2021
jamesplease
changed the title
Build error: type or namespace 'Localization' does not exist in the namespace 'UnityEditor'
Build error: type or namespace name 'Localization' does not exist in the namespace 'UnityEditor'
Aug 30, 2021
Thanks @jamesplease. The issue is exactly what the debug panel reports: there are classes that are part of the UnityEditor namespace which are being included in the code that has to go into the build. This makes it fail, since builds cannot contain any editor-related code.
This is a mistake on our end, should be easy to fix by just wrapping those classes in a conditional compilation, to say the compiler not to include them when outside of the editor (i.e. in the build). I'll fix it as soon as I can push.
I've run into similar issue when I tried to use reuse StateMachine code in my project.
For some reason Editor folders were included in build but as far as I understand the docs they should not as they are treated as special folders. Wrapping around conditional compilation fixed issue in my project but wanted to make sure if that was the case so tried building this open-project.
I followed instructions in wiki and I was able build game without adding conditional compilation to editor scripts.
The only difference I spotted was that in RiderIDE folder named editor from open-project had different icon? In my project editor folders copied from open-project did not change the icon in RiderIDE. Not sure if this issue is not being caused by some settings in Unity? Because for some reason Editor folders are included in my projects builds after copying from here.
I've used same version in my project as open-project is using now - 2020.3 with latest patch.
Hi! I've been following the Wiki to better understand this project, but I was unable to successfully complete the instructions on building the project.
When I attempt to build from the
main
branch I receive this error:Here's a screenshot showing the error:
This is very similar to the error that a user reported in #403, but it's not clear to me if the solution presented there applies to my situation as I haven't made any code changes.
Steps I followed
./Build
(a new folder within the root directory of the repo)Here's a
git status
showing the files that have been changed since my clone. I believe these changes are due to packaging the asset bundle.As a quick check, I reverted all of these changes (via
git checkout -- .
) and tried to run a build with a completely clean install. The same error occurred.Does anyone have any tips or advice on what might be causing this problem? Thank you so much for taking the time to read this issue!
Operating System:
Tested on both:
Unity version: 2020.3.12f1
The text was updated successfully, but these errors were encountered: