How to Launch a Game/Process
Running an Arbitrary Program/Game
You can import a ready-made example from here: https://eyeauras.net/share/S20240702143616Nj8fr0gCxktL
- Create an aura.
- Add
HotkeyIsActiveto it and bind it to a convenient button (this will be our on/off switch, in the example it'sF3), change the activation type toClick/Hold. - Add a
C# Scriptaction toOn Enter. - Copy and paste the script itself.
- Pressing
F3will launchNotepad.
using System.Diagnostics;
{
using var process = Process.Start("notepad");
// Or supply an existing full path to the executable.
}
Run this in a top-level C# Script Action on Windows. Supply an available program
name or an existing executable path. A game may also need a working directory
configured through ProcessStartInfo. The expected visible result is Notepad.
using releases the Process component; it does not terminate the launched program.
Stopping the script does not stop the child process, and Process.Start accepts
no cancellation token. See Process.Start
and the .NET 8.0.19 Close/Dispose implementation.