Skip to content

Commit 5aede5f

Browse files
committed
Allow scrolling textures for player objects
1 parent c321082 commit 5aede5f

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

src/modules/Patches.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,9 @@ Patches::Patches()
140140
// NOP the original death wipe code in DeathState::Entry
141141
Hooking::Nop((void*)GET_ADDRESS(0x55E188, 0x5584DC, 0x75AEDE), 5);
142142

143+
// Allow animated and scrolling textures on player objects
144+
PatchAnimateScroll();
145+
143146
#ifdef TR7
144147
// NOP the exception handler in Legend
145148
Hooking::Nop((void*)0x401F53, 26);
@@ -201,6 +204,13 @@ void Patches::PatchHeapSize() const noexcept
201204
Hooking::Patch(match.get_first(19), size);
202205
}
203206

207+
void Patches::PatchAnimateScroll() const noexcept
208+
{
209+
auto match = hook::pattern("8A 86 A4 00 00 00 84 C0 78 14").count(1);
210+
211+
Hooking::Nop(match.get_first(), 10);
212+
}
213+
204214
#ifdef TR7
205215
void Patches::PatchShadowMap() const noexcept
206216
{

src/modules/Patches.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ class Patches : public Module
5858
void PatchHeapSize() const noexcept;
5959
void PatchShadowMap() const noexcept;
6060
void PatchDrawableHelper() const noexcept;
61+
void PatchAnimateScroll() const noexcept;
6162

6263
public:
6364
Patches();

0 commit comments

Comments
 (0)