10.03.2012, 03:51
this is possible:
First of all You must have a varible for player balance.... Let me show you
Now On Command in which you are showing player dialog you have to use format like this:
See this for more about format:https://sampwiki.blast.hk/wiki/Format
Enjoy it.... Hope it helps you.
First of all You must have a varible for player balance.... Let me show you
pawn Код:
new pbalance[MAX_PLAYERS];//this is my var for player balance use your var in which you are saving player balance or what ever it is
See this for more about format:https://sampwiki.blast.hk/wiki/Format
pawn Код:
new msg[64];//we will format it for our message + varaible in message
format(msg,sizeof(msg),"Your balance is : %d",pbalance[playerid]);// %d uses for integar variable and this will use value of pbalance[playerid] , just your varaible for balance here in place of pbalance[playerid]
//now time for dialog
ShowPlayerDialog(playerid,1,DIALOG_STYLE_MSGBOX,"Bank Balnce",msg,"Okay","Close");// here msg is format we define above