[16:15:41] Cypher: caus the CPU is a dick
[16:16:07] kynox: CPU is mad
[16:16:15] Cypher: CPU is all like
[16:16:16] Cypher: whatever, i do what i want
My memory library can handle both x86 and x64 instances of wow and i'd like to be compatible with any architecture regardless of current binary state
Huh?
When targeting native 64-bit, INT_PTR is a 64-bit data type.
When targeting native 32-bit, INT_PTR is a 32-bit data type.
There is no compatibility problem unless you're targeting native 64-bit and then interfacing with the 32-bit WoW client, which is dumb except in very specific circumstances that don't apply here.
Using INT_PTR means that in the future, if they were ever to upgrade WoW to native x64 your code would still work (assuming you updated your offsets etc).
He's doing the right thing. uint32_t should not be used to hold a pointer if you're trying to remain architecture agnostic.
This is one of those 'specific circumstances' in which targeting native 64-bit then interacting with a 32-bit target is the 'right' thing to do.
A good attitude imo.![]()