Fix utility to use Platform.SupportDir (#1067); drop the --SupportDir arg and the path passed to --settings-value; Update OSX launcher to match.
This commit is contained in:
@@ -74,7 +74,6 @@ extern char **environ;
|
||||
|
||||
NSMutableArray *taskArgs = [NSMutableArray arrayWithObjects:@"OpenRA.Utility.exe",
|
||||
@"--settings-value",
|
||||
[@"~/Library/Application Support/OpenRA" stringByExpandingTildeInPath],
|
||||
@"Graphics.Mode", nil];
|
||||
|
||||
[task setCurrentDirectoryPath:gamePath];
|
||||
@@ -91,7 +90,7 @@ extern char **environ;
|
||||
defaultButton:@"Quit"
|
||||
alternateButton:nil
|
||||
otherButton:nil
|
||||
informativeTextWithFormat:@"OpenRA.Utility.exe returned an error and cannot continue."];
|
||||
informativeTextWithFormat:@"OpenRA.Utility returned an error and cannot continue.\n\nA log has been saved to ~/Library/Application Support/OpenRA/Logs/utility.log"];
|
||||
|
||||
[alert runModal];
|
||||
[[NSApplication sharedApplication] terminate:self];
|
||||
@@ -115,7 +114,6 @@ extern char **environ;
|
||||
gamePath,
|
||||
monoPath,
|
||||
[NSString stringWithFormat:@"UtilityPath=%@", [[NSBundle mainBundle] executablePath]],
|
||||
[NSString stringWithFormat:@"SupportDir=%@",[@"~/Library/Application Support/OpenRA" stringByExpandingTildeInPath]],
|
||||
nil];
|
||||
FSRef appRef;
|
||||
CFURLGetFSRef((CFURLRef)[NSURL URLWithString:[[[NSBundle mainBundle] executablePath] stringByAddingPercentEscapesUsingEncoding:NSASCIIStringEncoding]], &appRef);
|
||||
|
||||
Binary file not shown.
@@ -13,7 +13,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
/* When launching a mod, the arguments are of the form
|
||||
* --launch <game dir> <mono path> <utility path> <support dir option> <mod option> */
|
||||
if (argc >= 7 && strcmp(argv[1], "--launch") == 0)
|
||||
if (argc >= 6 && strcmp(argv[1], "--launch") == 0)
|
||||
{
|
||||
/* Change into the game dir */
|
||||
chdir(argv[3]);
|
||||
@@ -24,7 +24,6 @@ int main(int argc, char *argv[])
|
||||
"--debug",
|
||||
"OpenRA.Game.exe",
|
||||
argv[5],
|
||||
argv[6],
|
||||
NULL
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user