[pomoc] Oglas(/ad)

Započeo Respect the Rules, Maj 13, 2012, 20:22:43 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 3 gostiju pregledaju ovu temu.

Respect the Rules

Skripta koju koristim: CLRP Edit
Detaljan opis problema: Ovako ja sam napravio log za oglase i sve je u redu i sprema oglase ali kad ja u igri dam oglas(/ad) ono mi ispise oglas kao sto treba biti u logu
Dio skripte:
if(strcmp(cmd, "/advertise", true) == 0 || strcmp(cmd, "/ad", true) == 0)
{
    if(IsPlayerConnected(playerid))
    {
        if(gPlayerLogged[playerid] == 0)
        {
            SendClientMessage(playerid, WHITE, "|"COL_RED"AntiBot{FFFFFF}| Niste se prijavili!");
            return 1;
        }
        if(PlayerInfo[playerid][pLevel] < 3)
        {
            SendClientMessage(playerid, WHITE, "|"COL_RED"AntiBot|{FFFFFF}| Morate biti level "COL_RED"3 {FFFFFF}da bih ste dali oglas.");
            return 1;
        }
GetPlayerName(playerid, sendername, sizeof(sendername));
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[128];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_GRAD2, "Koriscenje: (/ad)vertise [advert text]");
return 1;
}
if ((!adds) && (PlayerInfo[playerid][pAdmin] < 1))
{
format(string, sizeof(string), "Molimo pokusajte jer treba da prodje %d sekundi izmedju reklama!",  (addtimer/1000));
SendClientMessage(playerid, COLOR_GRAD2, string);
return 1;

}
new payout = idx * 1;
if(GetPlayerMoney(playerid) < payout)
        {
            format(string, sizeof(string), "* Vi ste iskoristili %d slova sto kosta $%d, nemate dovoljno novca.", offset, payout);
            SendClientMessage(playerid, COLOR_WHITE, string);
            return 1;
        }
GivePlayerCash(playerid, - payout);
SBizzInfo[7][sbTill] += payout;
ExtortionSBiz(7, payout);
format(string, sizeof(string), "{48E31C}Oglasavanje | Kontakt: {FFFFFF}%s | {48E31C}Broj: {FFFFFF}%d.",sendername,PlayerInfo[playerid][pPnumber]);
OOCNews(TEAM_GROVE_COLOR,string);
format(string, sizeof(string), "- %s.",  result);
format(string, sizeof(string), "Igrac %s postavio oglas: %s", sendername,result);//Evo tu je log za /ad ali mi ipsiuje ovako npr. Oglasavanje|Kontak:Medis_Burn|Broj:12345
Igrac Medis Burn je postavio oglas: Test
AdLog(string);
OOCNews(COLOR_WHITE,string);
format(string, sizeof(string), "~r~Racun $%d~n~~w~Poruka je sadrzala: %d Slova", payout, idx);
GameTextForPlayer(playerid, string, 5000, 1);
if (PlayerInfo[playerid][pAdmin] < 1){SetTimer("AddsOn", addtimer, 0);adds = 0;}
}
return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno):