Page 2 of 2 FirstFirst 12
Results 16 to 20 of 20
  1. #16
    supercarz1991's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    North of Hell, South of Heaven
    Posts
    6,067
    Reputation
    323
    Thanks
    3,320
    My Mood
    Doh
    Code:
    bool Color = true;
    /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    
    LPDIRECT3DTEXTURE9    texYellow, texRed, texGreen, texBlue, texBlack, texWhite, texPink, texOrange, texLightBlue, texCyan, texPurple, texSteelBlue, texLightSteelBlue, texSalmon, texBrown, texTeal, texLime, texElectricLime, texGold, texOrangeRed, texGreenYellow, texAquaMarine, texSkyBlue, texSlateBlue, texCrimson, texDarkOliveGreen, texPaleGreen, texDarkGoldenRod, texFireBrick, texDarkBlue, texDarkerBlue, texDarkYellow, texLightYellow;
    
    ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    
    HRESULT GenerateShader(LPDIRECT3DDEVICE9 pD3Ddev, IDirect3DPixelShader9 **pShader, float r, float g, float b )
    {
        char szShader[ 256 ];
        ID3DXBuffer *pShaderBuf = NULL;
        sprintf( szShader, "ps.1.1\ndef c0, %f, %f, %f, %f\nmov r0,c0", r, g, b, 1.0f );
        D3DXAssembleShader( szShader, sizeof( szShader ), NULL, NULL, 0, &pShaderBuf, NULL );
        if( FAILED( pD3Ddev->CreatePixelShader((const DWORD*)pShaderBuf->GetBufferPointer(), pShader)) )return E_FAIL;
        return S_OK;
    }
    
    ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    
    if(Color)
            {
             GenerateTexture(pDevice, &texGreen , D3DCOLOR_ARGB(255,0,255,0));
         GenerateTexture(pDevice, &texRed , D3DCOLOR_ARGB(255,255,0,0));
         GenerateTexture(pDevice, &texBlue , D3DCOLOR_ARGB(255,0,0,255));
         GenerateTexture(pDevice, &texOrange , D3DCOLOR_ARGB(255,255,165,0));
         GenerateTexture(pDevice, &texYellow , D3DCOLOR_ARGB(255,255,255,0));
         GenerateTexture(pDevice, &texPink , D3DCOLOR_ARGB(255,255,192,203));
         GenerateTexture(pDevice, &texCyan , D3DCOLOR_ARGB(255,0,255,255));
         GenerateTexture(pDevice, &texPurple , D3DCOLOR_ARGB(255,160,32,240));
         GenerateTexture(pDevice, &texBlack , D3DCOLOR_ARGB(255,0,0,0));
         GenerateTexture(pDevice, &texWhite , D3DCOLOR_ARGB(255,255,255,255));
         GenerateTexture(pDevice, &texSteelBlue , D3DCOLOR_ARGB(255,33,104,140));
         GenerateTexture(pDevice, &texLightSteelBlue, D3DCOLOR_ARGB(255,201,255,255));
         GenerateTexture(pDevice, &texLightBlue , D3DCOLOR_ARGB(255,26,140,306));
         GenerateTexture(pDevice, &texSalmon , D3DCOLOR_ARGB(255,196,112,112));
         GenerateTexture(pDevice, &texBrown , D3DCOLOR_ARGB(255,168,99,20));
         GenerateTexture(pDevice, &texTeal , D3DCOLOR_ARGB(255,38,140,140));
         GenerateTexture(pDevice, &texLime , D3DCOLOR_ARGB(255,50,205,50));
         GenerateTexture(pDevice, &texElectricLime , D3DCOLOR_ARGB(255,204,255,0));
         GenerateTexture(pDevice, &texGold , D3DCOLOR_ARGB(255,255, 215, 0));
         GenerateTexture(pDevice, &texOrangeRed , D3DCOLOR_ARGB(255,255,69,0));
         GenerateTexture(pDevice, &texGreenYellow , D3DCOLOR_ARGB(255,173,255,47));
         GenerateTexture(pDevice, &texAquaMarine , D3DCOLOR_ARGB(255,127,255,212));
         GenerateTexture(pDevice, &texSkyBlue , D3DCOLOR_ARGB(255,0,191,255));
         GenerateTexture(pDevice, &texSlateBlue , D3DCOLOR_ARGB(255,132, 112, 255));
         GenerateTexture(pDevice, &texCrimson , D3DCOLOR_ARGB(255,220,20,60));
         GenerateTexture(pDevice, &texDarkOliveGreen, D3DCOLOR_ARGB(255,188,238,104 ));
         GenerateTexture(pDevice, &texPaleGreen , D3DCOLOR_ARGB(255,154,255, 154));
         GenerateTexture(pDevice, &texDarkGoldenRod , D3DCOLOR_ARGB(255,255, 185, 15 ));
         GenerateTexture(pDevice, &texFireBrick , D3DCOLOR_ARGB(255,255,48,48));
         GenerateTexture(pDevice, &texDarkBlue , D3DCOLOR_ARGB(255,0,0,204));
         GenerateTexture(pDevice, &texDarkerBlue , D3DCOLOR_ARGB(255,0,0,153));
         GenerateTexture(pDevice, &texDarkYellow , D3DCOLOR_ARGB(255,255,204,0));
         GenerateTexture(pDevice, &texLightYellow , D3DCOLOR_ARGB(255,255,255,153));
             GenerateShader( pDevice, &Blue,   0.0f, 0.0f, 1.0f );
         GenerateShader( pDevice, &Orange, 1.0f, 0.5f, 0.0f );
         GenerateShader( pDevice, &Purple, 1.0f, 0.0f, 1.0f );
         GenerateShader( pDevice, &White,  1.0f, 1.0f, 1.0f );
         GenerateShader( pDevice, &Yellow, 1.0f, 1.0f, 0.0f );
                    Color = false;
     
                   
            }
                    if(m_Stride == 32 || m_Stride == 36 || m_Stride == 44 )
                    {
                            pDevice->SetRenderState(D3DRS_ZENABLE, true);
                            pDevice->SetTexture(0, texGreen);
                            pDrawIndexedPrimitive(pDevice,pType D3DparamvalX,nMinIndex,nNumVertices,nStartIndex,nPrimitiveCount);
                            pDevice->SetTexture(0, texRed);
                            pDevice->SetRenderState(D3DRS_ZENABLE, false);
                    }
     
                    ifif(m_Stride == 32 || m_Stride == 36 || m_Stride == 44 )
                    {
                            pDevice->SetRenderState( D3DRS_ZENABLE,false );
                            pDevice->SetRenderState( D3DRS_FILLMODE,D3DFILL_SOLID );
                            pDevice->SetPixelShader( White );
                            pDrawIndexedPrimitive(pDevice,pType D3DparamvalX,nMinIndex,nNumVertices,nStartIndex,nPrimitiveCount);
                            pDevice->SetRenderState( D3DRS_ZENABLE, true );
                            pDevice->SetRenderState( D3DRS_FILLMODE,D3DFILL_SOLID );
                            pDevice->SetPixelShader( Blue );
                           
                    }
     
                    if(if(m_Stride == 32 || m_Stride == 36 || m_Stride == 44 )
                    {
                            SumStride=SumStride+4;
                            pDevice->SetRenderState(D3DRS_ZENABLE,false);
                            pDevice->SetRenderState(D3DRS_ALPHABLENDENABLE,false);
                            pDevice->SetRenderState(D3DRS_DESTBLEND,D3DBLEND_INVDESTCOLOR);
                            pDevice->SetRenderState(D3DRS_ZENABLE,false);
                           
                    }
     
                    ifif(m_Stride == 32 || m_Stride == 36 || m_Stride == 44 )
                    {
                            pDevice->SetRenderState(D3DRS_ZENABLE,false);
                            pDevice->SetRenderState( D3DRS_SRCBLEND, 4 );
                            pDevice->SetRenderState(D3DRS_DESTBLEND,D3DBLEND_INVDESTCOLOR);
                            pDevice->SetRenderState(D3DRS_ZENABLE,false);
                    }
     
     
            if(opt.d3d.HD)
            {
                                    pDevice->SetRenderState(D3DRS_SRCBLEND, D3DBLEND_SRCCOLOR);
            }
     
            if(opt.d3d.WhiteWalls)
            {
                            pDevice->SetRenderState(D3DRS_DESTBLEND, D3DBLEND_INVSRCCOLOR);
            }
     
            if(opt.d3d.NoGun)
            {
                    pDevice->SetRenderState(D3DRS_STENCILFUNC, D3DCMP_EQUAL);
            }
    have a blast. Credits to me on 90% of this. Will need modification to work with the dip posted here

    commando: You're probably the best non-coder coder I know LOL


  2. #17
    SpadeCA's Avatar
    Join Date
    Sep 2010
    Gender
    male
    Posts
    57
    Reputation
    7
    Thanks
    22
    My Mood
    Psychedelic
    To the wise men:
    Make sure you have a working MID hook or else you'll be crashing like mad.

  3. The Following User Says Thank You to SpadeCA For This Useful Post:

    supercarz1991 (04-08-2012)

  4. #18
    _Variavel_'s Avatar
    Join Date
    Apr 2012
    Gender
    male
    Posts
    1
    Reputation
    10
    Thanks
    9
    Thanks Friend,good job
    [X] Ser usuario iniciante em C++
    [X] Ser usuario InterMediario em C++
    [ ] Ser usuario Avançado em C++


    Missao :Reconstruino o T K O

  5. #19
    FR1GHT's Avatar
    Join Date
    Dec 2011
    Gender
    male
    Location
    Comendo Peru Pato Frango Burguer e Bebendo Whisky
    Posts
    1,632
    Reputation
    68
    Thanks
    984
    My Mood
    Yeehaw

    @supercarz1991

    This method is complete



  6. #20
    supercarz1991's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    North of Hell, South of Heaven
    Posts
    6,067
    Reputation
    323
    Thanks
    3,320
    My Mood
    Doh
    Quote Originally Posted by 50-CeNt- View Post

    @supercarz1991

    This method is complete
    i was just giving some more stuff for it, like shaders and more colors

    commando: You're probably the best non-coder coder I know LOL


Page 2 of 2 FirstFirst 12

Similar Threads

  1. [Source Code] CoD4 Chams Source Code
    By JoEyHaX in forum Call of Duty 4 - Modern Warfare (MW) Hacks
    Replies: 7
    Last Post: 08-17-2012, 05:00 AM
  2. [Request] D3D Chams Source Code C++ 2010
    By enverheckir in forum CrossFire Hack Coding / Programming / Source Code
    Replies: 6
    Last Post: 12-14-2011, 08:17 AM
  3. [Release] Chams Source Code
    By D3t0N4t3 in forum WarRock Hack Source Code
    Replies: 10
    Last Post: 03-10-2011, 06:29 AM
  4. [Kinda Release]AVA Chams Source Code
    By noleash in forum Alliance of Valiant Arms (AVA) Coding / Source Code
    Replies: 14
    Last Post: 11-30-2010, 03:14 PM
  5. Cham Colors And Their Codes
    By Zhellbound in forum Combat Arms Hacks & Cheats
    Replies: 4
    Last Post: 11-10-2008, 09:21 AM