- Home /
To what version does Unity update a managed Library?
Thing is: I don't know which framework to use. Since I switched to Rider I have a range of frameworks to choose from. so I went for .net standard 2.0. which with some option in Unity Player Settings worked fine without updating it.
Having switched to another Game/Project the same settings don't work here anymore. Unity always tells me it wants to update the library, which to me means not updating the mdb, hence giving me errorlines that have absolutely nothing to do with the issue (oftentimes redirecting me to a closing curly bracket.
So If anyone here knows which options in the Player settings to combine with which version of the library, that'd be great, since the Unity API Updater doesn't actually tell me which version it prefers.
Thanks in advance. This whole mdb not being created or always having to use pdb2mdb.exe (which also doesn't work now, because the API Updater doesn't create a pdb for me to create a mdb from) has been a pain in the ass for way too long. And they just didn't change anything for the last couple of months and are not about to now.
So please, someone... help me
Answer by dCalle · May 15, 2018 at 08:11 AM
Alright, it loooks like I got it all wrong. after reading this...
Still, it would be great if there was an option to point out what actually could be updated, to let me do it manually and learn something on the way...
also I think the updater doesn't create its own mdb file, right?
Anyways. Answer is: For The API Updater it doesn't matter which framework version you're using, it just checks for obsolete code and updates it...
Yes, you got it right. However the API Updater as far as i know only updates script files, not already compiled assemblies (I may be wrong here). If you're asked if you want to update and you choose "no" you should get some error / warning messages in the console. Though I'm not sure if this works for compiled assemblies. The best way to solve obsolete API usages in external libraries would be to create a new temporary Unity project, copy all your library source files into that empty project and see if the updater can fix the problems. At least if you choose "no" you should get proper line numbers and file references in the errors. Once everything is fixed, just copy the files back into your library project and recompile your library again.
Btw: Have you heard about the Assembly Definition Files? It would allow you to actually place the source files of an assembly inside Unity and have them to be compiled to a seperate assembly by Unity. As long as no changes are made to an assembly source file it should not be recompiled. Note that Assembly Definition Files are not seperate projects. They are just a way to split your source files into several logical units.
Hey Buddy, how' you doing? ;-)
yeah I used that library as mentioned in the link. But I use it for a couple of different Projects to figure out their use cases, errors and what would be nice to have next.
I actually do not have an own Unity project for that. Thought I could fix everything just on the run. But you are right, it is getting tedious compiling everything and putting it into the plugin folder every time you change something in your script...