WarRock EU - Code Snippets

12/01/2011 18:31 Raise_Your_Division#5986
@request
Zombie, Player OPK Structs
12/01/2011 19:19 CyberVeezy :)#5987
Quote:
Originally Posted by WARROCK_CODER View Post
@request
Zombie, Player OPK Structs
Code:
  if(nPlayerOPK==1)//NEED UPDATED STRUCTS ;)
  {
  for(int i = 0; i < 32; i++)
 {
 CPlayer* pPlayer = pBase->player[i];
 pBase->plocal->pos1 = 0;
 pBase->plocal->pos2 = 0;
 pBase->plocal->pos3 = 0;
 pPlayer->pos1 = 0;
 pPlayer->pos2 = 0;
 pPlayer->pos3 = 0;
 *(float*)(dwPlayerPtr+OFS_NFD) = -9999999;
 }
  }
//Credits: ToxicLibrary
12/01/2011 19:34 Raise_Your_Division#5988
@up
ye but i don't need source for opk ...
i need STRUCTS for opk
12/01/2011 21:36 Wamba123123#5989
Hey dudes, I have a problem by hooking...

When I use the following things:


Code:
int iDIRECT3D(void)
{
	DWORD		hD3D, adr, *vTable;

	// wait for the d3dx dll
	hD3D=0;
	do {
		hD3D = (DWORD)GetModuleHandleA("d3d9.dll");
		Sleep(100);
	} while(!hD3D);
	adr = FindPattern(hD3D, 0x128000, (PBYTE)"\xC7\x06\x00\x00\x00\x00\x89\x86\x00\x00\x00\x00\x89\x86", "xx????xx????xx");
	if(adr){
		memcpy(&vTable,(void *)(adr+2),4);
		BYTE* DipCheck = (BYTE*)vTable[82];
		
		 pReset                = (oReset)                 DetourE9((DWORD)vTable[16], (DWORD)myReset,12);
         pPresent              = (oPresent)               DetourE9((DWORD)vTable[17], (DWORD)myPresent,5);
	    pDrawIndexedPrimitive = (oDrawIndexedPrimitive)   DetourCreate85539323((DWORD)vTable[82], (DWORD)myDrawIndexedPrimitive,12);
	   while (1)

{
		if(memcmp((void*)vTable[82],(void*)(PBYTE)"\x8B\xFF",2)== 0)
		{
			pDrawIndexedPrimitive	= (oDrawIndexedPrimitive)	DetourCreate85539323((DWORD)vTable[82], (DWORD)myDrawIndexedPrimitive,12);
		}
		Sleep(100);
	}
	 

	return TRUE;
	} 
}
DetourCreate85539323:
Code:
DWORD DetourCreate85539323( DWORD  SrcVA, DWORD  DstVA, DWORD  Size )
{
	DWORD DetourVA, dwProtect, i;

#define SIZEOF_JMP_REL  5

	if ( SrcVA && DstVA && Size >= SIZEOF_JMP_REL )
	{
		DetourVA = (DWORD) VirtualAlloc( 
			NULL, Size + SIZEOF_JMP_REL, 
			MEM_COMMIT, PAGE_EXECUTE_READWRITE );

		if ( DetourVA && VirtualProtect( (VOID*)SrcVA, Size, PAGE_EXECUTE_READWRITE, &dwProtect ) )
		{
			for ( i=0; i < Size; i++ ) {
				*(BYTE*)( DetourVA + i ) = *(BYTE*)( SrcVA + i );
			}
			
			*(BYTE*)( DetourVA + Size + 0 ) = 0xE9;
			*(DWORD*)( DetourVA + Size + 1 ) = ( SrcVA - DetourVA - SIZEOF_JMP_REL );

	    	        *(BYTE*)( SrcVA + 0 ) = 0xE9;
			*(DWORD*)( SrcVA + 1 ) = ( DstVA - SrcVA - SIZEOF_JMP_REL );

			VirtualProtect( (VOID*)SrcVA, Size, dwProtect, &dwProtect );

			VirtualProtect( (VOID*)DetourVA, Size + 
				SIZEOF_JMP_REL, PAGE_EXECUTE_READ, &dwProtect );

	    	return DetourVA;
		}
	}
	return (0);
	}
DetourE9:
Code:
DWORD DetourE9( DWORD  SrcVA, DWORD  DstVA, DWORD  Size )
{
/* detour type: jmp rel */
/* it has no effect if you specify size below SIZEOF_JMP_REL */
/* by croner */

	DWORD DetourVA, dwProtect, i;

#define SIZEOF_JMP_REL  5

	if ( SrcVA && DstVA && Size >= SIZEOF_JMP_REL )
	{
		DetourVA = (DWORD) VirtualAlloc( 
			NULL, Size + SIZEOF_JMP_REL, 
			MEM_COMMIT, PAGE_EXECUTE_READWRITE );

		if ( DetourVA && VirtualProtect( (VOID*)SrcVA, Size, PAGE_EXECUTE_READWRITE, &dwProtect ) )
		{
			for ( i=0; i < Size; i++ ) {
				*(BYTE*)( DetourVA + i ) = *(BYTE*)( SrcVA + i );
			}
			
			*(BYTE*)( DetourVA + Size + 0 ) = 0xE9;
			*(DWORD*)( DetourVA + Size + 1 ) = ( SrcVA - DetourVA - SIZEOF_JMP_REL );

	    	        *(BYTE*)( SrcVA + 0 ) = 0xE9;
			*(DWORD*)( SrcVA + 1 ) = ( DstVA - SrcVA - SIZEOF_JMP_REL );

			VirtualProtect( (VOID*)SrcVA, Size, dwProtect, &dwProtect );

			VirtualProtect( (VOID*)DetourVA, Size + 
				SIZEOF_JMP_REL, PAGE_EXECUTE_READ, &dwProtect );

	    	return DetourVA;
		}
	}
	return (0);
}
By using this source, you'll get partyprogramm detected...

I think only Pro's can fixx it, Is there anyone?

I really have respect to those peoples.
12/01/2011 22:14 Wolf0fmusic#5990
Quote:
Originally Posted by Wolf0fmusic View Post
Request source code of : OFS_Rapidfire 0x1023C
??????????????
12/01/2011 23:13 boknoy24#5991
can you find source code of rapidfire here

[Only registered and activated users can see links. Click Here To Register...]
12/02/2011 10:50 xBioK1ngz#5992
DrawIndexedPrimitive is Detected with this Detour!
12/02/2011 12:11 CyberVeezy :)#5993
Quote:
Originally Posted by WARROCK_CODER View Post
@up
ye but i don't need source for opk ...
i need STRUCTS for opk
You must search the Structs self?
12/02/2011 14:15 Wamba123123#5994
Quote:
Originally Posted by xBioK1ngz View Post
DrawIndexedPrimitive is Detected with this Detour!
How to fixx god?
12/02/2011 14:56 xBioK1ngz#5995
Quote:
Originally Posted by Wamba123123 View Post
How to fixx god?
Find or make a undetected detour.
12/02/2011 14:56 Wamba123123#5996
[Only registered and activated users can see links. Click Here To Register...]

undetected?
12/02/2011 15:11 Angel-Piece#5997
Quote:
Originally Posted by Wamba123123 View Post
[Only registered and activated users can see links. Click Here To Register...]

undetected?
no
12/02/2011 15:17 Wamba123123#5998
you have one ?
12/02/2011 19:25 Venom'#5999
Kann mir jemand sagen was Px Items für eine Art ist ?
12/02/2011 22:40 GraFixPL#6000
Looking for codes for:
-Fulbright
-BlackBright
Only, that is to be at the addresses!