Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Undocumented (but public) DefaultExecutionOrder attribute

Discussion in 'Documentation' started by any_user, May 9, 2018.

  1. Rabadash8820


    Aug 20, 2015
    Then don't. You still don't need to hijack an existing thread.

    That is a personal issue that doesn't belong on this thread.

    Believe me, I've felt your frustration with Unity. I feel it almost every day lol. If you're done with Unity, then be done; no judgement here. But venting on the forums just gets everybody heated and helps no one.
  2. seoyeon222222


    Nov 18, 2020

    Is it really "same rules exactly"?
    - [DefaultExecutionOrder( value )]
    - Project Settings Add Script Execution Order (value)
    I'm having trouble with these two way causing different results.
    I was able to reproduce this in a light sample project.

    But there is no official document on this.
    So I'm reluctant to report because I'm not sure if this is a bug.
    There is an A class that inherits MonoBehaviour.
    There is B who inherits A
    Scene has GameObejct with B attached.
    Modifying A's DefaultExecutionOrder way, it works as intended.
    However, if you modify Project Settings way, with the same value, it does not work as intended.

    I'm not going to go deeper on this because I've roughly figured out the cause and the solution.

    I know this thread is about "documents",
    I don't want to discuss here a solution to the suspected bug.

    I'm just writing Reply because CharlesWard(Unity) comments on the DefaultExecutionOrder are in this thread.
  3. Pyr3z


    Jul 6, 2017
    Back on topic, how hard is it really to add a new documentation page? Isn't most of the first pass generated by comments?

    oh wait just checked, the UnityEngine.CoreModule.dll has no comments for the DefaultExecutionOrder class... so that's why it's taken 5 years! :)

    Even if the content is literally just "See related page:", at least that meets the minimum effort.

    My boring story = I've been using this attribute for years now, and now that I need to backport some internal package code to support a bunch of older Unity versions, I'm having to go figure out minimum versions for certain APIs. Anything and everything without even minimum-effort documentation is proving to be a real pain in the arse...
  4. tonytopper


    Jun 25, 2018
    Still undocumented.

    Another issue here is the values don't show up on the Script Execution Order in the Project Settings options, which from a UX standpoint, they should. That page in the Project Settings really should be a source of truth for Script Execution Order information in your project.

    Maybe DefaultExecutionOrder classes should be displayed in the Project Settings but be disabled since contradictory values in two places might be a headache.
    FlightOfOne and bdovaz like this.