File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -54,13 +54,13 @@ class Memory {
5454 template <unsigned int IIdx, typename TRet, typename ... TArgs>
5555 static inline auto CallVFunc (void *thisptr, TArgs... argList) -> TRet {
5656 using Fn = TRet (__thiscall *)(void *, decltype (argList)...);
57- return (*static_cast <Fn **>(thisptr))[IIdx](thisptr, argList...);
57+ return (*static_cast <Fn **>(thisptr))[IIdx](thisptr, std::forward<TArgs>( argList) ...);
5858 }
5959
6060 template <typename TRet, typename ... TArgs>
6161 static auto CallVFuncI (uint32_t index, void * thisptr, TArgs... argList) -> TRet {
62- using Fn = TRet (__thiscall*)(void *, decltype (argList) ...);
63- return (*static_cast <Fn**>(thisptr))[index](thisptr, argList...);
62+ using Fn = TRet (__thiscall*)(void *, TArgs ...);
63+ return (*static_cast <Fn**>(thisptr))[index](thisptr, std::forward<TArgs>( argList) ...);
6464 }
6565
6666 static void hookFunc (void *pTarget, void *pDetour, void **ppOriginal, std::string name) {
You can’t perform that action at this time.
0 commit comments