How do you do it with send message? I've never used it
How do you do it with send message? I've never used it
This was my first time actually figuring out how to use it xDOriginally Posted by Bryfry221
So here it goes:
The reason why I use PostMessage for the Enter keypress is that SendMessage needs focus to send an enter keypress, while PostMessage doesn't (at least it wouldn't for me)Code:Public Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long 'YOU HAVE TO USE FINDWINDOW TO FIND THE WINDOW AND SET IT TO THE VARIABLE Window, if you want this code to work without a change: SendMessage Window, &H100, vbKeyA, 0 '&H100 = wm_keydown SendMessage Window, &H101, vbKeyA, 0 '&H101 = wm_keyup, vbKeyA = the A key on yar/yer keyboard To send the enter keypress, I use this: Public Declare Function PostMessage Lib "user32.dll" Alias "PostMessageA" (ByVal hwnd As Long, _ ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long PostMessage Window, &H100, vbKeyReturn, 0 '&H100 is still wm_keydown PostMessage Window, &H101, vbKeyReturn, 0 '&H101 is still wm_keyup 'vbKeyReturn is teh Enter button.
Ps. I've always thought you used it to send whole strings of characters, which is why I couldn't get it to work earlier, but now I've made a loop that sends one character at a time.
Also sendmessage hangs ur thread and waits for responce from the target program, while postmessage dosent
Thanks, I was trying to send it as a string and it wasn't working. A for loop through a char array works just fine though
At last I found the pointers, god bless tprogramming!
Well now to my problem... The thing is I can't get the memory reading right. I know how to do with non pointer addresses but with these pointers I don't know how to do to get it working. :icon8:
Can someone with experience of this show a litle code for exemple showing the current hp in a MsgBox and help me understand, please!
Jiggan! Tired of my pixelbot. :icon10:
In your program just start with the base address and then use the ofsets to eventually get to the value
like use ReadProcessMemory on the base value and then add the ofset to it. And then do it again until you reach the value of hp or mana or whatever.
(it's what I do I don't know if there is a better way.)
@erra
Instead of typing out the spell I send the key for my hotkey for healing (or mana or whatever spell I want automated) and press enter.
It seems to be faster and doesn't screw up if there is any text in the messagebox already. It works for me since I'm keeping mine private, I haven't tried allowing a person to set which hotkey to press yet.
Jiggan: Pointer is a variable that is pointing to some other place in memory. So in practice first you read the pointer's value, and then you read the place in memory where that value points.
pseudo code:
Code:int memAdr = Memory.Read(pointerAddress); int value = Memory.Read(memAdr);
That's the thing, if you use hotkeys you have to set them beforehand if you don't edit them through memory too. Surely it would be done quite easily, but this is more user-friendly!Originally Posted by Bryfry221
Btw, your way (getting pointer) seems really weird, looks as if you first try a random value and then add random offsets, I'm not sure I get your point xD
Why hasnt anyone done a packet.dll for this game yet? It should be so easy to update it to make it work with this game, just finding the socket pointer and send address, then disabling checksum and xtea, right?
I have found the Send_Pointer(47AA84), but still trying to find Socket_Pointer
I use cheat engine to find the base pointer that never changes. In order to use the base pointer you have to know the offsets to add in to get to the real address. (Kind of hard for me to explain)Originally Posted by Erra
Here's my code for finding what value your mana is at:
I'm sure there are better ways, this is the first time I've attempted to ever make any kind of a trainer or bot or whatever.Code:int basevalue = 0x4df280; ReadProcessMemory(hProcess, (void*) (basevalue), &tempvalue, sizeof(&tempvalue), NULL); basevalue = tempvalue + 0x10; ReadProcessMemory(hProcess, (void*) (basevalue), &tempvalue, sizeof(&tempvalue), NULL); basevalue = tempvalue + 0x8c; ReadProcessMemory(hProcess, (void*) (basevalue), &tempvalue, sizeof(&tempvalue), NULL); basevalue = tempvalue + 0x30; ReadProcessMemory(hProcess, (void*) (basevalue), &tempvalue, sizeof(&tempvalue), NULL);
This code will work for finding mana until he updates zezenia
@dark pallys
I would make a packet.dll if I knew how. And there aren't very many experienced programmers that are making anything for zezenia at the moment, so most likely everybody else is just like me and doesn't know how.