War Rock Cheat Programming Discussion

11/07/2013 17:40 Alliance™#241
Because my addylog dont' work?

Pattern.h
Code:
bool Match(const BYTE* pData, const BYTE* bMask, const char* szMask)
{
    for(;*szMask;++szMask,++pData,++bMask)
        if(*szMask=='x' && *pData!=*bMask ) 
            return false;
    return (*szMask) == NULL;
}


DWORD FindPattern(DWORD dwAddress,DWORD dwLen,BYTE *bMask,char * szMask, bool doExtract, int offset)
{
    for(DWORD i=0; i < dwLen; i++)
        if( Match( (BYTE*)( dwAddress+i ),bMask,szMask) )
			if(doExtract)
				return *(DWORD*)(dwAddress+i+offset);
			else
				return (DWORD)(dwAddress+i+offset);

    return 0;
}
Main.cpp
Code:
void Write(){

   ofstream file;
   file.open("C:\\Users\\...\\Desktop\\Alliance_Addys.txt");
   file<<"#define ADR_PLAYERPOINTER "<<FindPattern(0x00400000,0x00986000,(BYTE*)"\xA1\xF0\x17\xAF\x00\x85\xC0\x74\x17\x83\xA0\xC8\x02\x01\x00\x00","xx??xxxxxxxxxxxx",true,2);
   file.close();
   Sleep(100);
   ExitProcess(0);
}
this is output:
Code:
#define ADR_PLAYERPOINTER 0
11/08/2013 15:35 Gameerish___#242
I Need PLAYER_SIZE Addy !!!
11/08/2013 15:50 Kazbah__#243
Code:
 DWORD ADR_OFFSET_GLOBALPLAYERSIZE  = 0xB10; // 06/11/2013 
 DWORD ADR_OFFSET_LOCALPLAYERSIZE   = 0xA1DC; // 06/11/2013
11/08/2013 16:01 Cyanstack#244
Quote:
Originally Posted by Alliance™ View Post
Because my addylog dont' work?

Pattern.h
Code:
bool Match(const BYTE* pData, const BYTE* bMask, const char* szMask)
{
    for(;*szMask;++szMask,++pData,++bMask)
        if(*szMask=='x' && *pData!=*bMask ) 
            return false;
    return (*szMask) == NULL;
}


DWORD FindPattern(DWORD dwAddress,DWORD dwLen,BYTE *bMask,char * szMask, bool doExtract, int offset)
{
    for(DWORD i=0; i < dwLen; i++)
        if( Match( (BYTE*)( dwAddress+i ),bMask,szMask) )
			if(doExtract)
				return *(DWORD*)(dwAddress+i+offset);
			else
				return (DWORD)(dwAddress+i+offset);

    return 0;
}
Main.cpp
Code:
void Write(){

   ofstream file;
   file.open("C:\\Users\\...\\Desktop\\Alliance_Addys.txt");
   file<<"#define ADR_PLAYERPOINTER "<<FindPattern(0x00400000,0x00986000,(BYTE*)"\xA1\xF0\x17\xAF\x00\x85\xC0\x74\x17\x83\xA0\xC8\x02\x01\x00\x00","xx??xxxxxxxxxxxx",true,2);
   file.close();
   Sleep(100);
   ExitProcess(0);
}
this is output:
Code:
#define ADR_PLAYERPOINTER 0
The pattern don't work for some reason
1) There are dynamic bytes
2)
Quote:
,true,2);
this should be
Quote:
,true,1);
try this one
\xA1\x00\x00\x00\x00\x84\xC0\x74\x17(pattern) , x????xxxx (mask)
11/08/2013 17:14 Alliance™#245
I try but don't work...the output is:
Code:
#define ADR_PLAYERPOINTER 0
11/08/2013 17:14 Gameerish___#246
AutoMedic/Ammo Source.
Code:
if(AutoAmmo)
{
WriteMEM<float>((void*)MEM_AUTOAMMO,9999.0f);
}
Code:
if(AutoMedic)
{
WriteMEM<float>((void*)MEM_AUTOMEDIC,9999.0f);
}
11/08/2013 17:33 Kazbah__#247
this auto ammo/medic suck use the one from upk with packets :)
11/08/2013 19:04 n4n033#248
Quote:
Originally Posted by Alliance™ View Post
I try but don't work...the output is:
Code:
#define ADR_PLAYERPOINTER 0
Here you go for correct pattern :

DWORD PlayerPTR = FindPattern((PBYTE)"\xA1\x00\x00\x00\x00\x85\xC0\x 74\x17\x83\xA0\xC8\x02\x01\x00\x00", "x???xxxxxxxxxxxx", 1, true);
11/08/2013 19:47 Cyanstack#249
Quote:
Originally Posted by Alliance™ View Post
I try but don't work...the output is:
Code:
#define ADR_PLAYERPOINTER 0
yea , my mistake , here there is the correct one

Code:
\xA1\x00\x00\x00\x00\x85\xC0\x74\x17(pattern) , x????xxxx (mask)
Quote:
Here you go for correct pattern :

DWORD PlayerPTR = FindPattern((PBYTE)"\xA1\x00\x00\x00\x00\x85\xC0\x 74\x17\x83\xA0\xC8\x02\x01\x00\x00", "x???xxxxxxxxxxxx", 1, true);

the pattern can be more short because if you go on ollydbg->wrdump->search for binary string and insert the pattern like : A1 ?? ?? ?? ?? 85 C0 74 15 ,you can see that the first result is the playerpointer
11/08/2013 20:54 Combatdafuq#250
Quote:
Originally Posted by Kazbah__ View Post
Code:
 DWORD ADR_OFFSET_GLOBALPLAYERSIZE  = 0xB10; // 06/11/2013 
 DWORD ADR_OFFSET_LOCALPLAYERSIZE   = 0xA1DC; // 06/11/2013
good job about localplayersize question how you exactly using it ?

Quote:
Originally Posted by Kazbah__ View Post
this auto ammo/medic suck use the one from upk with packets :)
they changed automedic code on upk style
11/08/2013 21:34 Alliance™#251
Quote:
Originally Posted by Cyanstack View Post
yea , my mistake , here there is the correct one

Code:
\xA1\x00\x00\x00\x00\x85\xC0\x74\x17(pattern) , x????xxxx (mask)



the pattern can be more short because if you go on ollydbg->wrdump->search for binary string and insert the pattern like : A1 ?? ?? ?? ?? 85 C0 74 15 ,you can see that the first result is the playerpointer
I resolved this is the correct pattern:
Code:
FindPattern((PBYTE)"\xA1\xF0\x00\x00\x00\x85\xC0\x74","xx??xxxx",true,1);
compare old byte with new byte of address:
Code:
0040A5EF  A1 F0 17 AF 00 85 C0 74    New byte
0040A0DC  A1 F0 E2 AE 00 85 C0 74  Old byte
 
mask: xx??xxxx
pattern: \xA1\xF0\x00\x00\x00\x85\xC0\x74
11/08/2013 21:39 Kazbah__#252
Quote:
they changed automedic code on upk style
no they didnt, update your cserver maybe or dont be stupid
11/08/2013 22:01 Gameerish___#253
Kann jemand die Aktuellen Addys & Structs Posten ?
11/08/2013 23:57 Kazbah__#254
Quote:
Kann jemand die Aktuellen Addys & Structs Posten ?
schreib welche du brauchst
11/09/2013 04:00 Combatdafuq#255
Quote:
Originally Posted by Kazbah__ View Post
no they didnt, update your cserver maybe or dont be stupid
i has it working in other way.
but has i noticed on code i saw some changment.