mirror of
https://github.com/goatcorp/Dalamud.git
synced 2026-02-20 06:47:44 +01:00
Describe address for debugging, change PresentDetour viewport handling (#1943)
* Describe memory address when printed in log/debug utilities * PresentDetour: Compare against game's internal copy of IDXGISwapChain * Handle ReShade on_present function signature properly
This commit is contained in:
parent
eed7abed12
commit
1109e64552
26 changed files with 445 additions and 591 deletions
|
|
@ -50,7 +50,7 @@ internal unsafe class AddonWidget : IDataWindowWidget
|
|||
|
||||
var addon = (FFXIVClientStructs.FFXIV.Component.GUI.AtkUnitBase*)address;
|
||||
var name = addon->NameString;
|
||||
ImGui.TextUnformatted($"{name} - 0x{address.ToInt64():X}\n v:{addon->IsVisible} x:{addon->X} y:{addon->Y} s:{addon->Scale}, w:{addon->RootNode->Width}, h:{addon->RootNode->Height}");
|
||||
ImGui.TextUnformatted($"{name} - {Util.DescribeAddress(address)}\n v:{addon->IsVisible} x:{addon->X} y:{addon->Y} s:{addon->Scale}, w:{addon->RootNode->Width}, h:{addon->RootNode->Height}");
|
||||
|
||||
if (ImGui.Button("Find Agent"))
|
||||
{
|
||||
|
|
@ -59,7 +59,7 @@ internal unsafe class AddonWidget : IDataWindowWidget
|
|||
|
||||
if (this.findAgentInterfacePtr != nint.Zero)
|
||||
{
|
||||
ImGui.TextUnformatted($"Agent: 0x{this.findAgentInterfacePtr.ToInt64():X}");
|
||||
ImGui.TextUnformatted($"Agent: {Util.DescribeAddress(this.findAgentInterfacePtr)}");
|
||||
ImGui.SameLine();
|
||||
|
||||
if (ImGui.Button("C"))
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
using System.Collections.Generic;
|
||||
|
||||
using Dalamud.Game;
|
||||
using Dalamud.Utility;
|
||||
|
||||
using ImGuiNET;
|
||||
|
||||
|
|
@ -57,7 +58,7 @@ internal class AddressesWidget : IDataWindowWidget
|
|||
foreach (var valueTuple in debugScannedValue.Value)
|
||||
{
|
||||
ImGui.TextUnformatted(
|
||||
$" {valueTuple.ClassName} - 0x{valueTuple.Address.ToInt64():X}");
|
||||
$" {valueTuple.ClassName} - {Util.DescribeAddress(valueTuple.Address)}");
|
||||
ImGui.SameLine();
|
||||
|
||||
if (ImGui.Button($"C##{valueTuple.Address.ToInt64():X}"))
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
using Dalamud.Game.ClientState.Conditions;
|
||||
using Dalamud.Utility;
|
||||
|
||||
using ImGuiNET;
|
||||
|
||||
|
|
@ -30,7 +31,7 @@ internal class ConditionWidget : IDataWindowWidget
|
|||
var condition = Service<Condition>.Get();
|
||||
|
||||
#if DEBUG
|
||||
ImGui.Text($"ptr: 0x{condition.Address.ToInt64():X}");
|
||||
ImGui.Text($"ptr: {Util.DescribeAddress(condition.Address)}");
|
||||
#endif
|
||||
|
||||
ImGui.Text("Current Conditions:");
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
using Dalamud.Game.ClientState.GamePad;
|
||||
using Dalamud.Utility;
|
||||
|
||||
using ImGuiNET;
|
||||
|
||||
|
|
@ -29,14 +30,14 @@ internal class GamepadWidget : IDataWindowWidget
|
|||
{
|
||||
var gamepadState = Service<GamepadState>.Get();
|
||||
|
||||
ImGui.Text($"GamepadInput 0x{gamepadState.GamepadInputAddress.ToInt64():X}");
|
||||
ImGui.Text($"GamepadInput {Util.DescribeAddress(gamepadState.GamepadInputAddress)}");
|
||||
|
||||
#if DEBUG
|
||||
if (ImGui.IsItemHovered())
|
||||
ImGui.SetMouseCursor(ImGuiMouseCursor.Hand);
|
||||
|
||||
if (ImGui.IsItemClicked())
|
||||
ImGui.SetClipboardText($"0x{gamepadState.GamepadInputAddress.ToInt64():X}");
|
||||
ImGui.SetClipboardText($"{Util.DescribeAddress(gamepadState.GamepadInputAddress)}");
|
||||
#endif
|
||||
|
||||
this.DrawHelper(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue