Sorry, aber das ist nichts was speziell mit Hacks sondern mit Programmieren im Allgemein zu tuen hat. Zu jener Thematik gibt es Dutzende von Büchern und die verschiedene Techniken, Patterns und Paradigma lassen sich nicht anhand eines einziges Programmes verstehen. Außerdem sind Hacks / Bots normalerweise nicht gerade die besten Beispiele für OOP oder einen guten Stil. Wenn du nur in c++ interessiert wirst du es sowieso schwieriger haben, da die Sprache doch ihre ganz eigenen Kniffe hat (constness,templates, RAII, value semantics um nur ein paar zu nennen). Guter c++ code ist rar! Wenn du trotzdem nicht von c++ abhälts rate ich dir die Poco libs anzusehen; mit Abstand einer der saubersten und objektorientiertesten c++ libs, die es so gibt.
Hast du oder evtl. jemand ander lust es ein bischen open source zu machen, damit man davon lernen kann, wie der code aufgebaut ist ect?
Kannst ja auch dir wichtige hacks ect. rauslassen wenn du sie nicht vö willst.
Also wenn du allgemein c++ näher kennenlernen möchtest, solltest du vlt nicht gleich hackspezifisch durchstarten. es gibt unzählige beginner tuts für c++ um einfach einsteigen zu können. Wenn du wirklich objektorientiert proggen möchtest, solltest du c++ eher meiden. mein tipp für oop ist java. eignet sich aber nicht für hacks.
solltest du dir einfach nur nen teleporter bauen wollen zum testen, schau dir mal den c# code zum auslesen der char koordinaten an, den djmatrix1987 gepostet hat. den code kann man simple ändern um die werte nicht zu lesen sondern zu schreiben.
Wird ein richtiger Bot mit Wegpunkten, diese mann dan auf der Karte zeichnen kann. Im Moment sind die Wegpunkte ingame auch auf der Karte vorhanden und die Rüssi / Händler.
Packet encryption for sending packets (imagebase already added)
Code:
off_NetworkClass = $015C1DD4; // [15754]
off_EncryptCallAdd = $1CC; // [15754]
off_EncryptPacket = $00A62190; // [15754]
procedure EncryptPacket(pBuffer, pTargetBuffer: Pointer; bufferSize: Integer);
const
// delphi __thiscall hekk, ignore _eax and _edx and reverse the order
gw2Encrypt: procedure( _eax, _edx, pThis, pTargetBuffer, pBuffer: Pointer; bufferSize: Integer) = Pointer(off_EncryptPacket);
begin
gw2Encrypt(nil, nil, Pointer(PCardinal(off_NetworkClass)^ + off_EncryptCallAdd), pTargetBuffer, pBuffer, bufferSize);
end;
After the encryption you have to send your packet immediately or the server will receive wrong encrypted packets by the client. Just put the targetbuffer into the winsock send function, so easy.
Hi, first thanks for these offsets, this is very interresting, i tried to implement this to a c++ dll. Hooks on EncryptPacket and send are applying fine but when EncryptPacket is called, the game instantly crashes :/
Here is the code i do in my hooked EncryptPacket & send :
I'm sure there are better ways to send packets. GW2 puts all packets into a list and sends it, there is a high chance that your encryption will fail if you do it in your own thread.
Looks wrong, EncryptCallAdd should be the first parameter (as you use msfastcall). Also you don't need to add the base to the offset, I already did it.
If your code is a detour you should also add edx and ecx as the first parameters
VOID __fastcall m_PacketEncrypt(VOID* ecx, VOID * Unused, int bufferSize, VOID* pBuffer, VOID* pTargetBuffer)
Hope this helps.
Anyway here's my detour in delphi, it's crap but hey it works.
Code:
procedure hk_PacketCrypt(_eax, _edx, pThis, pEncryptedBuffer, pBuffer: Pointer; packetSize: Integer);
var
buffer: Array of Byte;
i: Integer;
sLog, sOpName: string;
wOpCode: Word;
const
org_PacketCrypt: procedure(_eax, _edx, pThis, pEncryptedBuffer, pBuffer: Pointer; packetSize: Integer) = Pointer($00A62190);
begin
if (g_bLogOutgoingPackets) then
begin
SetLength(buffer, packetSize);
Move(pBuffer^, buffer[0], packetSize);
for i := Low(buffer) to High(buffer) do
begin
sLog := sLog + IntToHex(buffer[i], 2) + ' ';
end;
Move(buffer[0], wOpCode, SizeOf(wOpCode));
case wOpCode of
$0D:
sOpName := 'MovementHeartbeat';
$0F:
sOpName := 'CastSpell';
$21:
sOpName := 'MoveItem';
$54:
sOpName := 'ChatMessage';
$56:
sOpName := 'SlashCommand';
$7C:
sOpName := 'Unlock bag slot'
else
sOpName := 'Unknown';
end;
LogConsole ('======================================================');
LogConsoleF('C->S Packet code: %x (%s) Size: %d', [wOpCode, sOpName, Length(buffer)]);
LogConsole ('======================================================');
LogConsole (sLog);
LogConsole ('======================================================');
end;
org_PacketCrypt(_eax, _edx, pThis, pEncryptedBuffer, pBuffer, packetSize);
end;
I'm overwriting the call at 0x00A5D011, else you'll also see the incoming packets.
Thanks for the answer, i'm doing like this now but it crash at calling oPacketEncrypt (I cleaned my src a little ^^') (oPacketEncrypt is new name for pPacketEncrypt)
I use MSDetours 1.5 and the call of m_PacketEncrypt works fine now !
In PacketEncrypt(_EAX, (VOID*)EncryptCallAdd, NULL, pTargetBuffer, pBuffer, bufferSize);
I set 3rd parameters as NULL because I didn't know which argument passing to it.
Also after checking
DWORD EncryptCallAdd = *(DWORD*)(NetClassptr + EncryptCall) are set with some random numbers, i'm sure the cast is good and i removed the base adding indeed ><
I'm very new with hooks, i just done on D3DWrapper project, and i search for a deep documentation on, because i had failed to find one good with ggl!
Thanks for the answer, i'm doing like this now but it crash at calling oPacketEncrypt (I cleaned my src a little ^^') (oPacketEncrypt is new name for pPacketEncrypt)
I use MSDetours 1.5 and the call of m_PacketEncrypt works fine now !
In PacketEncrypt(_EAX, (VOID*)EncryptCallAdd, NULL, pTargetBuffer, pBuffer, bufferSize);
I set 3rd parameters as NULL because I didn't know which argument passing to it.
Also after checking
DWORD EncryptCallAdd = *(DWORD*)(NetClassptr + EncryptCall) are set with some random numbers, i'm sure the cast is good and i removed the base adding indeed ><
I'm very new with hooks, i just done on D3DWrapper project, and i search for a deep documentation on, because i had failed to find one good with ggl!
edit: Just letting you know that the offsets are not working anymore with the latest patch
Thanks detouring PacketEncrypt is now working fine, just crashing at original call but i'll work on it (whend using encryptcalladd).
The problem i have is i got a high number of packet throught the hook o_o
I use currently use pThis in oPacketEncrypt because EncryptCallAdd make the program crashing, i'm think it's because of the use of pThis and not of EncryptCallAdd that i got a lot of packet.
Ok, this is fixed, i just check pThis is equal to EncryptCall to just log outgoing packet ^^"
But packets are differents than your, eg for Heartbeat i got:
Grand Chase Memory Hacking Brigade Application Thread 07/20/2011 - Grand Chase - 34 Replies Grand Chase Memory Hackers Brigade
http://www.elitepvpers.com/forum/customgroupicons/ socialgroupicon_1406_1294233999.gif
Since i can't do memory hacking alone i need to gather members that can help me.. make and revive memory hacking... i got just the idea on how to make mle working again.. too bad i need someone who can help me with it..Now to begin with.. You need 1st to introduce yourself.. here follow this format:
Why do you want to join in the club?
Programming Language you...
grand chase memory hackers brigade application thread 01/10/2011 - Grand Chase Philippines - 26 Replies Grand Chase Memory Hackers Brigade
http://www.elitepvpers.com/forum/customgroupicons/ socialgroupicon_1406_1294233999.gif
Since i can't do memory hacking alone i need to gather members that can help me.. make and revive memory hacking... i got just the idea on how to make mle working again.. too bad i need someone who can help me with it..Now to begin with.. You need 1st to introduce yourself.. here follow this format:
Why do you want to join in the club?
Programming Language you...
Quick Memory Editor - Alternative Memory Hacking Software 11/21/2009 - Cabal Hacks, Bots, Cheats, Exploits & Macros - 11 Replies This might be detected or not by GameGuard, I have not tested this on Official servers however it worked perfectly fine on other private servers.
http://imagenic.net/images/x0jxwzwpg2zxmkdtcf36.p ng
This is just an alternative memory editing tool.
Press thanks if this helps.
Remember, scan before using this.
Cause its 5.5MB.
Fragen Zur Memory!!!(Auslesen von Spawn/Memory) 12/31/2008 - Guild Wars - 3 Replies hey leute,
ich wollte mal einen bot schreiben und nun bin ich ganz verwirrt.
könnte mir jmd bitte schritt für schritt erklären wie das mit Memory auslesen, benutzen und der Spawnpointer funktioniert.
Ich wär sehr dankbar wenn jmd kontakt mit mir aufnehmen würde...
und sobald der bot fertig ist bekommt der ihn natürlicherweise umsonst:D
ICQ: 481799773
oder hier im forum