[Ajuda]/an
#1

aki meu /an ele repete toda hora eu queria que quando o player da /an esperara 3 minutosp ra dar o outro /an

PHP код:
if(strcmp(cmd"/anuncio"true) == || strcmp(cmd"/an"true) == 0)
    {
        if(
IsPlayerConnected(playerid))
        {
            if(
gPlayerLogged[playerid] == 0)
            {
                
SendClientMessage(playeridCOLOR_GREY"   Vocк Nгo Estб Logado !");
                return 
1;
            }
            
GetPlayerName(playeridsendernamesizeof(sendername));
            new 
length strlen(cmdtext);
            while ((
idx length) && (cmdtext[idx] <= ' '))
            {
                
idx++;
            }
            new 
offset idx;
            new 
result[64];
            while ((
idx length) && ((idx offset) < (sizeof(result) - 1)))
            {
                
result[idx offset] = cmdtext[idx];
                
idx++;
            }
            
result[idx offset] = EOS;
            if(!
strlen(result))
            {
                
SendClientMessage(playeridCOLOR_GRAD2"USAGE: (/an)uncio [Texto]");
                return 
1;
            }
            if(
PlayerInfo[playerid][pLevel] < 3)
            {
                
SendClientMessage(playeridCOLOR_GRAD1"Vocк precisa ser nнvel 3 ou mais para anunciar");
                return 
1;
            }
            if((!
adds) && (PlayerInfo[playerid][pAdmin] < 1))
            {
                
format(stringsizeof(string), "   Por favor, Tente apуs %d segundos para o proximo anъncio !",  (addtimer/1000));
                
SendClientMessage(playeridCOLOR_GRAD2string);
                return 
1;
            }
            new 
payout idx 2;
            if(
GetPlayerGP(playerid) < payout)
            {
                
format(stringsizeof(string), "Vocк usou %d characteres e custou $%d, Vocк nгo tem Esse Dinheiro."offsetpayout);
                
SendClientMessage(playeridCOLOR_LIGHTBLUEstring);
                return 
1;
            }
            
GivePlayerGP(playerid, - payout);
            
SBizzInfo[7][sbTill] += payout;
            
ExtortionSBiz(7payout);
            for(new 
luplay=0;luplay<6;luplay++){
            if(
strfind(resultIP[luplay], true) != -1){result "PКGO EM FRБGRANTE!!!Jogador tentando divulgar algum IP.";}}
            
format(stringsizeof(string), "Anъncio: %s, Contato: %s Tel: %d",  resultsendername,PlayerInfo[playerid][pPnumber]);
            
OOCNews(TEAM_GROVE_COLOR,string);
            
format(stringsizeof(string), "~r~Pagou $%d~n~~w~Mensagem Contem: %d Characteres"payoutidx);
            
GameTextForPlayer(playeridstring50005);
            
SetTimer("AddsOn"addtimer0);adds 0;
        }
        return 
1;
    } 
Reply
#2

creio ke usa settime ou settimeex mais acho ki й settimeex
Reply
#3

Quote:
Originally Posted by histire
Посмотреть сообщение
creio ke usa settime ou settimeex mais acho ki й settimeex
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
ACHA MAS NAO ACHA?
Reply
#4

Sу pelo code vocк usa o BSL...

#TOPIC

Use um settimer!
Reply
#5

Se vc quer o player que mandou o anuncio demore 3 minutos para outro use SetTimeEx
agora se vc quer que o todos do server so mandem anuncio de 3 em 3 minutos use SetTimer
Reply
#6

mas o que eu mudo ai ?
Reply
#7

Tente gettime()
pawn Код:
SetPVarInt(playerid, "timer", gettime()+tempo_que_vocк_quer);
SetPVarInt(playerid, "timeron", true);

if ( GetPVarInt(playerid, "timer") < gettime() && GetPVarInt(playerid, "timeron") == true)
Reply
#8

qual motivos da risada? ja ki й tao esperto nao pesa ajuda eu falei ki acho ki й settime ou settimeex mais ja ki й tao esperto nao comento mais (Y
Reply
#9

vlw ai mas eu mudei aperceu erros no ricop522
Reply
#10

Quote:
Originally Posted by histire
Посмотреть сообщение
qual motivos da risada? ja ki й tao esperto nao pesa ajuda eu falei ki acho ki й settime ou settimeex mais ja ki й tao esperto nao comento mais (Y
Nгo serб que й por causa do seu portuguкs.
@Topic
Use SetTimer.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)