Advertisement
Guest User

Untitled

a guest
Oct 17th, 2018
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.31 KB | None | 0 0
  1. CMD:r(playerid, params[]) return cmd_radio(playerid, params);
  2. CMD:radio(playerid, params[]) {
  3. if(!IsPlayerLogged[playerid]) return SCM(playerid, -1, "Trebuie sa te loghezi mai intai.");
  4. new msj[144], string[144], query[144], member = PlayerInfo[playerid][pMember];
  5. if(member == 1 || member == 3 || member == 2) {
  6. if(sscanf(params, "s[144]", msj)) return SCM(playerid, COLOR_GREY, ""CUL"Sintaxa:{ffffff} /r [message]");
  7. format(string, 144, "*** %s %s: %s, over.", PlayerFaction[PlayerInfo[playerid][pMember]][fRankName7], getName(playerid), msj);
  8. foreach(new i : Player) {
  9. if(PlayerInfo[i][pMember] == member) SendFactionMessage(PlayerInfo[playerid][pMember], COLOR_RADIOCHAT, string);
  10. if(FactionSpec[i] == member && PlayerInfo[i][pAdmin] >= 1) SendFactionMessage(PlayerInfo[playerid][pMember], COLOR_RADIOCHAT, string);
  11. }
  12. format(string, 144, "(radio) ''%s''", params);
  13. SetPlayerChatBubble(playerid, string, COLOR_CHATBUBBLE, 10.0, 10000);
  14. mysql_format(SQL, query, 144, "INSERT INTO chat_logs (`playerid`,`text`,`where`) VALUES ('%d','%s','r')", PlayerInfo[playerid][pSQLID], string);
  15. mysql_tquery(SQL, query, "", "");
  16. }
  17. else return SCM(playerid, -1, "Aceasta comanda este doar pentru departamente.");
  18. return true; }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement