Chat problem

Započeo Bilsen_Jahjagic, Mart 10, 2013, 22:19:31 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 3 gostiju pregledaju ovu temu.

Bilsen_Jahjagic

Skripta koju koristim:FS:RP
Opis problema:Nekad igrac napise nesto u IC chatu i to svi vide.Nzm u cemu je problem pa nmg postavit taj dio skripte.
Dio skripte:/


Bilsen_Jahjagic

Evo public OnPlayerText(playerid, text[])
{
new sendername[MAX_PLAYER_NAME];
new giveplayer[MAX_PLAYER_NAME];
new tmp[256];
new string[256];
    //new gPlayerUsingLoopingAnim[MAX_PLAYERS];
SetPlayerChatBubble(playerid, text, COLOR_GRAD1, 20.0, 10000); //poruka iznad glave
    //LoopingAnim(playerid,"PED","IDLE_CHAT",4.0,1,0,0,1,1);
if(PlayerInfo[playerid][pMuted] == 1)
{
SendClientMessage(playerid, TEAM_CYAN_COLOR, "{F81414}[FS:RP] {0084e3}Ne mozes pricati, mutiran si!");
return 0;
}
    if(AdvertisementCheck(text) && !IsPlayerAdmin(playerid))
{
    GetPlayerName(playerid, sendername, sizeof(sendername));
format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Ne reklamiraj dobices ban ({F81414}Admini/Gamemasteri {0084e3}su upozoreni o pokusaju reklamiranja)!");
SendClientMessage( playerid, 0xFF4444FF, string);
    format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Igrac %s pokusava da reklamira opomenite ga!", sendername);
SendAdminGmMessage(COLOR_LIGHTRED, string);
return 0;
}
if(anty(text))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Ne reklamiraj dobices ban ({F81414}Admini/Gamemasteri {0084e3}su upozoreni o pokusaju reklamiranja)!");
SendClientMessage( playerid, 0xFF4444FF, string);
    format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Igrac %s pokusava da reklamira opomenite ga!", sendername);
SendAdminGmMessage(COLOR_LIGHTRED, string);
return 0;
}
if(SelectChar[playerid] == 255)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("next", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("next")))
{
    switch (SelectCharID[playerid])
{
case 20:
{
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, CivMalePeds[1][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = CivMalePeds[1][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, CivMalePeds[2][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = CivMalePeds[2][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, CivMalePeds[3][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = CivMalePeds[3][0]; }
    else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, CivMalePeds[4][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = CivMalePeds[4][0]; }
    else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, CivMalePeds[5][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = CivMalePeds[5][0]; }
    else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, CivMalePeds[6][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = CivMalePeds[6][0]; }
    else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, CivMalePeds[7][0]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = CivMalePeds[7][0]; }
    else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, CivMalePeds[8][0]); SelectCharPlace[playerid] = 9; ChosenSkin[playerid] = CivMalePeds[8][0]; }
}
case 30:
{
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, CivFemalePeds[1][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = CivFemalePeds[1][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, CivFemalePeds[2][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = CivFemalePeds[2][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, CivFemalePeds[3][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = CivFemalePeds[3][0]; }
    else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, CivFemalePeds[4][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = CivFemalePeds[4][0]; }
    else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, CivFemalePeds[5][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = CivFemalePeds[5][0]; }
    else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, CivFemalePeds[6][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = CivFemalePeds[6][0]; }
}

}
    return 0;
}
else if ((strcmp("done", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("done")))
{
    if(ChangePos2[playerid][1] == 1)
    {
        SetPlayerInterior(playerid, ChangePos2[playerid][0]);
        JBC_SetPlayerPos(playerid, ChangePos[playerid][0],ChangePos[playerid][1],ChangePos[playerid][2]);
        ChangePos2[playerid][1] = 0;
        //return 0;
    }
    MedicBill[playerid] = 0;
    PlayerInfo[playerid][pModel] = ChosenSkin[playerid];
    PlayerInfo[playerid][pChar] = ChosenSkin[playerid];
    SetSpawnInfo(playerid, PlayerInfo[playerid][pTeam], PlayerInfo[playerid][pModel],0.0,0.0,0.0,0,0,0,0,0,0,0);
    gTeam[playerid] = PlayerInfo[playerid][pTeam];
SetPlayerToTeamColor(playerid);
MedicBill[playerid] = 0;
SpawnPlayer(playerid);
MedicBill[playerid] = 0;
    SelectCharPlace[playerid] = 0;
    SelectCharID[playerid] = 0;
    SelectChar[playerid] = 0;
    SetPlayerVirtualWorld(playerid,0);
    SetTimerEx("backtoclothes", 1000, false, "i", playerid);
    MedicBill[playerid] = 0;
BizzInfo[3][bTill] += 100;
ExtortionBiz(3, 100);
            BizzInfo[4][bTill] += 100;
ExtortionBiz(4, 100);
            BizzInfo[16][bTill] += 100;
ExtortionBiz(16, 100);
            BizzInfo[17][bTill] += 100;
ExtortionBiz(17, 100);

return 0;
}
else
{
    SendClientMessage(playerid, COLOR_WHITE, "{F81414}(GRESKA) {FFAF00}Kucaj u chatu ( {F81414}next {FFAF00}) da listas skinove ( {F81414}done {FFAF00}) da kupis skin.");
    return 0;
}
}
if(MarriageCeremoney[playerid] > 0)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
    if(GotProposedBy[playerid] < 999)
    {
    if(IsPlayerConnected(GotProposedBy[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(GotProposedBy[playerid], giveplayer, sizeof(giveplayer));
    format(string, sizeof(string), "Pop: %s da li uzimate %s-u za svoju zenu? (kucajte 'yes', sve ostalo ce se smatrati negativnim odgovorom).", giveplayer,sendername);
SendClientMessage(GotProposedBy[playerid], COLOR_WHITE, string);
MarriageCeremoney[GotProposedBy[playerid]] = 1;
MarriageCeremoney[playerid] = 0;
GotProposedBy[playerid] = 999;
    return 1;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        GotProposedBy[playerid] = 999;
        return 0;
    }
}
else if(ProposedTo[playerid] < 999)
{
    if(IsPlayerConnected(ProposedTo[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(ProposedTo[playerid], giveplayer, sizeof(giveplayer));
if(PlayerInfo[playerid][pSex] == 1 && PlayerInfo[ProposedTo[playerid]][pSex] == 2)
{
format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Zenom, mozete poljubiti Mladu.", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s and %s proglasavam vas...Muzem & Zenom, mozete poljubiti Mladozenju.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Novosti: Imamo novi par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
else if(PlayerInfo[playerid][pSex] == 1 && PlayerInfo[ProposedTo[playerid]][pSex] == 1)
{
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Muzem, mozete poljubiti Mladu :).", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Muzem, mozete poljubiti Mladozenju.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Novosti: Imamo novi Gay par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
else if(PlayerInfo[playerid][pSex] == 2 && PlayerInfo[ProposedTo[playerid]][pSex] == 2)
{
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Zenom & Zenom, mozete poljubiti Mladu.", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Zenom & Zenom, mozete poljubiti Mladu.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Marriage News: Imamo novi Lesbo par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
MarriageCeremoney[ProposedTo[playerid]] = 0;
MarriageCeremoney[playerid] = 0;
format(string, sizeof(string), "%s", sendername);
strmid(PlayerInfo[ProposedTo[playerid]][pMarriedTo], string, 0, strlen(string), 255);
format(string, sizeof(string), "%s", giveplayer);
strmid(PlayerInfo[playerid][pMarriedTo], string, 0, strlen(string), 255);
SafeJBC_GivePlayerMoney(playerid, - 20000);
PlayerInfo[playerid][pMarried] = 1;
PlayerInfo[ProposedTo[playerid]][pMarried] = 1;
PlayerInfo[ProposedTo[playerid]][pPhousekey] = PlayerInfo[playerid][pPhousekey];
PlayerInfo[ProposedTo[playerid]][pPbiskey] = PlayerInfo[playerid][pPbiskey];
ProposedTo[playerid] = 999;
MarriageCeremoney[playerid] = 0;
    return 1;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        ProposedTo[playerid] = 999;
        return 0;
    }
}
}
else
{
    if(GotProposedBy[playerid] < 999)
    {
if(IsPlayerConnected(GotProposedBy[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(GotProposedBy[playerid], giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "* Niste htjeli da se vjencate sa %s-om, niste rekli 'yes'.",giveplayer);
    SendClientMessage(playerid, COLOR_YELLOW, string);
    format(string, sizeof(string), "* %s nije htio/la da se vjenca sa vama, nije rekao/la 'yes'.",sendername);
    SendClientMessage(GotProposedBy[playerid], COLOR_YELLOW, string);
    return 0;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        GotProposedBy[playerid] = 999;
        return 0;
    }
    }
    else if(ProposedTo[playerid] < 999)
{
    if(IsPlayerConnected(ProposedTo[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(ProposedTo[playerid], giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "* Niste hjteli da se vjencate sa %s, niste rekli 'yes'.",giveplayer);
    SendClientMessage(playerid, COLOR_YELLOW, string);
    format(string, sizeof(string), "* %s nije htio/la da se vjenca sa vama, nije rekao/la 'yes'.",sendername);
    SendClientMessage(ProposedTo[playerid], COLOR_YELLOW, string);
    return 0;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        ProposedTo[playerid] = 999;
        return 0;
    }
}
}
    return 0;
}
if(WritingPaper[playerid] > 0)
{
    new line;
        new nstring[256];
        new idx;
        new length = strlen(text);
while ((idx < length) && (text[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[64];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = text[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
    if(WritingLine[playerid] == 1) { SendClientMessage(playerid, COLOR_GRAD2, "* Molimo vas upisite Naslov vasih novina."); }
    else { SendClientMessage(playerid, COLOR_LIGHTRED, "* Molimo vas kucajte tekst vasih novina."); }
return 0;
}
format(nstring, sizeof(nstring), "%s", text);
switch(WritingLine[playerid])
{
    case 1:
    {
        new fstring[MAX_PLAYER_NAME];
        GetPlayerName(playerid, sendername, sizeof(sendername));
format(fstring, sizeof(fstring), "%s", sendername);
strmid(PaperInfo[WritingPaperNumber[playerid]][PaperMaker], fstring, 0, strlen(fstring), 255);
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperTitle], nstring, 0, strlen(nstring), 255);
        line = 0; WritingLine[playerid] = 2;
        SendClientMessage(playerid, COLOR_LIGHTRED, "* Sada mozete pisati redove u vasim novinama, 7 vam je ostalo.");
    }
    case 2:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText1], nstring, 0, strlen(nstring), 255);
        line = 1; WritingLine[playerid] = 3;
    }
    case 3:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText2], nstring, 0, strlen(nstring), 255);
        line = 2; WritingLine[playerid] = 4;
    }
    case 4:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText3], nstring, 0, strlen(nstring), 255);
        line = 3; WritingLine[playerid] = 5;
    }
    case 5:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText4], nstring, 0, strlen(nstring), 255);
        line = 4; WritingLine[playerid] = 6;
    }
    case 6:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText5], nstring, 0, strlen(nstring), 255);
        line = 5; WritingLine[playerid] = 7;
    }
    case 7:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText6], nstring, 0, strlen(nstring), 255);
        line = 6; WritingLine[playerid] = 8;
    }
    case 8:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText7], nstring, 0, strlen(nstring), 255);
        PaperInfo[WritingPaperNumber[playerid]][PaperUsed] = 1;
        SavePapers();
        line = 7; WritingLine[playerid] = 0; WritingPaper[playerid] = 0; WritingPaperNumber[playerid] = 999;
    }
}
if(line > 0)
{
format(string, sizeof(string), "* Napisali ste %d red/a/ova u vasim novina.", line);
SendClientMessage(playerid, COLOR_WHITE, string);
if(line == 7)
{
    SendClientMessage(playerid, COLOR_WHITE, "* Vase Novine su dodate na listi Novina (za Raznosace Novina).");
}
}
    return 0;
}
if(CallLawyer[playerid] == 111)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string, sizeof(string), "** %s je u zatvoru i treba advokata. Idite u Policijsku Stanicu.", sendername);
    SendJobMessage(2, TEAM_AZTECAS_COLOR, string);
    SendJobMessage(2, TEAM_AZTECAS_COLOR, "* Kada ste u Policijskoj Stanici, pitajte nekog policajca da vam dozvoli oslobadjanje sa /accept lawyer.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Poruka je poslata svim slobodnim advokatima, molimo sacekajte.");
    WantLawyer[playerid] = 0;
CallLawyer[playerid] = 0;
    return 0;
}
else
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "Trenutno nema slobodnih advokata, zatvorska kazna je pocela.");
    WantLawyer[playerid] = 0;
CallLawyer[playerid] = 0;
    return 0;
}
}
if(TalkingLive[playerid] != 255)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9)
{
    format(string, sizeof(string), "{FF00EA}[SE:RT] Novinar %s: {FFFFFF}%s", sendername, text);
OOCNews(COLOR_LIGHTGREEN, string);
}
else
{
    format(string, sizeof(string), "{FF00EA}[SE:RT] Gost %s: {FFFFFF}%s", sendername, text);
OOCNews(COLOR_LIGHTGREEN, string);
}
return 0;
}
if(Mobile[playerid] != 255)
{
new idx;
tmp = strtok(text, idx);
GetPlayerName(playerid, sendername, sizeof(sendername));
           new result[256];
   new brojevi[] = { '1','2','3','4','5','6','7','8','9'};
          for(new b = 0; b < sizeof brojevi; b++)
{
new tekst = strlen(result);
for(new i = 0; i<tekst; i++)
{
if(result[i] == brojevi[b])
result[i] = '*' ;
}
}
if(UnidentifedCall[playerid] == 1)
{
    format(string, sizeof(string), "{F3FF02}Stranac kaze (telefon): %s", text);
}
else
{
format(string, sizeof(string), "{F3FF02}%s kaze (telefon): %s", sendername, text);
}
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
if(Mobile[playerid] == 914)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Izvinite, ne razumijem?");
return 0;
}
new turner[MAX_PLAYER_NAME];
new wanted[128];
GetPlayerName(playerid, turner, sizeof(turner));
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Javili smo svim jedinicama u tom podruciju.");
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Hvala vam sto ste prijavili incident");
format(wanted, sizeof(wanted), "Dispacher: Svim jedinicama, novi incident: Prijavio: %s",turner);
SendTeamBeepMessage(1, TEAM_CYAN_COLOR, wanted);
format(wanted, sizeof(wanted), "Dispacher: Incident: %s",text);
SendTeamMessage(1, TEAM_CYAN_COLOR, wanted);
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
emdtrace = 1; emdtrace_x = trace_x; emdtrace_y = trace_y; emdtrace_z = trace_z;
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if(Mobile[playerid] == 913)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem?");
return 0;
}
if ((strcmp("no", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("no")))
{
new turner[MAX_PLAYER_NAME];
new wanted[128];
GetPlayerName(playerid, turner, sizeof(turner));
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Javili smo svim jedinicama u tom podruciju .");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala vam sto ste prijavili zlocin");
format(wanted, sizeof(wanted), "BAZA: Svim jedinicama, novi zlocin: Prijavio: %s",turner);
SendFamilyMessage(1, COLOR_DBLUE, wanted);
format(wanted, sizeof(wanted), "BAZA: Zlocin: %s, Osumnjiceni: Nepoznat",PlayerCrime[playerid][pAccusing]);
SendFamilyMessage(1, COLOR_DBLUE, wanted);
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
pdtrace = 1; pdtrace_x = trace_x; pdtrace_y = trace_y; pdtrace_z = trace_z;
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
new badguy;
badguy = ReturnUser(tmp);
if (IsPlayerConnected(badguy))
{
    if(badguy != INVALID_PLAYER_ID)
    {
if (gTeam[badguy] == 2 || gTeam[badguy] == 1)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Moracete da prijavite unutrasnjoj kontroli.");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if (WantedPoints[badguy] > 0)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Sve jedinice su vec obavjestene o tom slucaju");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala vam sto ste prijavili taj zlocin");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if (badguy == playerid)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Nemojte se zezati, ovo je linija za hitne slucajeve.");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Javili smo svim jedinicama u tom podruciju.");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala sto ste prijavili zlocin");
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
pdtrace = 1; pdtrace_x = trace_x; pdtrace_y = trace_y; pdtrace_z = trace_z;
SetPlayerCriminal(badguy,playerid, PlayerCrime[playerid][pAccusing]);
if(WantedPoints[badguy] > 0) { } else { WantedPoints[badguy] += 2; }
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
return 0;
}
else
{
format(string, sizeof(string), "PD Dispacher: Nemamo informacija o %s-u, da li ste sigurni da je to tacno ime?",tmp);
SendClientMessage(playerid, COLOR_DBLUE, string);
return 0;
}
}
if(Mobile[playerid] == 912)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem?");
return 0;
}
strmid(PlayerCrime[playerid][pAccusing], text, 0, strlen(text), 255);
SendClientMessage(playerid, COLOR_DBLUE, "PD: Ako znate ime pocinioca napisite ga, ako ne znate napisite 'no'.");
Mobile[playerid] = 913;
return 0;
}
if(Mobile[playerid] == 911)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Ne razumijem, da li trebate 'Policiju' ili 'Hitnu Pomoc'? (kucajte policija ili hitna_pomoc)");
return 0;
}
else if ((strcmp("policija", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("policija")))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Povezujem vas sa Policijom, sacekajte...");
Mobile[playerid] = 912;
SendClientMessage(playerid, COLOR_DBLUE, "PD: Molimo vas dajte nam kratke podatke o zlocinu i lokaciji.");
return 0;
}
else if ((strcmp("hitna_pomoc", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("hitna_pomoc")))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Povezujem vas Sa Hitnom Pomoci.");
Mobile[playerid] = 914;
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Molimo vas dajte nam kratke podatke o incidentu.");
return 0;
}
else
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem, da li trebate 'Policiju' ili 'Hitnu Pomoc'?");
return 0;
}
}
if(Mobile[playerid] == 3900)
{
SendFamilyMessage(9, COLOR_GREEN, "{F3FF02}[INFO] Imate novu poruku:");
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "[ID:%d] %s kaze: %s", playerid, sendername, text);
SendFamilyMessage(9, COLOR_GREEN, string);
SendClientMessage(playerid, COLOR_GREEN, "ABC Studio: Hvala vam na informacijama !");
SendClientMessage(playerid, COLOR_GRAD2, "[INFO] Prekinuli su !");
Mobile[playerid] = 255;
return 0;
}
if(IsPlayerConnected(Mobile[playerid]))
{
    if(Mobile[Mobile[playerid]] == playerid)
    {
if(PlayerInfo[Mobile[playerid]][pSpeaker] == 1)
{
ProxDetector(20.0, Mobile[playerid], string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    SendClientMessage(Mobile[playerid], COLOR_YELLOW,string);
}
}
}
else
{
SendClientMessage(playerid, COLOR_YELLOW,"Nema nikog tamo !");
}
return 0;
}
if (BusShowLocation[playerid][0] == 1)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
SetPlayerCheckpoint(playerid, BusShowLocation[playerid][1], BusShowLocation[playerid][2], BusShowLocation[playerid][3], 3.0);
SendClientMessage(playerid, COLOR_YELLOW, "Lokacija vam je prikazana na mapi, bolje vam je da pozurite!");
BusShowLocation[playerid][0] = 0;
BusShowLocationC[playerid] = 1;
return 0;
}
else
{
BusShowLocation[playerid][0] = 0;
return 0;
}
}
if (realchat)
{
    if(gPlayerLogged[playerid] == 0)
    {
        return 0;
      }
GetPlayerName(playerid, sendername, sizeof(sendername));
if(!IsPlayerInAnyVehicle(playerid))
{
if(PlayerInfo[playerid][pMaskuse] == 1)
{
format(string, sizeof(string), "Stranac kaze: %s", text);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    format(string, sizeof(string), "%s kaze: %s", sendername, text);
    ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
}
else
{
    new carid = GetPlayerVehicleID(playerid);
    new pveh = GetVehicleModel(GetPlayerVehicleID(playerid));
    if(IsABike(carid) || IsAOBike(carid) || IsAPizzabike(carid) || IsAPlane(carid) || IsABoat(carid) || IsAHarvest(carid) || pveh == 523 || pveh == 480 || pveh == 567 || pveh == 533 || pveh == 555 || pveh == 539 || pveh == 572 || pveh == 571 || pveh == 530 || pveh == 457 || pveh == 575 || pveh == 536 || pveh == 424)
    {
        if(PlayerInfo[playerid][pMaskuse] == 1)
{
format(string, sizeof(string), "Stranac kaze: %s", text);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    format(string, sizeof(string), "%s kaze: %s", sendername, text);
    ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
    }
    else
    {
    if(VehicleWindows[GetPlayerVehicleID(playerid)] == 0)
    {
    if(PlayerInfo[playerid][pMaskuse] == 1)
{
format(string, sizeof(string), "(Prozor Zatvoren) Stranac kaze: %s", text);
ProxDetector(10.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    format(string, sizeof(string), "(Prozor Zatvoren) %s kaze: %s", sendername, text);
    ProxDetector(10.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
}
else
{
    if(PlayerInfo[playerid][pMaskuse] == 1)
{
format(string, sizeof(string), "(Prozor Otvoren) Stranac kaze: %s", text);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    format(string, sizeof(string), "(Prozor Otvoren) %s kaze: %s", sendername, text);
    ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
}
}
}
return 0;
}
return 1;
}


Evo, pretpostavljam da ti ono za prozore ne treba

public OnPlayerText(playerid, text[])
{
new sendername[MAX_PLAYER_NAME];
new giveplayer[MAX_PLAYER_NAME];
new tmp[256];
new string[256];
    //new gPlayerUsingLoopingAnim[MAX_PLAYERS];
SetPlayerChatBubble(playerid, text, COLOR_GRAD1, 20.0, 10000); //poruka iznad glave
    //LoopingAnim(playerid,"PED","IDLE_CHAT",4.0,1,0,0,1,1);
if(PlayerInfo[playerid][pMuted] == 1)
{
SendClientMessage(playerid, TEAM_CYAN_COLOR, "{F81414}[FS:RP] {0084e3}Ne mozes pricati, mutiran si!");
return 0;
}
    if(AdvertisementCheck(text) && !IsPlayerAdmin(playerid))
{
    GetPlayerName(playerid, sendername, sizeof(sendername));
format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Ne reklamiraj dobices ban ({F81414}Admini/Gamemasteri {0084e3}su upozoreni o pokusaju reklamiranja)!");
SendClientMessage( playerid, 0xFF4444FF, string);
    format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Igrac %s pokusava da reklamira opomenite ga!", sendername);
SendAdminGmMessage(COLOR_LIGHTRED, string);
return 0;
}
if(anty(text))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Ne reklamiraj dobices ban ({F81414}Admini/Gamemasteri {0084e3}su upozoreni o pokusaju reklamiranja)!");
SendClientMessage( playerid, 0xFF4444FF, string);
    format( string, sizeof( string ), "{F81414}[FS:RP AntiAdvertise] {0084e3}Igrac %s pokusava da reklamira opomenite ga!", sendername);
SendAdminGmMessage(COLOR_LIGHTRED, string);
return 0;
}
if(SelectChar[playerid] == 255)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("next", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("next")))
{
    switch (SelectCharID[playerid])
{
case 20:
{
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, CivMalePeds[1][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = CivMalePeds[1][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, CivMalePeds[2][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = CivMalePeds[2][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, CivMalePeds[3][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = CivMalePeds[3][0]; }
    else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, CivMalePeds[4][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = CivMalePeds[4][0]; }
    else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, CivMalePeds[5][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = CivMalePeds[5][0]; }
    else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, CivMalePeds[6][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = CivMalePeds[6][0]; }
    else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, CivMalePeds[7][0]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = CivMalePeds[7][0]; }
    else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, CivMalePeds[8][0]); SelectCharPlace[playerid] = 9; ChosenSkin[playerid] = CivMalePeds[8][0]; }
}
case 30:
{
    if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, CivFemalePeds[1][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = CivFemalePeds[1][0]; }
    else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, CivFemalePeds[2][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = CivFemalePeds[2][0]; }
    else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, CivFemalePeds[3][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = CivFemalePeds[3][0]; }
    else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, CivFemalePeds[4][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = CivFemalePeds[4][0]; }
    else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, CivFemalePeds[5][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = CivFemalePeds[5][0]; }
    else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, CivFemalePeds[6][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = CivFemalePeds[6][0]; }
}

}
    return 0;
}
else if ((strcmp("done", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("done")))
{
    if(ChangePos2[playerid][1] == 1)
    {
        SetPlayerInterior(playerid, ChangePos2[playerid][0]);
        JBC_SetPlayerPos(playerid, ChangePos[playerid][0],ChangePos[playerid][1],ChangePos[playerid][2]);
        ChangePos2[playerid][1] = 0;
        //return 0;
    }
    MedicBill[playerid] = 0;
    PlayerInfo[playerid][pModel] = ChosenSkin[playerid];
    PlayerInfo[playerid][pChar] = ChosenSkin[playerid];
    SetSpawnInfo(playerid, PlayerInfo[playerid][pTeam], PlayerInfo[playerid][pModel],0.0,0.0,0.0,0,0,0,0,0,0,0);
    gTeam[playerid] = PlayerInfo[playerid][pTeam];
SetPlayerToTeamColor(playerid);
MedicBill[playerid] = 0;
SpawnPlayer(playerid);
MedicBill[playerid] = 0;
    SelectCharPlace[playerid] = 0;
    SelectCharID[playerid] = 0;
    SelectChar[playerid] = 0;
    SetPlayerVirtualWorld(playerid,0);
    SetTimerEx("backtoclothes", 1000, false, "i", playerid);
    MedicBill[playerid] = 0;
BizzInfo[3][bTill] += 100;
ExtortionBiz(3, 100);
            BizzInfo[4][bTill] += 100;
ExtortionBiz(4, 100);
            BizzInfo[16][bTill] += 100;
ExtortionBiz(16, 100);
            BizzInfo[17][bTill] += 100;
ExtortionBiz(17, 100);

return 0;
}
else
{
    SendClientMessage(playerid, COLOR_WHITE, "{F81414}(GRESKA) {FFAF00}Kucaj u chatu ( {F81414}next {FFAF00}) da listas skinove ( {F81414}done {FFAF00}) da kupis skin.");
    return 0;
}
}
if(MarriageCeremoney[playerid] > 0)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
    if(GotProposedBy[playerid] < 999)
    {
    if(IsPlayerConnected(GotProposedBy[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(GotProposedBy[playerid], giveplayer, sizeof(giveplayer));
    format(string, sizeof(string), "Pop: %s da li uzimate %s-u za svoju zenu? (kucajte 'yes', sve ostalo ce se smatrati negativnim odgovorom).", giveplayer,sendername);
SendClientMessage(GotProposedBy[playerid], COLOR_WHITE, string);
MarriageCeremoney[GotProposedBy[playerid]] = 1;
MarriageCeremoney[playerid] = 0;
GotProposedBy[playerid] = 999;
    return 1;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        GotProposedBy[playerid] = 999;
        return 0;
    }
}
else if(ProposedTo[playerid] < 999)
{
    if(IsPlayerConnected(ProposedTo[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(ProposedTo[playerid], giveplayer, sizeof(giveplayer));
if(PlayerInfo[playerid][pSex] == 1 && PlayerInfo[ProposedTo[playerid]][pSex] == 2)
{
format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Zenom, mozete poljubiti Mladu.", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s and %s proglasavam vas...Muzem & Zenom, mozete poljubiti Mladozenju.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Novosti: Imamo novi par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
else if(PlayerInfo[playerid][pSex] == 1 && PlayerInfo[ProposedTo[playerid]][pSex] == 1)
{
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Muzem, mozete poljubiti Mladu :).", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Muzem & Muzem, mozete poljubiti Mladozenju.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Novosti: Imamo novi Gay par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
else if(PlayerInfo[playerid][pSex] == 2 && PlayerInfo[ProposedTo[playerid]][pSex] == 2)
{
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Zenom & Zenom, mozete poljubiti Mladu.", sendername, giveplayer);
SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "Pop: %s i %s proglasavam vas...Zenom & Zenom, mozete poljubiti Mladu.", giveplayer, sendername);
SendClientMessage(ProposedTo[playerid], COLOR_WHITE, string);
format(string, sizeof(string), "Marriage News: Imamo novi Lesbo par, %s & %s su vjencani.", sendername, giveplayer);
OOCNews(COLOR_WHITE, string);
}
MarriageCeremoney[ProposedTo[playerid]] = 0;
MarriageCeremoney[playerid] = 0;
format(string, sizeof(string), "%s", sendername);
strmid(PlayerInfo[ProposedTo[playerid]][pMarriedTo], string, 0, strlen(string), 255);
format(string, sizeof(string), "%s", giveplayer);
strmid(PlayerInfo[playerid][pMarriedTo], string, 0, strlen(string), 255);
SafeJBC_GivePlayerMoney(playerid, - 20000);
PlayerInfo[playerid][pMarried] = 1;
PlayerInfo[ProposedTo[playerid]][pMarried] = 1;
PlayerInfo[ProposedTo[playerid]][pPhousekey] = PlayerInfo[playerid][pPhousekey];
PlayerInfo[ProposedTo[playerid]][pPbiskey] = PlayerInfo[playerid][pPbiskey];
ProposedTo[playerid] = 999;
MarriageCeremoney[playerid] = 0;
    return 1;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        ProposedTo[playerid] = 999;
        return 0;
    }
}
}
else
{
    if(GotProposedBy[playerid] < 999)
    {
if(IsPlayerConnected(GotProposedBy[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(GotProposedBy[playerid], giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "* Niste htjeli da se vjencate sa %s-om, niste rekli 'yes'.",giveplayer);
    SendClientMessage(playerid, COLOR_YELLOW, string);
    format(string, sizeof(string), "* %s nije htio/la da se vjenca sa vama, nije rekao/la 'yes'.",sendername);
    SendClientMessage(GotProposedBy[playerid], COLOR_YELLOW, string);
    return 0;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        GotProposedBy[playerid] = 999;
        return 0;
    }
    }
    else if(ProposedTo[playerid] < 999)
{
    if(IsPlayerConnected(ProposedTo[playerid]))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
GetPlayerName(ProposedTo[playerid], giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "* Niste hjteli da se vjencate sa %s, niste rekli 'yes'.",giveplayer);
    SendClientMessage(playerid, COLOR_YELLOW, string);
    format(string, sizeof(string), "* %s nije htio/la da se vjenca sa vama, nije rekao/la 'yes'.",sendername);
    SendClientMessage(ProposedTo[playerid], COLOR_YELLOW, string);
    return 0;
    }
    else
    {
        MarriageCeremoney[playerid] = 0;
        ProposedTo[playerid] = 999;
        return 0;
    }
}
}
    return 0;
}
if(WritingPaper[playerid] > 0)
{
    new line;
        new nstring[256];
        new idx;
        new length = strlen(text);
while ((idx < length) && (text[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[64];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = text[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
    if(WritingLine[playerid] == 1) { SendClientMessage(playerid, COLOR_GRAD2, "* Molimo vas upisite Naslov vasih novina."); }
    else { SendClientMessage(playerid, COLOR_LIGHTRED, "* Molimo vas kucajte tekst vasih novina."); }
return 0;
}
format(nstring, sizeof(nstring), "%s", text);
switch(WritingLine[playerid])
{
    case 1:
    {
        new fstring[MAX_PLAYER_NAME];
        GetPlayerName(playerid, sendername, sizeof(sendername));
format(fstring, sizeof(fstring), "%s", sendername);
strmid(PaperInfo[WritingPaperNumber[playerid]][PaperMaker], fstring, 0, strlen(fstring), 255);
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperTitle], nstring, 0, strlen(nstring), 255);
        line = 0; WritingLine[playerid] = 2;
        SendClientMessage(playerid, COLOR_LIGHTRED, "* Sada mozete pisati redove u vasim novinama, 7 vam je ostalo.");
    }
    case 2:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText1], nstring, 0, strlen(nstring), 255);
        line = 1; WritingLine[playerid] = 3;
    }
    case 3:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText2], nstring, 0, strlen(nstring), 255);
        line = 2; WritingLine[playerid] = 4;
    }
    case 4:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText3], nstring, 0, strlen(nstring), 255);
        line = 3; WritingLine[playerid] = 5;
    }
    case 5:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText4], nstring, 0, strlen(nstring), 255);
        line = 4; WritingLine[playerid] = 6;
    }
    case 6:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText5], nstring, 0, strlen(nstring), 255);
        line = 5; WritingLine[playerid] = 7;
    }
    case 7:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText6], nstring, 0, strlen(nstring), 255);
        line = 6; WritingLine[playerid] = 8;
    }
    case 8:
    {
        strmid(PaperInfo[WritingPaperNumber[playerid]][PaperText7], nstring, 0, strlen(nstring), 255);
        PaperInfo[WritingPaperNumber[playerid]][PaperUsed] = 1;
        SavePapers();
        line = 7; WritingLine[playerid] = 0; WritingPaper[playerid] = 0; WritingPaperNumber[playerid] = 999;
    }
}
if(line > 0)
{
format(string, sizeof(string), "* Napisali ste %d red/a/ova u vasim novina.", line);
SendClientMessage(playerid, COLOR_WHITE, string);
if(line == 7)
{
    SendClientMessage(playerid, COLOR_WHITE, "* Vase Novine su dodate na listi Novina (za Raznosace Novina).");
}
}
    return 0;
}
if(CallLawyer[playerid] == 111)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string, sizeof(string), "** %s je u zatvoru i treba advokata. Idite u Policijsku Stanicu.", sendername);
    SendJobMessage(2, TEAM_AZTECAS_COLOR, string);
    SendJobMessage(2, TEAM_AZTECAS_COLOR, "* Kada ste u Policijskoj Stanici, pitajte nekog policajca da vam dozvoli oslobadjanje sa /accept lawyer.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Poruka je poslata svim slobodnim advokatima, molimo sacekajte.");
    WantLawyer[playerid] = 0;
CallLawyer[playerid] = 0;
    return 0;
}
else
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "Trenutno nema slobodnih advokata, zatvorska kazna je pocela.");
    WantLawyer[playerid] = 0;
CallLawyer[playerid] = 0;
    return 0;
}
}
if(TalkingLive[playerid] != 255)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9)
{
    format(string, sizeof(string), "{FF00EA}[SE:RT] Novinar %s: {FFFFFF}%s", sendername, text);
OOCNews(COLOR_LIGHTGREEN, string);
}
else
{
    format(string, sizeof(string), "{FF00EA}[SE:RT] Gost %s: {FFFFFF}%s", sendername, text);
OOCNews(COLOR_LIGHTGREEN, string);
}
return 0;
}
if(Mobile[playerid] != 255)
{
new idx;
tmp = strtok(text, idx);
GetPlayerName(playerid, sendername, sizeof(sendername));
           new result[256];
   new brojevi[] = { '1','2','3','4','5','6','7','8','9'};
          for(new b = 0; b < sizeof brojevi; b++)
{
new tekst = strlen(result);
for(new i = 0; i<tekst; i++)
{
if(result[i] == brojevi[b])
result[i] = '*' ;
}
}
if(UnidentifedCall[playerid] == 1)
{
    format(string, sizeof(string), "{F3FF02}Stranac kaze (telefon): %s", text);
}
else
{
format(string, sizeof(string), "{F3FF02}%s kaze (telefon): %s", sendername, text);
}
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
if(Mobile[playerid] == 914)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Izvinite, ne razumijem?");
return 0;
}
new turner[MAX_PLAYER_NAME];
new wanted[128];
GetPlayerName(playerid, turner, sizeof(turner));
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Javili smo svim jedinicama u tom podruciju.");
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Hvala vam sto ste prijavili incident");
format(wanted, sizeof(wanted), "Dispacher: Svim jedinicama, novi incident: Prijavio: %s",turner);
SendTeamBeepMessage(1, TEAM_CYAN_COLOR, wanted);
format(wanted, sizeof(wanted), "Dispacher: Incident: %s",text);
SendTeamMessage(1, TEAM_CYAN_COLOR, wanted);
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
emdtrace = 1; emdtrace_x = trace_x; emdtrace_y = trace_y; emdtrace_z = trace_z;
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if(Mobile[playerid] == 913)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem?");
return 0;
}
if ((strcmp("no", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("no")))
{
new turner[MAX_PLAYER_NAME];
new wanted[128];
GetPlayerName(playerid, turner, sizeof(turner));
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Javili smo svim jedinicama u tom podruciju .");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala vam sto ste prijavili zlocin");
format(wanted, sizeof(wanted), "BAZA: Svim jedinicama, novi zlocin: Prijavio: %s",turner);
SendFamilyMessage(1, COLOR_DBLUE, wanted);
format(wanted, sizeof(wanted), "BAZA: Zlocin: %s, Osumnjiceni: Nepoznat",PlayerCrime[playerid][pAccusing]);
SendFamilyMessage(1, COLOR_DBLUE, wanted);
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
pdtrace = 1; pdtrace_x = trace_x; pdtrace_y = trace_y; pdtrace_z = trace_z;
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
new badguy;
badguy = ReturnUser(tmp);
if (IsPlayerConnected(badguy))
{
    if(badguy != INVALID_PLAYER_ID)
    {
if (gTeam[badguy] == 2 || gTeam[badguy] == 1)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Moracete da prijavite unutrasnjoj kontroli.");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if (WantedPoints[badguy] > 0)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Sve jedinice su vec obavjestene o tom slucaju");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala vam sto ste prijavili taj zlocin");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
if (badguy == playerid)
{
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Nemojte se zezati, ovo je linija za hitne slucajeve.");
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
SendClientMessage(playerid, COLOR_DBLUE, "PD Dispacher: Javili smo svim jedinicama u tom podruciju.");
SendClientMessage(playerid, COLOR_DBLUE, "Hvala sto ste prijavili zlocin");
new Float:trace_x, Float:trace_y, Float:trace_z;
GetPlayerPos(playerid, trace_x, trace_y, trace_z);
pdtrace = 1; pdtrace_x = trace_x; pdtrace_y = trace_y; pdtrace_z = trace_z;
SetPlayerCriminal(badguy,playerid, PlayerCrime[playerid][pAccusing]);
if(WantedPoints[badguy] > 0) { } else { WantedPoints[badguy] += 2; }
SendClientMessage(playerid, COLOR_GRAD2, "   Prekinuli su...");
Mobile[playerid] = 255;
return 0;
}
return 0;
}
else
{
format(string, sizeof(string), "PD Dispacher: Nemamo informacija o %s-u, da li ste sigurni da je to tacno ime?",tmp);
SendClientMessage(playerid, COLOR_DBLUE, string);
return 0;
}
}
if(Mobile[playerid] == 912)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem?");
return 0;
}
strmid(PlayerCrime[playerid][pAccusing], text, 0, strlen(text), 255);
SendClientMessage(playerid, COLOR_DBLUE, "PD: Ako znate ime pocinioca napisite ga, ako ne znate napisite 'no'.");
Mobile[playerid] = 913;
return 0;
}
if(Mobile[playerid] == 911)
{
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Ne razumijem, da li trebate 'Policiju' ili 'Hitnu Pomoc'? (kucajte policija ili hitna_pomoc)");
return 0;
}
else if ((strcmp("policija", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("policija")))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Povezujem vas sa Policijom, sacekajte...");
Mobile[playerid] = 912;
SendClientMessage(playerid, COLOR_DBLUE, "PD: Molimo vas dajte nam kratke podatke o zlocinu i lokaciji.");
return 0;
}
else if ((strcmp("hitna_pomoc", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("hitna_pomoc")))
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Povezujem vas Sa Hitnom Pomoci.");
Mobile[playerid] = 914;
SendClientMessage(playerid, TEAM_CYAN_COLOR, "Dispacher: Molimo vas dajte nam kratke podatke o incidentu.");
return 0;
}
else
{
SendClientMessage(playerid, COLOR_ALLDEPT, "Hitna Sluzba: Izvinite, ne razumijem, da li trebate 'Policiju' ili 'Hitnu Pomoc'?");
return 0;
}
}
if(Mobile[playerid] == 3900)
{
SendFamilyMessage(9, COLOR_GREEN, "{F3FF02}[INFO] Imate novu poruku:");
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "[ID:%d] %s kaze: %s", playerid, sendername, text);
SendFamilyMessage(9, COLOR_GREEN, string);
SendClientMessage(playerid, COLOR_GREEN, "ABC Studio: Hvala vam na informacijama !");
SendClientMessage(playerid, COLOR_GRAD2, "[INFO] Prekinuli su !");
Mobile[playerid] = 255;
return 0;
}
if(IsPlayerConnected(Mobile[playerid]))
{
    if(Mobile[Mobile[playerid]] == playerid)
    {
if(PlayerInfo[Mobile[playerid]][pSpeaker] == 1)
{
ProxDetector(20.0, Mobile[playerid], string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    SendClientMessage(Mobile[playerid], COLOR_YELLOW,string);
}
}
}
else
{
SendClientMessage(playerid, COLOR_YELLOW,"Nema nikog tamo !");
}
return 0;
}
if (BusShowLocation[playerid][0] == 1)
{
    new idx;
    tmp = strtok(text, idx);
    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
{
SetPlayerCheckpoint(playerid, BusShowLocation[playerid][1], BusShowLocation[playerid][2], BusShowLocation[playerid][3], 3.0);
SendClientMessage(playerid, COLOR_YELLOW, "Lokacija vam je prikazana na mapi, bolje vam je da pozurite!");
BusShowLocation[playerid][0] = 0;
BusShowLocationC[playerid] = 1;
return 0;
}
else
{
BusShowLocation[playerid][0] = 0;
return 0;
}
}
if (realchat)
{
    if(gPlayerLogged[playerid] == 0)
    {
        return 0;
      }
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pMaskuse] == 1)
{
format(string, sizeof(string), "Stranac kaze: %s", text);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
else
{
    format(string, sizeof(string), "%s kaze: %s", sendername, text);
    ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
}
return 0;
}
return 1;
}