Skip to content

Commit

Permalink
Add new find pattern macro to SeqActLog Enabler, update ASI versions
Browse files Browse the repository at this point in the history
  • Loading branch information
henbagle committed Aug 23, 2021
1 parent 91eea78 commit d2d5693
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 16 deletions.
4 changes: 2 additions & 2 deletions KismetLogger/KismetLogger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@

#define MYHOOK "KismetLogger_"

SPI_PLUGINSIDE_SUPPORT(L"KismetLogger", L"1.0.0", L"HenBagle", SPI_GAME_LE1, SPI_VERSION_ANY);
SPI_PLUGINSIDE_SUPPORT(L"KismetLogger", L"2.0.0", L"HenBagle", SPI_GAME_LE1, SPI_VERSION_ANY);
SPI_PLUGINSIDE_POSTLOAD;
SPI_PLUGINSIDE_ASYNCATTACH;

ME3TweaksASILogger logger("Kismet Logger v1", "KismetLog.txt");
ME3TweaksASILogger logger("Kismet Logger v2", "KismetLog.txt");



Expand Down
2 changes: 1 addition & 1 deletion LE1StreamingLevelsHUD/LE1StreamingLevelsHUD.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

#define SLHHOOK "LE1StreamingLevelsHUD_"

SPI_PLUGINSIDE_SUPPORT(L"LE1StreamingLevelsHUD", L"Mgamerz", L"1.0.0", SPI_GAME_LE1, SPI_VERSION_LATEST);
SPI_PLUGINSIDE_SUPPORT(L"LE1StreamingLevelsHUD", L"Mgamerz", L"2.0.0", SPI_GAME_LE1, SPI_VERSION_LATEST);
SPI_PLUGINSIDE_POSTLOAD;
SPI_PLUGINSIDE_ASYNCATTACH;

Expand Down
17 changes: 4 additions & 13 deletions SeqActLog Enabler/LE1SeqActLogEnabler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@

#define MYHOOK "LE1SeqActLogEnabler_"

SPI_PLUGINSIDE_SUPPORT(L"LE1SeqActLogEnabler", L"1.0.0", L"HenBagle", SPI_GAME_LE1, SPI_VERSION_ANY);
SPI_PLUGINSIDE_SUPPORT(L"LE1SeqActLogEnabler", L"2.0.0", L"HenBagle", SPI_GAME_LE1, SPI_VERSION_ANY);
SPI_PLUGINSIDE_POSTLOAD;
SPI_PLUGINSIDE_ASYNCATTACH;

ME3TweaksASILogger logger("SeqAct_Log Enabler v1", "SeqActLog.txt");
ScreenLogger screenLogger(L"SeqAct_Log Enabler v1");
ME3TweaksASILogger logger("SeqAct_Log Enabler v2", "SeqActLog.txt");
ScreenLogger screenLogger(L"SeqAct_Log Enabler v2");


std::wstringstream& operator<<(std::wstringstream& ss, const FString& fStr)
Expand Down Expand Up @@ -118,17 +118,8 @@ SPI_IMPLEMENT_ATTACH
Common::OpenConsole();

auto _ = SDKInitializer::Instance();
writeln(L"Attach - names at 0x%p, objects at 0x%p",
SDKInitializer::Instance()->GetBioNamePools(),
SDKInitializer::Instance()->GetObjects());

if (auto rc = InterfacePtr->FindPattern((void**)&ProcessEvent, "40 55 41 56 41 57 48 81 EC 90 00 00 00 48 8D 6C 24 20");
rc != SPIReturn::Success)
{
writeln(L"Attach - failed to find ProcessEvent pattern: %d / %s", rc, SPIReturnToString(rc));
return false;
}

INIT_FIND_PATTERN_POSTHOOK(ProcessEvent, /* 40 55 41 56 41 */ "57 48 81 EC 90 00 00 00 48 8D 6C 24 20");

if (auto rc = InterfacePtr->InstallHook(MYHOOK "ProcessEvent", ProcessEvent, ProcessEvent_hook, (void**)&ProcessEvent_orig);
rc != SPIReturn::Success)
Expand Down

0 comments on commit d2d5693

Please sign in to comment.