SA-MP Forums Archive
[Ajuda] Progress bar - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Progress bar (/showthread.php?tid=579266)



Progress bar - KevinStyle - 25.06.2015

me ajudem!! a progress bar na minha gamemode nгo aparece, e nгo й codigo errado estou usando um FS e em outra gm funciona normalmente e na minha n funciona e o mais estranho й que algum tempo atraz funcionava, vocкs tem ideia do q pode estar conflitando e nгo pode estar fazendo ela aparecer?


Re: Progress bar - D3sconn3ct - 25.06.2015

Poste o cуdigo que amostra as progress.


Re: Progress bar - KevinStyle - 25.06.2015

new Bar:CarregamentoBar[MAX_PLAYERS] = {INVALID_BAR_ID, ...};

CallBack:: ProgressBar()
{
for(new playerid; playerid < MAX_PLAYERS; playerid++) //I recommend foreach(Player, playerid)
{
if(CarregamentoBar[playerid] != INVALID_BAR_ID)
{
if(mostrandobarra[playerid] == 1)
{
SetProgressBarValue(CarregamentoBar[playerid], Carregamento[playerid]);
UpdateProgressBar(CarregamentoBar[playerid], playerid);
}
}
}

CallBack:: MostrarBarra (playerid)
{
CarregamentoBar[playerid] = CreateProgressBar(275.0, 365.0, 106.50, 10.0, 0x0080FFFF, 20.0);
ShowProgressBarForPlayer(playerid, CarregamentoBar[playerid]);
}

e quando carrega o caminhao ativa o
mostrandobarra[playerid] = 1;

O estranho й que estava funcionando mas eu nem mexi nela e parou de funfar...


Re: Progress bar - iTakelot - 25.06.2015

Poem em CODE para melhor visualizar