feat: add "kill game" button to console

This commit is contained in:
goat 2021-07-18 17:36:42 +02:00
parent 8931ce75db
commit 28e99f5e4d
No known key found for this signature in database
GPG key ID: F18F057873895461

View file

@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Numerics;
using System.Runtime.InteropServices;
@ -132,43 +133,6 @@ namespace Dalamud.Interface.Internal.Windows
this.dalamud.Configuration.Save();
}
/* TEST */
if (ImGui.Button("Multiline test"))
{
Log.Verbose("This is a test\nTruly a multi-line test\nas it has always been.\nThank you.");
}
if (ImGui.Button("Single line test"))
{
Log.Debug("This is a test");
}
if (ImGui.Button("WARNING!!"))
{
Log.Warning("I want to warn you");
}
if (ImGui.Button("Add 50000"))
{
for (var i = 0; i < 50000; i++)
Log.Debug("TEST " + i);
}
if (ImGui.Button("Exception"))
{
try
{
var a = 0;
var b = 1;
var c = b / a;
}
catch (Exception e)
{
Log.Error(e, "There has been a serious problem");
}
}
ImGui.EndPopup();
}
@ -210,6 +174,10 @@ namespace Dalamud.Interface.Internal.Windows
ImGui.SameLine();
var copy = ImGui.Button(FontAwesomeIcon.Copy.ToIconString());
ImGui.SameLine();
if (ImGui.Button(FontAwesomeIcon.Skull.ToIconString()))
Process.GetCurrentProcess().Kill();
ImGui.PopFont();
ImGui.BeginChild("scrolling", new Vector2(0, ImGui.GetFrameHeightWithSpacing() - 55), false, ImGuiWindowFlags.HorizontalScrollbar);