Advertisement
BaSs_HaXoR

SPRX Give/Take Client Weapon

Sep 15th, 2014
407
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.37 KB | None | 0 0
  1. #define G_Client(clientIndex)   ( 0x0110A280 + ( clientIndex * 0x3980) )
  2.  
  3. void TakeWeapon(int clientIndex, int WeaponIndex, int takeAwayAmmo)
  4. {
  5.     opd_s BG_TPW = { 0x001C409C, TOC };
  6.     void(*BG_TakePlayerWeapon)(int *playerState, int WeaponIndex, int takeAwayAmmo) = (void(*)(int*, int, int))&BG_TPW;
  7.     BG_TakePlayerWeapon((int*)G_Client(clientIndex), WeaponIndex, takeAwayAmmo);
  8. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement