Advertisement
Guest User

Untitled

a guest
Feb 2nd, 2014
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. CMD:carcommand(playerid,params[])
  2. {
  3. new
  4. szCom[100],
  5. szF[MAX_PLAYER_NAME +5],
  6. szName[MAX_PLAYER_NAME +1]
  7. ;
  8. GetPlayerName(playerid, szName, sizeof(szName));
  9. if(sscanf(params, "s[100]", szCom)) return SendClientMessage( playerid, -1, "Syntax: /test <text>");
  10. {
  11. format(szF, MAX_PLAYER_NAME +5, "%s.txt", szName,szCom);
  12.  
  13. if(!fexist(szF))
  14. {
  15. new
  16. File:iFile = fopen(szF, io_write);
  17.  
  18. fwrite(iFile, szCom);
  19. fclose(iFile);
  20. }
  21. else return SendClientMessage(playerid, -1, "Exista deja.");
  22. }
  23. return 1;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement