summaryrefslogtreecommitdiffstats
path: root/src/modelinfo/SimpleModelInfo.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-07-08 08:46:42 +0200
committeraap <aap@papnet.eu>2019-07-08 08:46:42 +0200
commit12af85ca3d29e155f40323ad07a77f96a4aececf (patch)
tree7a6d7c8ed51ec1c527903835bbe4ee39eef2ab8b /src/modelinfo/SimpleModelInfo.cpp
parentMerge pull request #111 from gennariarmando/master (diff)
downloadre3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar.gz
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar.bz2
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar.lz
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar.xz
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.tar.zst
re3-12af85ca3d29e155f40323ad07a77f96a4aececf.zip
Diffstat (limited to '')
-rw-r--r--src/modelinfo/SimpleModelInfo.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/src/modelinfo/SimpleModelInfo.cpp b/src/modelinfo/SimpleModelInfo.cpp
index ea7a3f9e..dd5010fa 100644
--- a/src/modelinfo/SimpleModelInfo.cpp
+++ b/src/modelinfo/SimpleModelInfo.cpp
@@ -154,12 +154,20 @@ CSimpleModelInfo::SetupBigBuilding(void)
}
}
+class CSimpleModelInfo_ : public CSimpleModelInfo
+{
+public:
+ void DeleteRwObject_(void) { CSimpleModelInfo::DeleteRwObject(); }
+ RwObject *CreateInstance_1(void) { return CSimpleModelInfo::CreateInstance(); }
+ RwObject *CreateInstance_2(RwMatrix *m) { return CSimpleModelInfo::CreateInstance(m); }
+ RwObject *GetRwObject_(void) { return CSimpleModelInfo::GetRwObject(); }
+};
STARTPATCHES
- InjectHook(0x5179B0, &CSimpleModelInfo::DeleteRwObject_, PATCH_JUMP);
- InjectHook(0x517B60, &CSimpleModelInfo::CreateInstance_1, PATCH_JUMP);
- InjectHook(0x517AC0, &CSimpleModelInfo::CreateInstance_2, PATCH_JUMP);
- InjectHook(0x4A9BA0, &CSimpleModelInfo::GetRwObject_, PATCH_JUMP);
+ InjectHook(0x5179B0, &CSimpleModelInfo_::DeleteRwObject_, PATCH_JUMP);
+ InjectHook(0x517B60, &CSimpleModelInfo_::CreateInstance_1, PATCH_JUMP);
+ InjectHook(0x517AC0, &CSimpleModelInfo_::CreateInstance_2, PATCH_JUMP);
+ InjectHook(0x4A9BA0, &CSimpleModelInfo_::GetRwObject_, PATCH_JUMP);
InjectHook(0x517990, &CSimpleModelInfo::Init, PATCH_JUMP);
InjectHook(0x517C60, &CSimpleModelInfo::IncreaseAlpha, PATCH_JUMP);
InjectHook(0x517950, &CSimpleModelInfo::SetAtomic, PATCH_JUMP);