Advertisement
AlexRap

Untitled

Jul 3rd, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.59 KB | None | 0 0
  1. stock ShowFactions(playerid) {
  2. new szDialog[MAX_STRING], szDialog2[MAX_STRING];
  3. format(szDialog, sizeof(szDialog), "{FFFFFF}ID\tName\tMembers\tMaxim Members\n{FFFFFF}1\t%s\t%d\t%d\n", DynamicFactions[1][fName], GetFactionMembers(1), DynamicFactions[1][fMaxMembers]);
  4. strcat(szDialog2, szDialog);
  5.  
  6. de la showfactions pui asta in locul primei iti dai si tu seama acolo
  7.  
  8. CMD:paydaymoney(playerid, params[])
  9. {
  10. if(PlayerInfo[playerid][pAdmin] >= 5)
  11. {
  12. new fid,money,string[MAX_STRING];
  13. if(sscanf(params, "dd",fid,money)) return SendClientMessage(playerid, 0xFFFFFFFF, "{AB0000}Usage: {FFFFFF}/paydaymoney <Faction ID> <Money>");
  14. if(money > 0 && money <= 500000)
  15. {
  16. if(fid > 0 && fid <= 14)
  17. {
  18. if(fid == 7) return SendClientMessage(playerid, COLOR_WHITE,"Aceasta factiune nu mai exista.");
  19. DynamicFactions[fid][fPaydayMoney] = money;
  20. mysql_format(SQL, string, sizeof(string), "UPDATE `factions` SET `PaydayMoney`='%d' WHERE `ID`='%d'",DynamicFactions[fid][fPaydayMoney], fid);
  21. mysql_tquery(SQL,string,"","");
  22. format(string, sizeof(string), "Acum factiunea %s primeste $%s la PayDay in seif.",DynamicFactions[fid][fName], FormatNumber(DynamicFactions[fid][fPaydayMoney]));
  23. SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
  24. }
  25. else return SendClientMessage(playerid, COLOR_WHITE,"Faction ID must be between 1 and 14.");
  26. }
  27. else return SendClientMessage(playerid, COLOR_WHITE,"Money must be between $1 and $500,000.");
  28. }
  29. else
  30. {
  31. SendClientMessage(playerid, COLOR_ERROR, AdminOnly);
  32. }
  33. return 1;
  34. }
  35. inlocuieste o cu cea veche asta e putin imbunatatita
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement