GetCharMoney DLL problem
Hi.
We have a problem with reading the moneyvalue of our character.
Code:
This should send the value to gamechat, but the game crashes.
This are the correct addresses.
The game is Metin2.
What is wrong?
Thank you really much!
Best regards, René
We have a problem with reading the moneyvalue of our character.
Code:
Code:
#include <Windows.h>
char* money;
char* Functionen::GetCharMoney()
{
__asm
{
MOV ECX,DWORD PTR DS:[0x0FE54EC]
MOV EAX,DWORD PTR DS:[ECX+4]
ADD ECX,4
PUSH 0xB
CALL DWORD PTR DS:[EAX+0x10]
MOV DWORD PTR SS:[ESP+0x8],EAX
JMP DWORD PTR DS:[0x0E2A7EC]
MOV Money,EAX
}
return Money;
}
void Functionen::SendChatPacket(char* Nachricht,int ChatType)
{
__asm
{
MOV ECX, SendChatPacketPointer
PUSH ChatType
PUSH Nachricht
CALL SendChatPacketCall
}
}
BOOL APIENTRY DllMain( HMODULE hModule,DWORD ul_reason_for_call,LPVOID lpReserved)
{
switch (ul_reason_for_call)
{
case DLL_PROCESS_ATTACH:
SendChatPacket(GetCharMoney() ,0);
case DLL_THREAD_ATTACH:
case DLL_THREAD_DETACH:
case DLL_PROCESS_DETACH:
break;
}
return TRUE;
}
This should send the value to gamechat, but the game crashes.
This are the correct addresses.
The game is Metin2.
What is wrong?
Thank you really much!

Best regards, René
