Skip to content

Commit

Permalink
Fix pattern scan for ac6 1.1.2. Update event flag logger.
Browse files Browse the repository at this point in the history
  • Loading branch information
FrankvdStam committed Sep 11, 2023
1 parent fbb8730 commit 76391e3
Show file tree
Hide file tree
Showing 11 changed files with 29 additions and 5 deletions.
Binary file modified Components/SoulMemory.dll
Binary file not shown.
Binary file modified Components/SoulSplitter.dll
Binary file not shown.
10 changes: 10 additions & 0 deletions Components/Updates.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<updates>
<update version="1.5.2">
<files>
<file path="Components/SoulMemory.dll" status="changed"/>
<file path="Components/SoulSplitter.dll" status="changed"/>
</files>
<changelog>
<change>AC6 fix pattern scan for 1.1.2</change>
<change>AC6 fix event flag logger hook being removed by anti cheat</change>
</changelog>
</update>
<update version="1.5.1">
<files>
<file path="Components/SoulMemory.dll" status="changed"/>
Expand Down
17 changes: 15 additions & 2 deletions src/SoulMemory/ArmoredCore6/ArmoredCore6.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
using System;
using System.Diagnostics;
using System.Linq;
using SoulMemory.MemoryV2.PointerTreeBuilder;

namespace SoulMemory.ArmoredCore6
{
Expand All @@ -36,7 +37,7 @@ public ArmoredCore6(IProcessHook processHook = null)
_menuMan = new Pointer(_armoredCore6);

_armoredCore6.PointerTreeBuilder
.ScanRelative("CSEventFlagMan", "48 8b 35 20 4a df 03 83 f8 ff 0f 44 c1", 3, 7)
.ScanRelative("CSEventFlagMan", "48 8b 35 ? ? ? ? 83 f8 ff 0f 44 c1", 3, 7)
.AddPointer(_eventFlagMan, 0, 0);

_armoredCore6.PointerTreeBuilder
Expand Down Expand Up @@ -76,7 +77,19 @@ public bool IsLoadingScreenVisible()

public SoulMemory.Memory.TreeBuilder GetTreeBuilder()
{
throw new NotImplementedException();
var builder = new SoulMemory.Memory.TreeBuilder();
foreach (var node in _armoredCore6.PointerTreeBuilder.Tree)
{
if (node.PointerNodeType == PointerNodeType.RelativeScan)
{
builder.ScanRelative(node.Name, node.Pattern, node.AddressOffset, node.InstructionSize);
}
if (node.PointerNodeType == PointerNodeType.AbsoluteScan)
{
builder.ScanAbsolute(node.Name, node.Pattern, node.AddressOffset);
}
}
return builder;
}

public Process GetProcess() => _armoredCore6.ProcessWrapper.GetProcess();
Expand Down
2 changes: 1 addition & 1 deletion src/SoulMemory/SoulMemory.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<Platforms>x64</Platforms>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<Title>SoulMemory</Title>
<Version>1.5.1</Version>
<Version>1.5.2</Version>
<Authors>Frank v.d. Stam</Authors>
<PackageProjectUrl>https://github.com/FrankvdStam/SoulSplitter</PackageProjectUrl>
<RepositoryUrl>https://github.com/FrankvdStam/SoulSplitter</RepositoryUrl>
Expand Down
2 changes: 1 addition & 1 deletion src/SoulSplitter/SoulSplitter.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<UseWPF>true</UseWPF>
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
<Title>SoulSplitter</Title>
<Version>1.5.1</Version>
<Version>1.5.2</Version>
<Authors>Frank v.d. Stam</Authors>
<PackageProjectUrl>https://github.com/FrankvdStam/SoulSplitter</PackageProjectUrl>
<RepositoryUrl>https://github.com/FrankvdStam/SoulSplitter</RepositoryUrl>
Expand Down
Binary file modified src/SoulSplitter/soulmemory-rs/x64/launcher.exe
Binary file not shown.
Binary file modified src/SoulSplitter/soulmemory-rs/x64/soulmemory_rs.dll
Binary file not shown.
Binary file modified src/SoulSplitter/soulmemory-rs/x86/launcher.exe
Binary file not shown.
Binary file modified src/SoulSplitter/soulmemory-rs/x86/soulmemory_rs.dll
Binary file not shown.
3 changes: 2 additions & 1 deletion src/cli/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ internal class Program
[STAThread]
static void Main(string[] args)
{
ValidatePatterns();

GameLoop<DarkSouls3>((e) =>
GameLoop<ArmoredCore6>((e) =>
{
Console.WriteLine(e.GetInGameTimeMilliseconds());
Expand Down

0 comments on commit 76391e3

Please sign in to comment.