How to recognize I'm in Unity Webbuild Editor, without precompiler

As in topic:

I need to be able to execute code path when I have:

  1. Editor and
  2. Webplayer build

Things I cannot use (those are requirements I have from 3rd party, so there is no “change requirements” possible):

  1. No precompiler directives
  2. No Editor scripts that I can poll for

Things I tried:

  1. Application.isEditor && similar fields
  2. RuntimePlatform

Current solution:

Do WWW query to google.com and see exception “no crossdomain” …

I’m open to suggestions :slight_smile:

The requirements are quite strange… why using Unity if you can’t use Unity’s features when you are in editor mode ? :smiley:

You can try creating things or using features that are not supported in webplayer. I think that they will throw exceptions, then you can just catch them. Or maybe Webplayer only features.

That’s the only things I found for the moment… Hope it helps.