Search Unity

  1. Unity 2019.1 beta is now available.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. We're looking for insight from anyone who has experience with game testing to help us better Unity. Take our survey here. If chosen to participate you'll be entered into a sweepstake to win an Amazon gift card.
    Dismiss Notice
  4. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  5. Unity 2018.3 is now released.
    Dismiss Notice
  6. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

Execute editor window scripts when project errors are present

Discussion in 'Extensions & OnGUI' started by Aridez, Feb 2, 2019.

  1. Aridez

    Aridez

    Joined:
    Feb 12, 2014
    Posts:
    9
    Hi!

    I'm trying to publish another asset to the asset store, but this one integrates some third party libraries. I was told that I couldn't submit these libraries directly within my package (even with their licenses) so I wanted to allow the users to download the dependencies with just a click through an editor window.

    But I found that when there are errors on the project the editor window scripts won't run, and of course, without these third-party dependencies the project has some errors upon being downloaded. I was told to just put a disclaimer on the page and on the README file, but I'd really like to make things easier for anyone downloading this asset.

    Is there any way to force the execution of editor window scripts? Or is there any way to ignore the "missing assembly reference" errors?
     
  2. Madgvox

    Madgvox

    Joined:
    Apr 13, 2014
    Posts:
    516
    You'd have to wrap your third party code in conditional execution statements, then try to detect the existence of the third party libraries on initialize and inject the conditional statement into the project settings, then trigger an assembly reload.
     
  3. MrMatthias

    MrMatthias

    Joined:
    Sep 18, 2012
    Posts:
    135
    or you have some bootstrap code that will install your asset which is in a unity package. But I would probably choose a different library, since the license of your library will extend to the content of your customers, at least that's what i assume is the reason for rejecting your asset.

    The relevant section in the asset store provider agreement states:
     
    Last edited: Feb 3, 2019
  4. Aridez

    Aridez

    Joined:
    Feb 12, 2014
    Posts:
    9
    I contacted them and told me that it was enough to specify in a "third-parties.txt" file which dependencies I had and where their licenses where. Thanks for the replies!