SHARE
TWEET

Untitled




Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- #define ADDR_WeaponMgrPointer 0x2294530
- #define M16 25
- #define M4A1_S_Predator 1508
- void DoWeaponReplace(DWORD currentweaponid, DWORD newweaponid)
- {
- DWORD CShell = (DWORD)GetModuleHandleA("CShell.dll");
- DWORD pWeaponMgr = *(DWORD*)(CShell + ADDR_WeaponMgrPointer);
- if(pWeaponMgr)
- {
- DWORD currentweapon = pWeaponMgr + 4 * currentweaponid;
- DWORD newweapon = pWeaponMgr + 4 * newweaponid;
- if(currentweapon)
- {
- if(newweapon)
- {
- *(DWORD*)currentweapon = *(DWORD*)newweapon;
- }
- }
- }
- }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy.