Guest User

Untitled

a guest
May 29th, 2012
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.08 KB | None | 0 0
  1. command(cuff, playerid, params[])
  2. {
  3. new id, string[128];
  4. if(sscanf(params, "u", id))
  5. {
  6. SendClientMessage(playerid, WHITE, "SYNTAX: /cuff [playerid]");
  7. }
  8. else
  9. {
  10. if(Groups[Player[playerid][Group]][CommandTypes] == 1 || Groups[Player[playerid][Group]][CommandTypes] == 4)
  11. {
  12. if(Player[id][Tazed] == 1)
  13. {
  14. if(GetDistanceBetweenPlayers(playerid, id) < 7)
  15. {
  16. TogglePlayerControllable(id, false);
  17. ApplyAnimation(id, "ped", "cower", 1, 1, 0, 0, 0, 0);
  18. Player[id][Cuffed] = 1;
  19. Player[id][Tazed] = 0;
  20. format(string, sizeof(string), "* %s has cuffed %s.", GetName(playerid), GetName(id));
  21. NearByMessage(playerid, NICESKY, string);
  22. format(string, sizeof(string), "You have cuffed %s.", GetName(id));
  23. SendClientMessage(playerid, WHITE, string);
  24. format(string, sizeof(string), "You have been cuffed by %s.", GetName(playerid));
  25. SendClientMessage(id, WHITE, string);
  26. TogglePlayerControllable(id, false);
Advertisement
Add Comment
Please, Sign In to add comment