I upgraded from free to the latest version just now. Followed the update instructions (start new scene, delete NGUI, reimport nGUI) and my game runs fine.
But when I go to edit any of my C#, I get this error compiling the project:
------ Build started: Project: UnityVS.ScifiEmpire.CSharp, Configuration: Debug Any CPU ------
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(270,4): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(453,8): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(453,64): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(453,93): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(454,5): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Internal\UIWidget.cs(480,20): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIAtlas.cs(373,3): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIAtlas.cs(389,5): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIAtlas.cs(406,5): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIAtlas.cs(423,5): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIPanel.cs(584,20): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIPanel.cs(1034,20): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\UI\UIFont.cs(599,3): error CS0103: The name 'UnityEditor' does not exist in the current context
C:\Programming\ScifiEmpire\Assets\NGUI\Scripts\Interaction\UIPopupList.cs(171,6): error CS0103: The name 'UnityEditor' does not exist in the current context
I don't know a lot about Unity. I'm using VSUnity. In Visual Studio there are two projects in the SLN:
UnityVS.ScifiEmpire.CSharp
UnityVS.ScifiEmpire.CSharp.Editor
It seems to me that the NGUI stuff in the first project shouldn't be looking for the editor. Or the preprocessor flag of #if UNITY_EDITOR is for some reason turned on in that project.
I don't know what to do!