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

Script Execution Order hard to use

Discussion in 'Editor & General Support' started by iivo_k, Jan 13, 2017.

  1. iivo_k

    iivo_k

    Joined:
    Jan 28, 2013
    Posts:
    314
    With lots of script in a project it's pretty much impossible to find a script from the popup without any proper search (you can only search for the first letter, which is often the first letter of the namespace). Scrolling is a pain in the ass too, since you can't do it with the scroll wheel.

    Adding it to the .meta file directly doesn't seem to work either, so the best way seems to be doing it via script with MonoImporter.SetExecutionOrder.

    Are there any plans to improve this?
     
  2. Dave-Carlile

    Dave-Carlile

    Joined:
    Sep 16, 2012
    Posts:
    967
    Yeah, it's a terrible UI for that once you have a lot of scripts. As a pro, it forces me to organize things so I'm not relying on execution order except in the most extreme cases, e.g. the main game manager.
     
    ArachnidAnimal likes this.
  3. ArachnidAnimal

    ArachnidAnimal

    Joined:
    Mar 3, 2015
    Posts:
    1,727
    Try scrolling through a list of 300 tags too to find the tag you want. Not fun. Adding a new tag takes 30 seconds to scroll to the bottom of the list to find the "Add tag..." choice.

    Also I do what Dave-Carlile suggests and avoid using the script execution order when possible. By using LateUpdate instead of Update, needing to use the SEO can be avoided under certain circumstances. Also moving code out of Awake into Start can be useful in avoiding having to use the SEO.
     
    Last edited: Jan 14, 2017
  4. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,400
    Scroll wheel works fine here, also can't you just hit the page down key to get to the bottom? Because that works here. Not saying that it's a good UI of course, but it's usually enough to just type the first few letters of the script name and hit return, so to me it never registered as being more than mildly annoying.

    --Eric
     
  5. ArachnidAnimal

    ArachnidAnimal

    Joined:
    Mar 3, 2015
    Posts:
    1,727
    Can confirm the scroll wheel and PgDown/PgUp does not work here when trying to choose a tag or add a script to the script execution order. (On Windows 10 using Unity 5.3, so maybe something changed in later versions of Unity?)
    For the tags, I use a "hack" and always make sure the last tag in the list is "z". Then I can hit the "z" key to jump to the bottom of the list immediately. But still, searching for a tag or script in the lists is still a hassle.
     
  6. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,400
    Actually that might be a Windows thing; I think that particular type of popup list is native UI. (On macOS here.)

    --Eric
     
  7. iivo_k

    iivo_k

    Joined:
    Jan 28, 2013
    Posts:
    314
    I guess it's a Windows thing, the way you describe it on Mac sounds usable and like what I'd expect it to be. On Windows you can only search for the first letter, which makes it a huge pain.

    If it's a native component that cannot be fixed by Unity, then a separate search box would be immensely helpful.
     
  8. sand_lantern

    sand_lantern

    Joined:
    Sep 15, 2017
    Posts:
    207
    It would be really nice if there was an improvement to this. Organizing based on namespace with nested values similar to how the shader dropdown works would be fantastic. As it is, it's probably one of the most frustrating aspects of using Unity.
     
  9. villevli

    villevli

    Joined:
    Jan 19, 2016
    Posts:
    86
    It should be noted that you can drag scripts from the Project window into the execution order.
    And the fastest way to navigate that popup list on windows is by holding the arrow keys.
     
    sand_lantern likes this.
  10. sand_lantern

    sand_lantern

    Joined:
    Sep 15, 2017
    Posts:
    207
    The dragging is a lifesend. The arrow keys are next to useless when you have lots of scripts.
     
  11. LazyKnight

    LazyKnight

    Joined:
    Jul 28, 2017
    Posts:
    7
    Well, seem unity on macOS is awesome.

    Thank you, Eric.