Need example regarding progress bar
#7

To create progress bars in-game, this is the filterscript: http://pastebin.com/P6iPFp9F

CreateProgressBar(x, y, width, height, color, max); - max should be something like 100. (create it in OnPlayerConnect for specific IDs.

ShowProgressBarForPlayer(playerid, barid); - Only use this in OnPlayerConnect, then set a timer to the player's id for like every 50 milliseconds to a callback that will SetProgressbarValue(barid, GetProgressBarValue(barid)+1); then if(GetProgressBarValue(barid) > 99) - destroys the progress bar

SetProgressBarValue(barid, value); - used to set the value 1 higher

GetProgressBarValue(barid); - used to get the value to set it 1 higher

UpdateProgressBar(barid, playerid=INVALID_PLAYER_ID); - use the playerid part for it to update to the player.
Reply


Messages In This Thread
Need example regarding progress bar - by Equuuuin0X - 06.04.2014, 11:39
Re: Need example regarding progress bar - by Pottus - 06.04.2014, 12:23
Re: Need example regarding progress bar - by Equuuuin0X - 06.04.2014, 14:19
Re: Need example regarding progress bar - by iZN - 06.04.2014, 14:58
Re: Need example regarding progress bar - by Equuuuin0X - 06.04.2014, 15:12
Re: Need example regarding progress bar - by Pottus - 06.04.2014, 15:31
Re: Need example regarding progress bar - by Dubya - 06.04.2014, 15:34
Re: Need example regarding progress bar - by Equuuuin0X - 06.04.2014, 16:07
Re: Need example regarding progress bar - by Coffeely - 07.04.2014, 11:24

Forum Jump:


Users browsing this thread: 2 Guest(s)