Advertisement
Guest User

AntiDB

a guest
Apr 26th, 2010
1,887
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.59 KB | None | 0 0
  1. #include <a_samp>
  2.  
  3. new Weapons[MAX_PLAYERS][11], Ammo[MAX_PLAYERS][11];
  4.  
  5. public OnPlayerStateChange(playerid, newstate, oldstate)
  6. {
  7.     if((newstate == PLAYER_STATE_DRIVER) || (newstate == PLAYER_STATE_PASSENGER))
  8.     {
  9.         for(new j=0; j<11; j++) GetPlayerWeaponData(playerid, j, Weapons[playerid][j], Ammo[playerid][j]);
  10.         ResetPlayerWeapons(playerid);
  11.     }
  12.     if((newstate == PLAYER_STATE_ONFOOT) && ((oldstate == PLAYER_STATE_DRIVER) || (oldstate == PLAYER_STATE_PASSENGER)))
  13.     {
  14.         for(new j=0; j<11; j++) GivePlayerWeapon(playerid, Weapons[playerid][j], Ammo[playerid][j]);
  15.     }
  16.  
  17.     return 1;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement