XML comments for UnityEngine/Editor DLL

I think it’s truly time for the UnityEngine and UnityEditor DLL to be published with complete XML documentation, so that IntelliSense can give you full infos instead than showing methods and properties that have no description at all.

6 Likes

Would be good indeed.

Agree. And I really hope we will have this soon-ish. Haven’t looked into the actual details of implementing it though

Someone’s already doing it. Can’t remember exactly who though.

Glad to hear that!

Good to know :slight_smile: You mean who could implement it? The details otherwise are pretty simple: you just need to write correct XML comments above each method/property then tell your editor to also export the XML documentation when compiling the library.

Yeah, sounds easy I know, but we don’t have the documentation inside the C# files for e.g. following reasons:

  1. Allow easy translation into other (human) languages
  2. Our C# files is to large extend an auto-generated layer on top of the C++ core, which increases the maintanability overall

But yes, I also miss the intellisense tooltips when working with Unity myself.

Haven’t taken a closer look, but the uIntelliSense asset store package claims to have implemented this: https://www.assetstore.unity3d.com/en/#!/content/22906

Rasmus

Ouch, I totally understand now. Cool about uIntelliSense by the way, will check it out.

I wrote a tool to parse the html docs and convert them into XML files to enable intellisense code hints. The same thing as what uIntellisense does but I am providing the XML files for free. This should work well enough until Unity gets around to providing official support for it.

https://github.com/drostar/UnityIntelliSenseDocumentation

Thanks @mdrotar , works here on my Unity 4.6 on Mac as well!

FYI, the process of installing on Mac/MonoDevelop is:
Copy your XML files to /Applications/Unity/Contents/Frameworks/Managed and /Applications/Unity/Contents/UnityExtensions/Unity/GUISystem/4.6.0

Should be fairly easy to implement now (we already have the documentation internally in XML files), and would think it should be possible to get into Unity 5.x soon. Your XML files will be valuable for 4.6 anyways, so thanks again.

Best regards, Rasmus

1 Like