mirror of
https://github.com/osukey/osukey.git
synced 2025-05-29 09:27:18 +09:00
Change to int
-only debug client ID
This commit is contained in:
parent
37393a8432
commit
ebd555129f
@ -24,12 +24,23 @@ namespace osu.Desktop
|
|||||||
var cwd = Environment.CurrentDirectory;
|
var cwd = Environment.CurrentDirectory;
|
||||||
|
|
||||||
string gameName = @"osu";
|
string gameName = @"osu";
|
||||||
|
bool tournamentClient = false;
|
||||||
|
|
||||||
if (DebugUtils.IsDebugBuild)
|
foreach (var arg in args.Select(s => s.Split('=')))
|
||||||
{
|
{
|
||||||
var customNameArg = args.SingleOrDefault(s => s.StartsWith(@"--name=", StringComparison.Ordinal));
|
switch (arg[0])
|
||||||
if (customNameArg != null)
|
{
|
||||||
gameName = customNameArg.Replace(@"--name=", string.Empty);
|
case "--tournament":
|
||||||
|
tournamentClient = true;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case "--debug-client-id":
|
||||||
|
if (!DebugUtils.IsDebugBuild)
|
||||||
|
break;
|
||||||
|
|
||||||
|
gameName = $"{gameName}-{int.Parse(arg[1])}";
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
using (DesktopGameHost host = Host.GetSuitableHost(gameName, true))
|
using (DesktopGameHost host = Host.GetSuitableHost(gameName, true))
|
||||||
@ -57,7 +68,7 @@ namespace osu.Desktop
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (args.Contains("--tournament"))
|
if (tournamentClient)
|
||||||
host.Run(new TournamentGame());
|
host.Run(new TournamentGame());
|
||||||
else
|
else
|
||||||
host.Run(new OsuGameDesktop(args));
|
host.Run(new OsuGameDesktop(args));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user