MSHook basically replacing a function with your own function.
lets say there is an offset called DefaultFOV(float value) and it's offset is 0x10123456
Using MSHOOK (jb only)
We wanna start with replacing the function with our own.
bool changefov;
old_DefaultFOV(float);
DefaultFOV(float value) {
if (changefov) {
value = 120
}
return old_DefaultFOV(float)
}
If changefov is true, then return the value to 120
else return the old value from old_DefaultFOV.
Then you need to hook the function via
MSHookFunction(0x10123456, DefaultFOV, old_DefaultFOV)
(DefaultFOV is the function youll be changing and old_DefaultFOV is the old function)
You can call MSHookFunction when you load your menu or something. Hopefully this can clear some foggy understanding.