View Single Post
Peace-Maker
SourceMod Plugin Approver
Join Date: Aug 2008
Location: Germany
Old 01-11-2019 , 16:27   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #643

That's an outstanding issue with parameter addresses getting reused in the functions on Windows, so post-hooks don't have access to the initial input anymore. The same holds for the this-pointer, except that there is special handling to save it and restore it for a post-hook. It is only saved from a pre-hook though and thus requires one. To work around that for now, you can add an empty pre hook on the function and you'll have access to the this-pointer in the post hook as well. This doesn't work for parameters.
__________________
Peace-Maker is offline