Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This post has been wikified, any user with enough reputation can edit it.
avatar image
5
Question by mStep · Nov 13, 2013 at 03:08 AM · c#monodevelop

MonoDevelop 4.0.1 won't recognize "UnityEngine" namespace

Since upgrading to Unity 4.3 and MonoDevelop 4.0.1, building any C# script in mono hits me with a "The type or namespace name 'UnityEngine' could not be found. Are you missing a using directive or an assembly reference?"

This happens with scripts that worked in the previous version of Unity/Mono, and also for any brand new scripts created in Unity. Also, the "build all" option is greyed out and not usable. Am I overlooking something extremely simple here?

FIXED - Go to Unity preferences -> External Tools -> External Script Editor, select the drop down and manually select MonoDevelop. Worked for me.

Comment
Add comment · Show 6
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image dilbertian · Nov 13, 2013 at 03:59 AM 0
Share

Same problem here. I'm running OS-X 10.9 ($$anonymous$$avericks). I just upgraded to Unity 4.3 Pro a few hours ago. I assume you tried the obvious such as Assets->Synch $$anonymous$$onoDevelop Project? This did not make any difference with my issues.

Did you register a ticket yet with Unity support? I will fire up the Unity bug reporter and send one in myself.

avatar image mStep · Nov 13, 2013 at 04:12 AM 0
Share

Yep, I'm running on $$anonymous$$avericks as well. Didn't send a ticket yet, I've been too busy trying to fix it. Probably should have done that.

avatar image dilbertian · Nov 13, 2013 at 04:45 AM 0
Share

Ahh...that's great to know - thanks! I figured it was their new file system tweaks with the attributes causing the gremlins. I'm also getting new folder appearing in Unity after the failed compile - bin and debug - are you too? I have my file system set to show hidden folders so wasn't sure if that was causing the problem or not.

Ticket sent - but I also sent one about a month ago for a similar issue under v4.2.2, along with 2 updates and never got a single response out of them.

avatar image mStep · Nov 13, 2013 at 05:00 AM 0
Share

I am getting those folders as well. Don't think I have hidden folders enabled.

avatar image whydoidoit · Nov 13, 2013 at 05:18 AM 0
Share

I never build through $$anonymous$$D - just let Unity do it (build in $$anonymous$$onoDevelop is turned off for all of my projects) - I just tab to Unity and let it build. There can be errors that occur in $$anonymous$$D builds that don't occur in Unity and it actually does a recompile of the compiled DLLs anyway...

Show more comments

5 Replies

· Add your reply
  • Sort: 
avatar image
2
Best Answer

Answer by dilbertian · Nov 13, 2013 at 05:42 AM

This fixed this issue: http://forum.unity3d.com/threads/210405-Unity-4-3-how-do-you-associate-Monodevelop-with-the-Unity-project-Sync-doesn-t-work

However, Unity then becomes unstable and crashes should you try and Quit Unity or Open another project.

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image dilbertian · Nov 13, 2013 at 06:00 AM 0
Share

Unity Save Scene and Save Project seem to work fine. You will just need to reset the $$anonymous$$onoDevelop.App association each time you load Unity as this setting does not get saved.

avatar image dilbertian · Nov 15, 2013 at 01:09 AM 0
Share

Unity contacted me today and had me run a complete re-install which totally fixed the problem. It appears there may have been a permission error on the folder which stores the user preferences during the initial install/upgrade as I had been on 4.2.2 previously. To verify if you have the permission error, go to ~/Library/Preferences and there should be 2 files named com.unity3d.unity... in there. If you don't see them there, do the re-install.

avatar image
12

Answer by BloodFox__88 · Jan 27, 2017 at 09:27 AM

I could not find the solution on any of the forums answers or otherwise. So I started clicking stuff and found something that worked!

I use monodevelop for CS and Unity script and just updated unity 5.5.1. Then for some reason in my CS scripts the "using UnityEngine;" was red along with a lot of other unity specific functions, code hints were gone as well.

what worked:

  • in Monodevelop goto: Project -> Solution Options

  • run -> StartUp Project

  • then change the option from "Single Startup Project" to "Multiple Startup Project" and check all the radios for all the options available "Assembly-CSharp-firstpass"....then click ok

  • then restart the editor.

Then everything worked for me,... no more red error text, code hints came back. :) Hope this helps. Joshua Carlos

Comment
Add comment · Show 8 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Razorlance · Jan 30, 2017 at 03:56 PM 0
Share

Thanks, I had this problem when I upgraded to 5.5.1f1 and was trawling the web for an answers, none of which worked, but this did, cheers mate!

avatar image NG1818 · Feb 09, 2017 at 04:30 AM 0
Share

This also worked very well for me after updating to 5.5.1p2. Have you guys noticed also after the upgrade that you unity is crashing and also causing your mac to crash?

avatar image John3D · Mar 22, 2017 at 06:21 PM 0
Share

Solved my problem. Thanks!

avatar image Dynamious · Jun 19, 2017 at 12:28 PM 0
Share

Thanks, this helped me quite a bit.

avatar image PetrFiala · Aug 01, 2017 at 03:56 PM 0
Share

This is the best answer! Works!

Show more comments
avatar image
1

Answer by kaan2015 · Oct 05, 2015 at 07:48 PM

Good answers. Thanks. More precisely ... Unity -> Edit ->Preference ->External Tools ->External Script Editor-> MonoDevelop(bilt-in). All Right. Previously, Visual Studio 2015 was.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by fahadshafique · Jul 03, 2017 at 05:58 AM

Some times its the problem of .NetFramework installed in your PC...mono develop may be using .netFramework version which is not installed in your PC as a reference..so need to change version of .netFramework in monodevelop settings

For this: Go to MonoDevelop "Project" ->"Assembly-C Sharp Options" ->"Build"->"General" Now Change "Target Framework" according to the version of the .netFrameWork installed in your computer

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Yoas · Aug 14, 2017 at 05:29 PM 0
Share

Thanks a lot !!! I had this problem with Unity 5.6.3f1, I´ve tried with different solutions without success and this was the only one that worked.

avatar image
0

Answer by mkgame · Aug 06, 2017 at 10:58 AM

I had the same trouble Unity5.6.3/Monodevelop 5.9.6, nothing helped me here. I couldn't open the Visual Studio, so then I tried with MonoDevelop, where all the UnityEngine namespace dependent classes were not recognized.

Because the C# project will be generated automatically, just delete all the c# project releated files under your Unity game project directory. Then a clean working project will be generated after you open the project with MonoDevelop (e.g. double click on a .cs file in Unity).

Remove files which ends with: .csproj, .unityproj, .sln

After this I didn't missed anything in a 100GB project on which I working since 3 years.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

32 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How can i shuffle a list 5 Answers

How to know which code depends on System.dll in mono C#? 1 Answer

how to debug in monodevelop 1 Answer

A node in a childnode? 1 Answer

Setting Player Instance for Scripts doesn't work. 4 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges