Skip to content
This repository has been archived by the owner on Nov 8, 2021. It is now read-only.

Commit

Permalink
Launch Steam on "Start Server"
Browse files Browse the repository at this point in the history
  • Loading branch information
polygraphene committed Jun 27, 2018
1 parent cca3d55 commit c42e141
Show file tree
Hide file tree
Showing 7 changed files with 119 additions and 72 deletions.
3 changes: 3 additions & 0 deletions ALVR/App.config
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@
<setting name="codec" serializeAs="String">
<value>1</value>
</setting>
<setting name="onlySteamVR" serializeAs="String">
<value>False</value>
</setting>
</ALVR.Properties.Settings>
</userSettings>
</configuration>
151 changes: 83 additions & 68 deletions ALVR/Launcher.Designer.cs

Large diffs are not rendered by default.

9 changes: 8 additions & 1 deletion ALVR/Launcher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,14 @@ private void LaunchServer()
return;
}

Process.Start("vrmonitor:");
if (Properties.Settings.Default.onlySteamVR)
{
Utils.LaunchOnlySteamVR();
}
else
{
Utils.LaunchSteam();
}
}

private bool SaveConfig()
Expand Down
3 changes: 0 additions & 3 deletions ALVR/Launcher.resx
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,6 @@
<metadata name="resolutionBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>303, 17</value>
</metadata>
<metadata name="resolutionBindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>303, 17</value>
</metadata>
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
Expand Down
12 changes: 12 additions & 0 deletions ALVR/Properties/Settings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions ALVR/Properties/Settings.settings
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,8 @@
<Setting Name="codec" Type="System.Int32" Scope="User">
<Value Profile="(Default)">1</Value>
</Setting>
<Setting Name="onlySteamVR" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
</Settings>
</SettingsFile>
10 changes: 10 additions & 0 deletions ALVR/Utils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,15 @@ public static Process ExecuteProcess(string path, string args)
}
return process;
}

public static void LaunchOnlySteamVR()
{
Process.Start("vrmonitor:");
}

public static void LaunchSteam()
{
Process.Start("steam://run/250820");
}
}
}

0 comments on commit c42e141

Please sign in to comment.