Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Last Chaos
You last visited: Today at 15:29

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[C++]Attackspeed Hack without offsets

Discussion on [C++]Attackspeed Hack without offsets within the Last Chaos forum part of the MMORPGs category.

Reply
 
Old   #1

 
elite*gold: 0
Join Date: Apr 2007
Posts: 2,394
Received Thanks: 6,644
[C++]Attackspeed Hack without offsets

hook.h is the Header of my own Hooking class but you
can just use Microsoft Detours instead ( its very very similar
to my Code ). For a MS Detours Tutorial take a look here:



With this way you can also change Runspeed, Range,
Skillspeed and much more. This is just a small example,
allthough i did not try this Code it should work perfectly
fine. With this way you dont need any Offsets / Baseaddresses
only the function strings for GetProcAddress, you can find
those with OllyDBG 2.0 and IDA.

If you have any Questions, feel free to ask.

Code:
#include <windows.h>
#include "hook.h"
Hook * Attackspeedhook = NULL;

DWORD WINAPI hookthread( LPVOID Param );
char __fastcall myGetAttackSpeed( void* this, DWORD unusededx );


typedef char (__thiscall* CPlayer_GetAttackSpeed )( void* ecx );

CPlayer_GetAttackSpeed oGetAttackSpeed = NULL;

BOOL WINAPI DllMain( HMODULE hModule, DWORD reason, LPVOID lpReserved )
{    
    UNREFERENCED_PARAMETER(lpReserved);
    if (reason == DLL_PROCESS_ATTACH)
    {
        DisableThreadLibraryCalls(hModule);
        CreateThread(NULL, NULL, hookthread, NULL, NULL, NULL);
        return 1;
    }      
    else if (reason == DLL_PROCESS_DETACH)    
    {        
        Attackspeedhook->RemoveHook();        
        return 0;    
    }      
    return 0;
}  

char __fastcall myGetAttackSpeed( void * ecx, DWORD unusededx )
{    
    return 5; // Attackspeed Value
}  

DWORD WINAPI hookthread( LPVOID Param )
{    
    HMODULE hmod = 0;
    while(!hmod)
    {
        hmod = GetModuleHandle("entitiesmp");
        Sleep(50);
    }
    unsigned long GetAttackspeedadr = reinterpret_cast<unsigned long>( GetProcAddress( hmod, "?GetAttackspeed@CPlayer@@UAECXZ" ));
    if( GetAttackspeedadr )
    {
        Attackspeedhook= new Hook( GetAttackspeedadr , 5, (DWORD)myGetAttackSpeed);
        oGetAttackSpeed = (CPlayer_GetAttackSpeed)Attackspeedhook->HookFunc();
    }
    return 0;
}
wurstbrot123 is offline  
Thanks
1 User
Old 07/07/2012, 09:28   #2
 
elite*gold: 0
Join Date: Feb 2011
Posts: 242
Received Thanks: 60
Quote:
Originally Posted by wurstbrot123 View Post
hook.h is the Header of my own Hooking class but you
can just use Microsoft Detours instead ( its very very similar
to my Code ). For a MS Detours Tutorial take a look here:



With this way you can also change Runspeed, Range,
Skillspeed and much more. This is just a small example,
allthough i did not try this Code it should work perfectly
fine. With this way you dont need any Offsets / Baseaddresses
only the function strings for GetProcAddress, you can find
those with OllyDBG 2.0 and IDA.

If you have any Questions, feel free to ask.

Code:
#include <windows.h>
#include "hook.h"
Hook * Attackspeedhook = NULL;

DWORD WINAPI hookthread( LPVOID Param );
char __fastcall myGetAttackSpeed( void* this, DWORD unusededx );


typedef char (__thiscall* CPlayer_GetAttackSpeed )( void* ecx );

CPlayer_GetAttackSpeed oGetAttackSpeed = NULL;

BOOL WINAPI DllMain( HMODULE hModule, DWORD reason, LPVOID lpReserved )
{    
    UNREFERENCED_PARAMETER(lpReserved);
    if (reason == DLL_PROCESS_ATTACH)
    {
        DisableThreadLibraryCalls(hModule);
        CreateThread(NULL, NULL, hookthread, NULL, NULL, NULL);
        return 1;
    }      
    else if (reason == DLL_PROCESS_DETACH)    
    {        
        Attackspeedhook->RemoveHook();        
        return 0;    
    }      
    return 0;
}  

char __fastcall myGetAttackSpeed( void * ecx, DWORD unusededx )
{    
    return 5; // Attackspeed Value
}  

DWORD WINAPI hookthread( LPVOID Param )
{    
    HMODULE hmod = 0;
    while(!hmod)
    {
        hmod = GetModuleHandle("entitiesmp");
        Sleep(50);
    }
    unsigned long GetAttackspeedadr = reinterpret_cast<unsigned long>( GetProcAddress( hmod, "?GetAttackspeed@CPlayer@@UAECXZ" ));
    if( GetAttackspeedadr )
    {
        Attackspeedhook= new Hook( GetAttackspeedadr , 5, (DWORD)myGetAttackSpeed);
        oGetAttackSpeed = (CPlayer_GetAttackSpeed)Attackspeedhook->HookFunc();
    }
    return 0;
}
Wenn ich das jetz richtig verstanden hab muss ich des jetz zu ner .DLL compilen, oder?^^ *noob*
lcprox3 is offline  
Old 07/07/2012, 17:15   #3
 
elite*gold: 0
Join Date: Nov 2009
Posts: 167
Received Thanks: 42
Wursti rette uns Ger noobs doch mal bitte endlich, wir peilen doch nix mensch
boblar is offline  
Old 07/07/2012, 17:36   #4
 
dsfgd's Avatar
 
elite*gold: 2
Join Date: Aug 2007
Posts: 599
Received Thanks: 2,927
Quote:
Originally Posted by boblar View Post
Wursti rette uns Ger noobs doch mal bitte endlich, wir peilen doch nix mensch
Es ist genau für euch nicht gedacht, man brauch kentnisse in
- C oder C++
- Hooks/Microsoft Detours
- dll injection

Es ist mehr ein sample code, wie man mithilfe von dll injection und hooking die standard funktion "GetAttackspeed" in eine funktion ändert, die einen beliebigen wert liefert um so ohne offsets/pointer den attackspeed beliebig manipulieren zu können.

Nebenbei, bei dieser simplen funktion (sie ist 7 Byte groß und hat 9 byte alignment ^^) reicht es auch sie mithilfe von writeprocessmemory oder memcpy zu überschreiben.
dsfgd is offline  
Thanks
1 User
Old 07/07/2012, 17:39   #5

 
elite*gold: 0
Join Date: Apr 2007
Posts: 2,394
Received Thanks: 6,644
Quote:
Originally Posted by dsfgd View Post
Nebenbei, bei dieser simplen funktion (sie ist 7 Byte groß und hat 9 byte alignment ^^) reicht es auch sie mithilfe von writeprocessmemory oder memcpy zu überschreiben.
Natürlich reicht das, aber wenn man jetzt zum Beispiel
so Radarfunktionen hat zum deaktivieren oder wenn der
User verschiedene Settings testen möchte, müsste
man nicht immer memcpy nutzen
Naja muss man ja beim patchen auch nicht wenn mans direkt
so patcht das es auf eine Variable zugreift
wurstbrot123 is offline  
Thanks
1 User
Reply


Similar Threads Similar Threads
Rohan Vendetta Attackspeed Hack
08/23/2011 - Rohan - 8 Replies
Huhu ich erkläre euch heute wie man in Rohan Vendetta German hackt bwz den Spielverlauf verschnellert. Ihr braucht dafür Cheat Engine (: Cheat Engine - Download - CHIP Online 1. Ihr startet Rohan Vendetta 2. Ihr öffnet Cheat Engine 3. Ihr sucht den Prozess 00000178C-rohanclient.exe 4. Unten rechts steht "Enable Speedhack" da ein Hacken rein 5. Stellt eure Geschwindigkeit ein höchstens 1.7 (: Ich hoffe ich kontte euch helfen (: Mfg WunderKiinD<3
Attackspeed Hack!
07/14/2011 - Metin2 - 3 Replies
Hai ich wollte mal nachfragen ob es nochsowas wie ein Multihack gibt wo man sein Attackspeed besser machen kann... schneller amchen kann. Den von Banjo fand ich HAMMER. Weis es wer ? Link posten pls
How to Hack last chaos AttackSpeed
12/10/2009 - Last Chaos - 15 Replies
Voraussetzung: Erfahrung mit Cheat engiene ein gehirn 2 arme 10 finger 2 augen ^^ ----------------------HACKERSOLDIER'S Tutoriel--------------------------- 1. öffnen von cheat engiene5.5 2. Pogramm auswählen
Metin2 Speed + Attackspeed hack
01/19/2009 - Metin2 - 4 Replies
Ich suche schon ewig verzweifelt einen virenfreien Speedhack für Metin2 weil ich Felsenaffen schneller killn will wegen Geld. Ich weiß, dass es dafür keinen Yanghack gibt. -.- Bitte einen VIRENFREIEN DOWNLOADLINK für Speedhack und Attackenspeed reinstellen. Cheat Engine hab ich schon versucht da freezt mein Caracter andauernd weg -.- Den von Leisures hatte ich mal aber der ist auch voller Viren.....also hilft mir bitte! Nochmals: VIRENFREIER SPEEDHACK-DOWNLOADLINK FÜR METIN2GERMANY GESUCHT!!!
Attackspeed Hack für Set benutzer :)
10/19/2007 - Flyff - 15 Replies
So ich biete euch mal 100% Attackspeed für Set benutzer an :) Schreibt mir einfach welches lvl das Set hat und für welche Klasse es ist.... Ich uppe später auch mal ne Data.res wo alle 100% Attackspeed haben. Achja ich verlange das diese person über 30 Posts hat... MFG.Vulcanraven



All times are GMT +1. The time now is 15:29.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.