25.11.2013, 10:14
Here you go mate change the text to whatever you like and the [pmember], if you don't know how I'll do it for you.
Quote:
CMD:greet(playerid, params[]) { if(IsACop(playerid)) { new string[128], giveplayerid; if(sscanf(params, "i", giveplayerid)) return Syntax(playerid,"greet", "[playerid]"); if(IsPlayerConnected(giveplayerid)) { if(PlayerInfo[playerid][pMember] == 7) { format(string, sizeof(string), " You have greeted %s ", GetPlayerNameEx(giveplayerid)); SendClientMessageEx(playerid, COLOR_WHITE, string); format(string, sizeof(string), " Hello, I'm Deputy %s from the Los Santos Sheriff's Department ", GetPlayerNameEx(playerid)); SendClientMessageEx(giveplayerid, COLOR_GRAD1, string); SendClientMessageEx(giveplayerid, COLOR_GRAD1, "Do you know why I am stopping you today?"); } if(PlayerInfo[playerid][pMember] == 1) { format(string, sizeof(string), " You have greeted %s ", GetPlayerNameEx(giveplayerid)); SendClientMessageEx(playerid, COLOR_WHITE, string); format(string, sizeof(string), " Hello, I'm Officer %s from the Los Santos Police Department ", GetPlayerNameEx(playerid)); SendClientMessageEx(giveplayerid, COLOR_GRAD1, string); SendClientMessageEx(giveplayerid, COLOR_GRAD1, "Do you know why I am stopping you today?"); } } } else { SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!"); } return 1; } |