Advertisement
Guest User

clan

a guest
Dec 2nd, 2018
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.25 KB | None | 0 0
  1. public LoadClanInfo()
  2. {
  3. clanss = cache_num_rows();
  4. for(new i = 1; i <= clanss; i++)
  5. {
  6. new x = i - 1;
  7. ClanInfo[i][cClanID] = cache_get_field_content_int(x, "clanID");
  8. ClanInfo[i][cClanExpire] = cache_get_field_content_int(x, "clanExpire");
  9. ClanInfo[i][cClanActive] = cache_get_field_content_int(x, "clanActive");
  10. ClanInfo[i][cClanSlots] = cache_get_field_content_int(x, "clanSlots");
  11. ClanInfo[i][cClanSeif] = cache_get_field_content_int(x, "clanSeif");
  12. cache_get_field_content(x, "clanName", ClanInfo[i][cClanName], SQL, 130);
  13. cache_get_field_content(x, "clanColor", ClanInfo[i][cClanColor], SQL, 130);
  14. cache_get_field_content(x, "clanMOTD", ClanInfo[i][cClanMOTD], SQL, 130);
  15. cache_get_field_content(x, "clanTag", ClanInfo[i][cClanTag], SQL, 130);
  16. cache_get_field_content(x, "clanRankName7", ClanInfo[i][cClanRankName7], SQL, 130);
  17. cache_get_field_content(x, "clanRankName6", ClanInfo[i][cClanRankName6], SQL, 130);
  18. cache_get_field_content(x, "clanRankName5", ClanInfo[i][cClanRankName5], SQL, 130);
  19. cache_get_field_content(x, "clanRankName4", ClanInfo[i][cClanRankName4], SQL, 130);
  20. cache_get_field_content(x, "clanRankName3", ClanInfo[i][cClanRankName3], SQL, 130);
  21. cache_get_field_content(x, "clanRankName2", ClanInfo[i][cClanRankName2], SQL, 130);
  22. cache_get_field_content(x, "clanRankName1", ClanInfo[i][cClanRankName1], SQL, 130);
  23. LoadClanCar(i);
  24. }
  25. printf("[LOADING] %d clans loaded.", clanss);
  26. }
  27.  
  28.  
  29.  
  30. case 7: {
  31. mysql_format(SQL, var100, sizeof(var100), "SELECT * FROM `clans`");
  32. mysql_tquery(SQL, var100, "LoadClanInfo", "");
  33. foreach(new ids : Player)
  34. {
  35. if(IsPlayerConnected(ids))
  36. {
  37. if(PlayerInfo[ids][pSQLID] == playerid)
  38. {
  39. PlayerInfo[ids][pClan] = complaint;
  40. PlayerInfo[ids][pCRank] = 7;
  41. PlayerInfo[ids][pPremiumPoints] -= 100;
  42. }
  43. }
  44. }
  45. mysql_format(SQL, var100, sizeof(var100), "INSERT INTO `emails` (`playerid`,`Message`) VALUES('%d','Felicitari! Ai cumparat un clan cu numele %s, foloseste /clan pentru a deschide meniul acestuia.')",playerid,playername);
  46. mysql_tquery(SQL,var100,"","");
  47. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement