- Home /
how to detect which unity version is used at runtime
Hello,
I'd like to know if it's possible to detect at runtime which version of unity my code is running in (Free or Pro). I'm writing a .net library (not especially targeted at unity) which can sometimes make native calls (using pinvokes). So I'd like to avoid making those calls when running unity free (which would crash stuff).
one option I thought of was using the same system used to detect if you're running mono. Trying to load a specific class at runtime that would only be available in the given context
example (from mono's website)
Type t = Type.GetType ("Mono.Runtime");
if (t != null)
Console.WriteLine ("You are running with the Mono VM");
else
Console.WriteLine ("You are running something else");
but I don't know if there are classes that are only available in pro that I could use for such test.
thanks.
Answer by Jaap Kreijkamp · Sep 28, 2010 at 01:48 AM
is Application.unityVersion
what you're looking for?
thanks for the quick answer Jaap,
Unfortunately it's not what I'm looking for, what I need to know is wether we're running the free version or the pro.
Your answer
Follow this Question
Related Questions
Pro versus Free 8 Answers
Unity Pro vs Unity Free License Restriction Question 1 Answer
Unity free builds a good APK, Unity Pro Doesn't... why? 0 Answers
What happens after 30 day trail? 2 Answers
Immediate Mode, working in Indie? 1 Answer