9 Commits

Author SHA1 Message Date
Kawe Mazidjatari
b76f4aa3bd CModule class improvements
*Use unordered_map to get mpdule sections instead, as this is more performant than comparing strings.
* Removed 'm_SectionName' field from ModuleSections_t, as the unordered map now keeps track of them.
* Removed all extraneous module section copies.
* Renamed 'GetImportedFunction' to 'GetImportedSymbol'.
* Renamed 'GetExportedFunction' to 'GetExportedSymbol'.
*Made a static version of 'GetImportedSymbol' and 'GetExportedSymbol', so it could be used on raw module base addresses.
*Created inlines for getting the DOS and NT headers.
*Improved formatting so the code could be read more easily on a vertical monitor.
2023-06-25 10:29:42 +02:00
Kawe Mazidjatari
cae5037324 Initial fix for older game builds
SDK compiles and works for the S1 game now, still needs to be debugged further.
2023-03-01 00:09:38 +01:00
Kawe Mazidjatari
a618990937 Detour code refactor
This change was planned for a long time. This moves all REGISTER calls to a single translation unit, this is required as we currently added a very dirty workaround for not registering duplicates by checking if VFTable pointer was already present in the vector... Registering from single translation unit prevents duplicate instances that gets created if header is included by more cpp files.
Reworking this reduced 100kb+ of compiled code. This commit also reworked the way functions/variables/constant gets logged with their addresses; the new code formats them on the fly, and allows for resize at any time. Formatting is no longer required by programmer.

TODO: currently there are some compile errors for dedicated and client dll's. These will be resolved very soon as they need to be properly worked out still (server & client only stuff needs to be properly split). Use the 'main' (stable) branch for the time being if you need to compile these dll's.
2023-01-25 02:26:52 +01:00
Kawe Mazidjatari
2501c37044 Globally convert all byte patterns to strings
These get reconverted to masked byte patterns at runtime. With the signature map cache system, this will only happen when building the cache.
2022-12-01 22:44:55 +01:00
rexx
b1b1e85b69 add MilesBankPatch hook for future debug print 2022-11-27 20:44:37 +00:00
rexx
6695a9bdaf add MilesQueueEventRun debug print 2022-11-27 20:44:17 +00:00
rexx
b15b876eed Revert "add more miles debug hooks"
This reverts commit feeaf5c54536a6ff7dae385314f9036ff45c4cd2.
2022-11-27 20:26:58 +00:00
rexx
feeaf5c545 add more miles debug hooks 2022-11-27 20:14:41 +00:00
Kawe Mazidjatari
03dc4eada5 Move Miles and Bink hooks/implementations to shared 'codecs' folder 2022-11-27 17:27:35 +01:00