From d49a066424315620aae7c6b4a6ec47b38219d2d5 Mon Sep 17 00:00:00 2001 From: Katy Coe Date: Wed, 16 Oct 2019 16:18:44 +0200 Subject: [PATCH] Add ReadMappedNullTerminatedString --- Il2CppInspector/FileFormatReader.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Il2CppInspector/FileFormatReader.cs b/Il2CppInspector/FileFormatReader.cs index c03d22c..a91de42 100644 --- a/Il2CppInspector/FileFormatReader.cs +++ b/Il2CppInspector/FileFormatReader.cs @@ -31,6 +31,7 @@ namespace Il2CppInspector uint ReadUInt32(); ushort ReadUInt16(); byte ReadByte(); + string ReadMappedNullTerminatedString(uint uiAddr); } internal class FileFormatReader : BinaryObjectReader, IFileFormatReader where T : FileFormatReader @@ -91,6 +92,10 @@ namespace Il2CppInspector return ReadArray(MapVATR(uiAddr), count); } + public string ReadMappedNullTerminatedString(uint uiAddr) { + return ReadNullTerminatedString(MapVATR(uiAddr)); + } + // Perform file format-based post-load manipulations to the IL2Cpp data public virtual void FinalizeInit(Il2CppBinary il2cpp) { } }