Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CMD:sms(playerid, params[])
- {
- if(PlayerInfo[playerid][pTelefon] >= 1)
- {
- new string[256], string1[256];
- new text[256];
- new sendername[MAX_PLAYER_NAME];
- new guza[MAX_PLAYER_NAME];
- new id = -1;
- new broj;
- if(sscanf(params,"is[256]", broj, text)) return SendClientMessage(playerid, COLOR_ORANGE, "{FFFF00}[LZ] {AFAFAF}Koriscenje | /sms [Ime igraca/ID] [text]");
- foreach(Player, i)
- {
- if(PlayerInfo[i][pBrojmoba] == broj) id = i;
- }
- if(id == -1) return SCM(playerid,COLOR_WHITE, "{FFFF00}[LZ|SMS] Uneli ste nepostojeci broj.");
- GetPlayerName(playerid,sendername,sizeof(sendername));
- GetPlayerName(id,guza,sizeof(guza));
- format(string,sizeof(string),"{FFFF00}[LZ|SMS]{FFFFFF} Stigao vam je SMS.{F3FF02} Poslao: %s", sendername);
- SendClientMessage(id, COLOR_WHITE, string);
- format(string1,sizeof(string1),"{FFFF00}[LZ|SMS] {F3FF02}Sms glasi:{FFFFFF} %s", text);
- SendClientMessage(id, COLOR_WHITE, string1);
- SCM(playerid, COLOR_WHITE, "{FFFF00}[LZ|SMS]{AFAFAF} Poruka uspesno dostavljena!");
- GivePlayerMoney(playerid, -1);
- GameTextForPlayer(playerid, "~r~-1$", 2500, 1);
- }
- else SCM(playerid, COLOR_WHITE, "{FFFF00}[LZ]{AFAFAF} Nemate telefon.");
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment