Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

What's the resolution dialog replacement?

Discussion in '2019.3 Beta' started by Rowlan, Oct 17, 2019.

  1. mrekuc

    mrekuc

    Joined:
    Apr 17, 2009
    Posts:
    116
    I feel like this example just made it even more confusing. Where is ScreenSelectorPrefs.txt and PersistentDataPath.txt?

    How does this work? Because if I launch the app i get an error

    WindowsPlayer.exe "The Code execution cannot proceed because UnityPlayer.dll was not foun. Reinstalling the program may fix this problem"

    I am on 2019.3 and everything works fine besides this example.
     
  2. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,628
    Did you open the supplied project in Unity and build it? Both of those files are generated by the Unity project.

    Unity outputs UnityPlayer.dll when you build the project to Windows.
     
  3. Kamyker

    Kamyker

    Joined:
    May 14, 2013
    Posts:
    1,084
    To be honest resolution dialog should be replaced by a simple Unity scene that runs in windowed mode.

    Currently we can make custom solution and after hitting play it would restart the game with correct command lines. Unfortunately:
    - it would show "Made with Unity" twice
    - Application.OpenURL used to restart the game can't take command lines
    - Process.Start doesn't work on IL2CPP

    In my case I have a full NET Core console app alongside Unity project that is opened with a native plugin. That way I can use whole Process api in il2cpp game using this kind of weird proxy.
     
    Last edited: Feb 11, 2020
  4. mrekuc

    mrekuc

    Joined:
    Apr 17, 2009
    Posts:
    116
    @Tautvydas-Zilys
    I get the build process and what its creating but what about source code besides the search these directories scripts? How can we customize display name and that? What I dont see is what's actually being used other then use the "LauncherExecutable". How is it being moved to the other screen? What's inside the "LauncherExecutable" that allows it to move screens? That sort of thing.
     
  5. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,628
    The source code for that executable is next to the Unity project: https://github.com/Unity-Technologies/DesktopSamples/tree/master/ScreenSelectorExample/WindowsPlayer
     
    Rowlan likes this.
  6. mrekuc

    mrekuc

    Joined:
    Apr 17, 2009
    Posts:
    116
    FYI this does work fine if you are only using 1 display, but if you have more then 1 like i am working with it does not work.
     
  7. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,628
    What exactly doesn't work? We tested it with up to 3 monitors connected and it seemed to work fine.
     
  8. mrekuc

    mrekuc

    Joined:
    Apr 17, 2009
    Posts:
    116
    I have 3 monitors. If I only want 1 display active and use it to put it on screen 2 instead of 1 it works. When I have 2 displays active and want them on screen 2 and 3 instead of 1 and 2 it always pops back to screen 1 and 2 and not 2 and 3.
     
  9. Skymorphis

    Skymorphis

    Joined:
    May 4, 2017
    Posts:
    17
    I'm really sad y'all got rid of this dialog, I literally don't know anyone that didn't use it extensively during production.
     
    Ony, jashan and Lars-Steenhoff like this.
  10. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    5,015
  11. jashan

    jashan

    Joined:
    Mar 9, 2007
    Posts:
    3,307
    I know I'm late to the party - but when the thing was deprecated, the deprecation message didn't have a link to this thread so I just ran into it by chance five minutes ago.

    Actually nope, the cool thing about the built-in resolution dialog was that you could hide it by default but show it when alt was pressed while the game was starting up. That was tremendously useful if you wanted to switch back and forth between full-screen and non-fullscreen while starting the game.

    I did never use the input-stuff and wouldn't have minded if that would have been removed because it's super-obsolete, anyways. But losing the resolution dialog really sucked.

    Also, for the purpose we used it for, the crappy design wasn't a problem.

    FYI, the SteamVR Unity plugin automatically activated this in projects - so everyone using that plugin built their games with it hidden by default. And I actually remember telling quite a few players about it (tbh, I don't exactly remember the use case but I believe it was to be able to start VR games with minimized resolutions for performance reasons, even if the game only supported opening in fullscreen with the default resolution).
     
    float likes this.
  12. float

    float

    Joined:
    Jul 29, 2012
    Posts:
    42
    Yes it was ugly and yes, i nearlly never used it but the feedback here is quite clear. The customer is always right.

    I find it a bit akward that the Demo-Launcher is written in C++ when the Main-Language that the users have contact with, is C# (at least when it comes to Unity).

    Anyway...
    A few years back a person made a tutorial for a simple launcher with c# ->

    I think with a few simple System-Checks (Screen-Class) a full launcher with all the extra-args for Unity can be made.
     
  13. bran76765

    bran76765

    Joined:
    Jul 14, 2018
    Posts:
    26
    Hey all, I'm late to the party as well and I'm just wondering something about the reason for the deprecation as well as this new one:

    If different users had different machines, this resolution dialog could let the user choose their quality level before heading ingame. Why was this removed and how are players supposed to choose their quality level before heading ingame now? This new system seems to just be a part of the game, not the engine choosing the settings, and I'm partially ok with that, but it still begs the question:

    For users not using the new asset in this thread, what's the point of the quality levels anymore since they can't be chosen by the user?

    I'll probably eventually end up going for this asset but unity can't have removed a feature that makes one of their own settings obsolete now without a replacement...right?
     
  14. Right, because luckily it doesn't make the quality settings obsolete.
     
  15. bran76765

    bran76765

    Joined:
    Jul 14, 2018
    Posts:
    26
    How so? I'd love to be proven wrong but the user can't choose the quality level without this asset now, which means one quality level will be used for all users/machines. Or am I wrong on that? If I am please tell me how because I don't see a way currently for the user to select their quality level beforehand.
     
  16. brunocoimbra

    brunocoimbra

    Joined:
    Sep 2, 2015
    Posts:
    679
    You can create your own options menu using the quality settings there, as any other game has.
     
  17. Moonstorm

    Moonstorm

    Joined:
    Jul 26, 2012
    Posts:
    23
    So you want Unity to make product-wide decisions based on the convenience of your 48 hour game jam? lol

    It's a tough balancing act deciding which features to maintain and which ones not to maintain. Having this feature is another thing that Unity has to test, maintain, and manage. If they realized most people aren't really using this and that it's some fat that can be trimmed off, they should be able to do so. In this case, I think they made the right call, especially since they did their research and let their data do the talking. Unity is ultimately a professional tool, not optimized for gamejams.
     
  18. Lars-Steenhoff

    Lars-Steenhoff

    Joined:
    Aug 7, 2007
    Posts:
    3,509
    I'm pretty sure the data thst they used to make this decision on is not representarive for most unity users.

    It was probably moslty big studios that they asked
     
  19. deus0

    deus0

    Joined:
    May 12, 2015
    Posts:
    256
    MoveWindow doesn't work on linux though, what is a solution for this? Or mac?
     
  20. nbg_yalta

    nbg_yalta

    Joined:
    Oct 3, 2012
    Posts:
    378
    put damn checkbox back
     
  21. shahiltp_aramco

    shahiltp_aramco

    Joined:
    Apr 5, 2020
    Posts:
    4
    i have first monitor with low resolution and second monitior which is looking glass which resolution differ based on device
     
  22. arkon

    arkon

    Joined:
    Jun 27, 2011
    Posts:
    1,122
    Unity standalone Mac implementation is a shambles after all these years its still crap. I need a windowed app on standalone with no title bar, title and no close, min and max buttons, but can I do that? no! All the answers on the web involve hacking with a windows dll, so only works on windows standalone. What about Mac standalone? Also all web answers also say to pass command line parameters to the app, something else you can't really do on a Mac. Also when you post Mac OSX questions on the forum you rarely get answers. Unity really is S*** if it can't do basic windowed stuff like this. I also have games that used the resolution dialog box that has now gone! Also when you call Screen.GetResoulotion on a MacBook the return results are hit and miss.
     
  23. jmacaling001

    jmacaling001

    Joined:
    Jul 21, 2021
    Posts:
    1
    shawnomatic likes this.