Opened 11 years ago
Closed 10 years ago
#78 closed defect (fixed)
Run Oni buttons bypass launch_args.txt in Intel Mac build
Reported by: | Iritscen | Owned by: | Christian |
---|---|---|---|
Priority: | major | Component: | AEI2/UI |
Keywords: | Cc: |
Description
When Feral added launch_args.txt to the Intel Oni build that most Mac users are using now (1.1b5), they made it so that it serves as an alternative to having to launch the Oni binary from the CLI in order to pass it launch arguments. This became useful because a number of args were added to Mac Oni for things like FSAA, and we can use the .txt file to basically "save our preferences" by storing the launch args in there.
Now if we want to temporarily bypass the contents of launch_args.txt, we can still launch Oni from the CLI, and if any args are passed in, Oni will use those and ignore launch_args.txt (in the case of no CLI args, launch_args.txt will still be read during a CLI launch of Oni). While this makes sense, it causes a problem for the AEI's Run Oni buttons because any settings the user is storing in launch_args.txt are ignored when the AEI launches Oni.
This is because the AEI is launching Oni CLI-style, and passing it -debugfiles, and -noswitch if the "windowed" button is clicked. Now, I don't know what -debugfiles does in Windows, but it seems to be useless on Macs. If you were not passing that, then at least the "fullscreen" button would work properly, allowing Oni to read launch_args.txt, but clicking the "windowed" button would still bypass launch_args.txt because of that -noswitch.
I don't want to suggest anything too complicated; I think the simplest solution is just to give us one Run Oni button on the Mac (no "fullscreen" or "windowed"), since the player already has launch_args.txt at his disposal in order to set windowed mode on/off.
Slightly more complicated (if you wanted) would be to read launch_args.txt and look for "-noswitch", and if the user clicks the "windowed" button but launch_args.txt does not have -noswitch, warn the user that he has to choose whether to launch Oni with -noswitch and none of his launch_args.txt args, or else launch Oni fullscreen with his saved args.
Attachments (1)
Change History (7)
comment:1 by , 11 years ago
comment:2 by , 11 years ago
I was thinking of suggesting that (it was my 3rd most complicated idea after the -noswitch warning :-), but I didn't know if you'd want to go to the trouble.
comment:3 by , 11 years ago
What's the format of the LA-file? Just a single line containing the cmd-line params? That would be simple string-find/replace/concat ... nothing fancy ;)
That could even work on both platforms, i.e. a existing LA-file on Windows could be handled the same by AEI.
comment:4 by , 11 years ago
Yes, it's just a space-separated line of arguments. I think there's a sample file in the beta release: http://oni.bungie.org/community/forum/viewtopic.php?pid=31710#p31710.
by , 11 years ago
Attachment: | launch_args.txt added |
---|
comment:5 by , 11 years ago
I see the beta build only had one argument in its LA file, so attached is a better example.
Why not simply always pass the params from launch-args, -noswitch adapter for full/window (i.e. if windowed and LA does not contain -noswitch, add it, if fullscreen and LA does contain -noswitch remove it)?