loki-code/gta-relaunch-exe-
A lightweight GTA San Andreas launcher for SA-MP and open.mp, with quick game restart, configurable hotkeys, and server connection settings.
В этом репозитории нет файла лицензии. Код открыт для чтения, но само по себе это не даёт права использовать его.
README.md
Loki Launcher
A small WPF (.NET 10, Windows) utility that restarts GTA San Andreas and reconnects you to your SA-MP or open.mp server with one hotkey.
What changed from the previous version
The earlier build defaulted to the samp:// protocol link to launch and
connect. That mechanism depends on Windows having a registry entry pointing
samp:// at your installed client - which many open.mp installs (especially
portable/zip extractions, or reinstalls) never set up correctly. When that
registration is missing, Process.Start("samp://...") doesn't throw an
error, it just silently does nothing, which is almost certainly why it
looked "not working."
This version:
- Defaults to direct launch (
-h ip -p port -n name, run against your configured launcher exe) instead of the protocol link. This doesn't depend on any registry state - it's just running an exe with arguments, so it either works or gives you a real error. - Adds
-g <gta folder>automatically for open.mp launches, since open.mp's launcher needs to know where GTA is installed if it isn't bundled in the same folder. - Shows you what happened. Every restart now reports success/failure
text in the main window, and a full log is written to
%AppData%\LokiLauncher\launcher.log(open it from the "View log file" link at the bottom of the window). If a restart silently "does nothing" again, that log will say exactly why. - Fixed the CS8618 warning by initializing the status timer inline.
- Renamed to Loki Launcher, with a redesigned, tighter UI.
If restart still doesn't work
- Click View log file at the bottom of the window right after pressing Restart - it logs every step (closing GTA, launching, any exception).
- Open ⚙ Settings and confirm the two paths are exactly right, and that "Connect method" is set to Direct launch (recommended).
- If your open.mp launcher exe is not in the same folder as
gta_sa.exe, make sure Client type in Settings is set to open.mp so the-gflag gets added - without it, some open.mp builds can't find the game. - Try running your launcher manually once with those same
-h/-p/-narguments from a terminal to confirm it connects outside of this app too (rules out a client-side config issue entirely separate from this tool).
What it does
- First launch asks for the path to
gta_sa.exeand your SA-MP/open.mp launcher executable, plus your player name, and saves them. - Lets you enter and change the server IP + port from the main window.
- Global ALT + ENTER hotkey (works even while GTA is focused/fullscreen):
- Closes the running
gta_sa.exeprocess. - Waits for it to fully exit (graceful close, then force-kill fallback).
- Relaunches through your configured SA-MP/open.mp launcher.
- Connects to the IP/port currently set in the app.
- Closes the running
- A Restart and Reconnect button does the same thing without the hotkey.
- Shows live GTA running/not-running status in the main window.
- Settings persist to
%AppData%\LokiLauncher\settings.json. - Activity/errors are logged to
%AppData%\LokiLauncher\launcher.log.
How the launch/connect step works (verified, not guessed)
Two mechanisms are supported, selectable in Settings:
-
Direct launch (default). Runs your configured launcher exe with
-h <ip> -p <port> -n "<name>"(and-g "<gta folder>"for open.mp) - the documented command-line syntax for bothsamp.exeand open.mp'somp-launcher.exe, confirmed against open.mp's own client documentation and SA-MP's documented client parameters. -
samp://ip:portprotocol link. Both the classic SA-MP client and the open.mp launcher can register themselves as the handler for this URI scheme on install. It's the same mechanism "Connect" buttons on server browser websites use, but it's only reliable if that registration actually happened on your machine - which is why it's no longer the default.
gta_sa.exe itself is never launched directly by this app - it's always
started by the SA-MP/open.mp launcher, exactly like a normal manual launch,
so anti-cheat/injection behavior is unaffected.
Notes / design choices
- No admin elevation. GTA/SA-MP/open.mp normally run unelevated; keeping this app unelevated too avoids UAC friction and keeps the global hotkey behaving normally against the game window.
- Process close is graceful-then-forced.
gta_sa.exeoften ignores a politeWM_CLOSEwhile fullscreen, so the controller triesCloseMainWindow()first, waits, and falls back toKill()if needed. - No database, accounts, telemetry, or network services. Settings are a single local JSON file and a plain text log. That's the entire persistence layer.
Страница собрана из того, что GitHub публикует о репозитории. samp.directory не хранит этот код. Сообщить о проблеме с этой записью