mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
namespace and SeString read change
This commit is contained in:
parent
4bf1e0f679
commit
40bdd6b41c
6 changed files with 9 additions and 26 deletions
|
|
@ -5,10 +5,11 @@ using System.Threading.Tasks;
|
|||
|
||||
using Dalamud.Game.Text.SeStringHandling;
|
||||
using Dalamud.Hooking;
|
||||
using Dalamud.Memory;
|
||||
using FFXIVClientStructs.FFXIV.Client.UI;
|
||||
using Serilog;
|
||||
|
||||
namespace Dalamud.Game.Gui
|
||||
namespace Dalamud.Game.Gui.FlyText
|
||||
{
|
||||
/// <summary>
|
||||
/// This class facilitates interacting with and creating native in-game "fly text".
|
||||
|
|
@ -205,8 +206,8 @@ namespace Dalamud.Game.Gui
|
|||
var tmpKind = (FlyTextKind)kind;
|
||||
var tmpVal1 = val1;
|
||||
var tmpVal2 = val2;
|
||||
var tmpText1 = this.Dalamud.SeStringManager.Parse(text1);
|
||||
var tmpText2 = this.Dalamud.SeStringManager.Parse(text2);
|
||||
var tmpText1 = MemoryHelper.ReadSeString(text1);
|
||||
var tmpText2 = MemoryHelper.ReadSeString(text2);
|
||||
var tmpColor = color;
|
||||
var tmpIcon = icon;
|
||||
var tmpYOffset = yOffset;
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
using System;
|
||||
using System;
|
||||
|
||||
namespace Dalamud.Game.Gui
|
||||
namespace Dalamud.Game.Gui.FlyText
|
||||
{
|
||||
/// <summary>
|
||||
/// An address resolver for the <see cref="FlyTextGui"/> class.
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
namespace Dalamud.Game.Gui
|
||||
namespace Dalamud.Game.Gui.FlyText
|
||||
{
|
||||
/// <summary>
|
||||
/// Enum of FlyTextKind values. Members suffixed with
|
||||
|
|
@ -3,6 +3,7 @@ using System.Numerics;
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
using Dalamud.Game.Gui.Addons;
|
||||
using Dalamud.Game.Gui.FlyText;
|
||||
using Dalamud.Game.Gui.PartyFinder;
|
||||
using Dalamud.Game.Text.SeStringHandling.Payloads;
|
||||
using Dalamud.Hooking;
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
using Dalamud.Data;
|
||||
using Dalamud.Game.Text.SeStringHandling.Payloads;
|
||||
|
|
@ -49,24 +47,6 @@ namespace Dalamud.Game.Text.SeStringHandling
|
|||
return new SeString(payloads);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Parse a binary game message into an SeString.
|
||||
/// </summary>
|
||||
/// <param name="bytePtr">Pointer to a binary message payload data in SE's internal format.</param>
|
||||
/// <returns>An SeString containing parsed Payload objects for each payload in the data.</returns>
|
||||
public SeString Parse(IntPtr bytePtr)
|
||||
{
|
||||
var bytes = new List<byte>();
|
||||
byte read = Marshal.ReadByte(bytePtr, 0);
|
||||
for (int ofs = 1; read != 0; ofs++)
|
||||
{
|
||||
bytes.Add(read);
|
||||
read = Marshal.ReadByte(bytePtr, ofs);
|
||||
}
|
||||
|
||||
return this.Parse(bytes.ToArray());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates an SeString representing an entire Payload chain that can be used to link an item in the chat log.
|
||||
/// </summary>
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ using Dalamud.Game.ClientState.JobGauge.Types;
|
|||
using Dalamud.Game.ClientState.Objects.SubKinds;
|
||||
using Dalamud.Game.ClientState.Objects.Types;
|
||||
using Dalamud.Game.Gui.Addons;
|
||||
using Dalamud.Game.Gui.FlyText;
|
||||
using Dalamud.Game.Gui.Toast;
|
||||
using Dalamud.Game.Text;
|
||||
using Dalamud.Interface.Windowing;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue