TextDraw Bank
#1

Hi everyone. I want to create a state bank In TextDraw like in Ravens. But i have a problem. When I spawn mu TD is 0$ but I have on bank 2000$....

I tried this:

Код:
new Text:Textdraw51[MAX_PLAYERS];
OnGameModeInit:
Код:
for(new i=0; i<MAX_PLAYERS; i++){
    Textdraw51[i] = TextDrawCreate(608.000000, 98.000000, " "); // bank money
	TextDrawAlignment(Textdraw51[i], 3);
	TextDrawBackgroundColor(Textdraw51[i], 255);
	TextDrawFont(Textdraw51[i], 3);
	TextDrawLetterSize(Textdraw51[i], 0.650000, 2.199999);
	TextDrawColor(Textdraw51[i], 43775);
	TextDrawSetOutline(Textdraw51[i], 1);
	TextDrawSetProportional(Textdraw51[i], 1);}
OnPlayerConnect:
Код:
new Banka[256];
    for(new i=0; i<MAX_PLAYERS; i++){
    format(Banka, sizeof(Banka),"$%d",PlayerInfo[i][pAccount]);
    TextDrawSetString(Textdraw51[i], Banka);
    TextDrawShowForPlayer(playerid,Textdraw51[i]);}
OnPlayerDisconnect:
Код:
for(new i=0; i<MAX_PLAYERS; i++){
    TextDrawHideForPlayer(playerid, Textdraw51[i]);}
I hope you understand me

Sry for my bad English
Reply
#2

Are you using the correct variable? PlayerInfo[i][pAccount]?
Reply
#3

Tnx
Reply
#4

try putting it on onplayerupdate maybe?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)