TextDraw - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: TextDraw (
/showthread.php?tid=309215)
TextDraw -
marrcko - 06.01.2012
Hi there, i have one problem, can't make textdraw to show up
this is on GameModeInit:
pawn Код:
new Text:OrdersL[MAX_PLAYERS]; //this one is global, but im adding it for u just in case.....
for(new i = 0; i< MAX_PLAYERS; i++)
{
OrdersL[i] = TextDrawCreate(350.000000,384.000000," ");
TextDrawFont(OrdersL[i],2);
TextDrawAlignment(OrdersL[i],0);
TextDrawLetterSize(OrdersL[i],0.5,0.5);
TextDrawBackgroundColor(OrdersL[i],0x000000ff);
TextDrawColor(OrdersL[i],ZALSVA);
TextDrawSetOutline(OrdersL[i],1);
TextDrawSetProportional(OrdersL[i],1);
TextDrawSetShadow(OrdersL[i],1);
}
On playerconnect:
pawn Код:
TextDrawHideForPlayer(playerid, OrdersL[playerid]);
part of code(allmost all of it)
pawn Код:
if(Orders[playerid] > 0)
{
new point = random(sizeof(order)),s[20];
SetPlayerCheckpoint(playerid,order[point][0],order[point][1],order[point][2],2.0);
SendClientMessage(playerid,ZALSVA,"[Praneљimų gaviklis]: Pristatyk uћsakymą!");
TextDrawShowForPlayer(playerid, OrdersL[playerid]);
format(s, sizeof(s),"Pristatyta: %d/20",OrdersMade[playerid]);
TextDrawSetString(OrdersL[playerid],s);
}
else
{
SendClientMessage(playerid,VIOLETINE,"[Praneљimų gaviklis]: Nebeturi uћsakymų!");
SendClientMessage(playerid,VIOLETINE,"[Praneљimų gaviklis]: Grįљk į kavinę ir pasiimk dar naujų uћsakymų!");
SetPlayerCheckpoint(playerid,-2346.5813,1020.9704,50.5624,2.0);
}
P.S. my other texdraws, which made myself, work fine....
Re: TextDraw -
Psymetrix - 06.01.2012
TextDraw
ShowForPlayer(playerid, OrdersL[playerid]); ?
Re: TextDraw -
marrcko - 06.01.2012
its already there....
Re: TextDraw -
Psymetrix - 06.01.2012
You said you used TextDrawHideForPlayer when they connect, it should be TextDrawShowForPlayer.
Other than that, I can't see a problem.
Re: TextDraw -
Mrki_Drakula - 07.01.2012
TextDrawSetString needs to be before TextDrawShowForPlayer,
Under OnPlayerConnect needs to be TextDrawShowForPlayer.