mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-30 04:13:40 +01:00
Offer to restart game from VEH exception handler (#936)
This commit is contained in:
parent
98e421a227
commit
58ceb1dc87
16 changed files with 1279 additions and 616 deletions
|
|
@ -615,6 +615,16 @@ namespace Dalamud.Interface.Internal
|
|||
Service<Dalamud>.Get().Unload();
|
||||
}
|
||||
|
||||
if (ImGui.MenuItem("Restart game"))
|
||||
{
|
||||
[DllImport("kernel32.dll")]
|
||||
[return: MarshalAs(UnmanagedType.Bool)]
|
||||
static extern void RaiseException(uint dwExceptionCode, uint dwExceptionFlags, uint nNumberOfArguments, IntPtr lpArguments);
|
||||
|
||||
RaiseException(0x12345678, 0, 0, IntPtr.Zero);
|
||||
Process.GetCurrentProcess().Kill();
|
||||
}
|
||||
|
||||
if (ImGui.MenuItem("Kill game"))
|
||||
{
|
||||
Process.GetCurrentProcess().Kill();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue