Update to support x64 bit games #20
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There is some massive changes on how the way the core part of the plugin works, so the version gets a 2.0.0 bump.
First step for x64 bit support is to make use of virtual address from latest Sourcemod update, using
LoadAddressFromAddressandStoreAddressToAddress.Using virtual address however makes it that the hack on getting address from VTable no longer works, with no simple workaround solution for it. All of the detour usages on
IScriptVMfrom offset therefore have to be replaced with a virtual hook. A few signatures had to be added to gamedata to get it working, hopefully aside from L4D2 all of the other games should have the same windows signatures.No address from VTable also makes it that native
VScriptFunction.Function.getnow returns null if its an offset function, users will need to create a virtual hook instead.This PR cannot be merged yet as sourcescramble extension will need to be updated to support virtual address, and having natives to be able to load/store address from
MemoryBlock. DHooks also still has yet to support 64bit and having address support forReturnTypeandHookParamType.