[Source] PushToConsole Function Usage

02/15/2021 13:52 XByteX#1
Here is a quick small tutorial of how to use PushToConsole Function

What's PushToConsole Function?
it's an in game function that used to do some visuals effect in the game by calling the function with some of string orders.

How to use?
First create a type definition for the function.
Code:
typedef LTRESULT (__cdecl* tPushToConsole)(const char* Command);
then specify the address that function located
Code:
DWORD dwPushToConsole = BINBase + 0x2CC90;
then create a pointer with its function type to start using it
Code:
pPushToConsole = (tPushToConsole)dwPushToConsole;
That's all you need, now you can start call the function like that.
Code:
pPushToConsole("WireFrame 1"); 
pPushToConsole("FogEnable 0"); 
pPushToConsole("DrawFlat 1");
etc..

hope it helps