When I put code inside an #if STATEMENT block in C#, Visual Studio grays out the entire block, ruining syntax highlighting, Find All References... and all those great Visual Studio features.
Is there a way I can disable this graying out of code or are pre-processor statements to confusing for Visual Studio?
I looked at some other posts: How to get Visual Studio 2012 to grey out ifdef instead of dimming it Disable or fix #ifdef-sensitive colouring and intellisense in Visual Studio
But these are for older versions of Visual Studio and C++ rather than C# and I couldn't find a similar setting in my Text Editor Options.

You can define the UNITY_ANDROID symbol (or UNITY_EDITOR, ecc..) following these steps (for Visual Studio 2015, but I think it is pretty similar to 2013):
Properties from the context menu (or Alt+Enter)Build tabUNITY_ANDROID (or whatever) in Conditional compilation symbols fieldNow your code inside #if UNITY_ANDROID ... #endif shouldn't be grayed out anymore (and you should be able to use IntelliSense and all the other stuff).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With