Skip to content
Welcome to Spicy Pixel Answers, where you can ask questions and receive answers from the support team and other members of the community.

Missing method exception in build

0 votes
I am using the concurrency library to, well, do concurrent operations in my Game. Everything works fine in the play test mode, but once I export a build I get the following error:

missing method System.Threading.ThreadPool.UnsafeQueueUserWorkItem

I know it's not just my code since the sample project does the same thing when I export it. Do I need to change a setting in the project for this to work correctly?

I cannot compile in 2.0 because that causes a large number of syntax errors (and I don't think it is compatible with the start new thread syntax)

I am using Unity 5.1.0f3 64bit and compile with .NET 3.5
asked Mar 5, 2016 in Concurrency Kit by vdwtanner (150 points)

1 Answer

0 votes
Best answer
Hi, and thanks for the question. That method is only available in the full .NET 2.0 profile, so if you have your Unity project set for subeset, micro, or webplayer you will need to change it.

There's a little more context here:

Since the source code is avilable to the kit, the other option is to change that call to the regular ThreadPool.QueueUserWorkItem() method available everywhere and recompile the DLL. At some point I will get a moment to update the code myself to do just that so it works by default on all profiles. Sorry for the inconvenience in the interim.
answered Mar 5, 2016 by admin (2,500 points)
selected Mar 6, 2016 by admin