Wall hack Texture Bug

Posts 1–4 of 4 · Page 1 of 1
Wall hack Texture Bug
Does anyone know how to fix this crap? i have a source for wall hack but the wall hack doesn't show through every texture it bugs a lot and only shows through certain textures i don't want to remove the textures because then if i tried shooting and i hit the object for example i cant see enemy through a rock so i removed the texture rendered it as see through if i didnt know it was there id shoot it.

Shader
Code:
HRESULT GenerateShader(IDirect3DDevice9 *pDevice, IDirect3DPixelShader9 **pShader, float r, float g, float b)
{
    char szShader[256];
    ID3DXBuffer *pShaderBuf = NULL;
    sprintf(szShader, "ps_3_0\ndef c0, %f, %f, %f, %f\nmov oC0,c0", r, g, b, 1.0f);
    D3DXAssembleShader(szShader, sizeof(szShader), NULL, NULL, 0, &pShaderBuf, NULL);
    if (FAILED(pDevice->CreatePixelShader((const DWORD*)pShaderBuf->GetBufferPointer(), pShader)))return E_FAIL;
    return S_OK;
}
button function
Code:
    if (wh) {
        if (_Features[0]) {
            pDevice->SetRenderState(D3DRS_ZENABLE, FALSE);
            pDevice->SetPixelShader(BlueTex);
            oDrawIndexedPrimitive(pDevice, Type, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, PrimitiveCount);
            pDevice->SetRenderState(D3DRS_ZENABLE, TRUE);
            pDevice->SetPixelShader(RedTex);
        }
    }
Hook
Code:
int  InitD3D(void)
{
    DWORD D3DBase, ResultadoD3DBase, *vTable;

     D3DBase = 0; do { // wait till we  can find the d3d9 dll the game and  grab its base address. The base address is where the dll (module) gets  loaded in memory
        D3DBase = (DWORD)GetModuleHandle("d3d9.dll");
        Sleep(10);
    }


    while (!D3DBase); // grab pattern of D3D9 Vtable, or VMT Table, or virtual method table
     ResultadoD3DBase = ProcurePattern(D3DBase, 0x128000,  (PBYTE)"\xC7\x06\x00\x00\x00\x00\x89\x86\x00\x00\x00\x00\x89\x86",  "xx????xx????xx");

    // vtable + 0x0 = Function1Address
    // vtable + 0x4 = Function2Address
    // vtable + 0x8 = Function3Address
    // vtable + 0xC = Function4Address

    if (ResultadoD3DBase) { // if we found the vtable in memory, if your in a d3d9 game this will always be found.
        memcpy(&vTable, (void *)(ResultadoD3DBase + 2), 4); // make own copy

        oEndScene = (tEndScene)DetourFunction((PBYTE)vTable[42], (PBYTE)hkEndScene);

        oDrawIndexedPrimitive = (tDrawIndexedPrimitive)DetourFunction((PBYTE)vTable[82], (PBYTE)hkDrawIndexedPrimitive);

    }

    return 0; // return out of function
}
Quote Originally Posted by _PuRe.LucK* View Post
stop copypasting
ill stop once you stop copy and pasting bs on peoples threads
It's completely normal for some chams to not show through some surfaces. It has to do with D3D's native depth perception.
Although, I'm not sure of what the degree you speak of is since you didn't show any examples.
Posts 1–4 of 4 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us