Add a COD4 hotkey

This is a discussion on Add a COD4 hotkey within the CoD 4 forum forum part of the Call of Duty category; Here's what i got so far to add COD4 hotkeys and it works perfectly in game. #include"windows.h" //Nametags BYTE Nametags1On[] ...


+ Reply to Thread
Results 1 to 4 of 4

Thread: Add a COD4 hotkey

  1. #1
    hendricius's Avatar
    hendricius is offline Administrator
    hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future hendricius has a brilliant future
    Join Date
    Feb 2007
    Location
    Hamburg, Germany
    Posts
    5,876
    Downloads
    108
    Uploads
    144
    Rep Power
    13
    Reputation
    1530

    Add a COD4 hotkey

    Here's what i got so far to add COD4 hotkeys and it works perfectly in game.

    #include"windows.h"
    //Nametags
    BYTE Nametags1On[] = {0x0F, 0x84, 0xCE, 0x00, 0x00, 0x00};//Nametags
    BYTE Nametags1Off[] = {0x0F, 0x85, 0xCE, 0x00, 0x00, 0x00};//0042E26C

    BYTE Nametags2On[] = {0x0F, 0x84, 0x09, 0x02, 0x00, 0x00};//DrawThroughWalls
    BYTE Nametags2Off[] = {0x0F, 0x85, 0x09, 0x02, 0x00, 0x00};//0042DF64

    unsignedlong Protection;
    BOOL WINAPI DllMain (HINSTANCE hModule, DWORD dwAttached, LPVOID lpvReserved)
    {
    if (dwAttached == DLL_PROCESS_ATTACH)
    {
    VirtualProtect((void*)0x0042E26C, 6, PAGE_READWRITE, &Protection);
    memcpy((void*)0x0042E26C, (constvoid*)Nametags1On, 6);
    VirtualProtect((void*)0x0042E26C, 6, Protection, 0);

    VirtualProtect((void*)0x0042DF64, 6, PAGE_READWRITE, &Protection);
    memcpy((void*)0x0042DF64, (constvoid*)Nametags2On, 6);
    VirtualProtect((void*)0x0042DF64, 6, Protection, 0);
    }
    }
    but i would like to be able to toggle it on and off while in game....could someone kindly give me a hand to get like a hotkey happening here...i have had previous attempts but obviously with no luck so far...

    here would be the off feature

    VirtualProtect((void*)0x0042E26C, 6, PAGE_READWRITE, &Protection);
    memcpy((void*)0x0042E26C, (constvoid*)Nametags1Off, 6);
    VirtualProtect((void*)0x0042E26C, 6, Protection, 0);

    VirtualProtect((void*)0x0042DF64, 6, PAGE_READWRITE, &Protection);
    memcpy((void*)0x0042DF64, (constvoid*)Nametags2Off, 6);
    VirtualProtect((void*)0x0042DF64, 6, Protection, 0);
    source:
    [Coding] - Adding a hotkey - UnKnoWnCheaTs

  2. #2
    Ryan's Avatar
    Ryan is offline myspace.com/ryan_str0up
    Ryan is a glorious beacon of light Ryan is a glorious beacon of light Ryan is a glorious beacon of light Ryan is a glorious beacon of light Ryan is a glorious beacon of light
    Join Date
    Jul 2007
    Location
    Folsom, California
    Posts
    2,202
    Downloads
    22
    Uploads
    2
    Rep Power
    6
    Reputation
    480
    Very Nice. Rep Added.




  3. #3
    firefly71's Avatar
    firefly71 is offline Wannabe Member
    firefly71 is an unknown quantity at this point
    Join Date
    Aug 2008
    Location
    New Jersey
    Posts
    21
    Downloads
    0
    Uploads
    0
    Rep Power
    2
    Reputation
    1
    Very nice indeed

  4. #4
    Pennypacker is offline Newbie
    Pennypacker is an unknown quantity at this point
    Join Date
    Aug 2008
    Location
    Texas
    Posts
    8
    Downloads
    0
    Uploads
    0
    Rep Power
    2
    Reputation
    1
    ty

+ Reply to Thread

Similar Threads

  1. Quantum's lossbot tutorial , well explained
    By quantum in forum Warcraft 3 forum
    Replies: 13
    Last Post: 12-21-2009, 04:45 PM
  2. Replies: 19
    Last Post: 10-07-2008, 01:21 AM
  3. [Guide] Add your own .ini to your GS
    By Milamber in forum Mu Archives
    Replies: 0
    Last Post: 03-22-2008, 08:08 PM
  4. How to add Vendor Waypoints
    By hendricius in forum Glider
    Replies: 0
    Last Post: 03-20-2008, 11:38 AM
  5. Photoshop. Where please?
    By Velocity in forum General Chat
    Replies: 30
    Last Post: 09-24-2007, 08:14 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Dboyz Interactive Skillhackers