Simple Txtdraw don t work, Hel.....pe me please :D! -
Sharks - 22.02.2010
public Website()
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
//TextDrawDestroy(Site[i]);
Site[i] = TextDrawCreate(120.000,425.000,"
http://blablabla.com");
TextDrawColor(Site[i],COLOR_WHITE);
TextDrawLetterSize(Site[i], 0.5, 1.5);
TextDrawFont(Site[i], 3);
TextDrawBackgroundColor(Site[i], 0x000000AA);
TextDrawSetOutline(Site[i], 2);
TextDrawShowForPlayer(i, Site[i]);
}
return true;
}
//Ongamemodeinit
SetTimer("Website", 1000, true);
The txtdraw dont show...
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Fedee! - 22.02.2010
The problem is... ?
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Rzzr - 22.02.2010
What's the purpose of replacing a textdraw with exactly the same textdraw every minute?
Just use this:
pawn Код:
//Under Ongamemodeinit:
Site = TextDrawCreate(120.000,425.000,"[url]http://blablabla.com"[/url]);
TextDrawColor(Site,COLOR_WHITE);
TextDrawLetterSize(Site, 0.5, 1.5);
TextDrawFont(Site, 3);
TextDrawBackgroundColor(Site, 0x000000AA);
TextDrawSetOutline(Site, 2);
//Under OnPlayerConnect
TextDrawShowForPlayer(playerid, Site);
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Sharks - 22.02.2010
The textdraw shows, but it desapears super fast.There is no more TextDrawHide or Destroy.
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
GhoulSlayeR - 22.02.2010
Get rid of the timer, that method of showing a textdraw is not needed for this situation.
Create the textdraw via OnGameModeInit:
Код:
Site = TextDrawCreate(120.000,425.000,"http://blablabla.com");
TextDrawColor(Site,COLOR_WHITE);
TextDrawLetterSize(Site, 0.5, 1.5);
TextDrawFont(Site, 3);
TextDrawBackgroundColor(Site, 0x000000AA);
TextDrawSetOutline(Site, 2);
Then show the textdraw to the player that connects to the server.
Код:
public OnPlayerConnect(playerid)
{
TextDrawShowForPlayer(playerid, Site);
}
Then hide the textdraw to the player that disconnects the server.
Код:
public OnPlayerDisconnect(playerid, reason)
{
TextDrawHideForPlayer(playerid, Site);
}
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Sharks - 22.02.2010
Textdraw shows when i connect, then it desapears ;(
/imageshack/i/txtd1.jpg/
/imageshack/i/txtdraw2.jpg/
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Sharks - 22.02.2010
I need a help in here. All txtdraws that I try to add, they desapear after creating.
Ideas why this is happening?
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Jeffry - 22.02.2010
Maybe you have any filterscript that destroys it? Or a timer.
Or its just a bad bug.
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Rzzr - 22.02.2010
Quote:
Originally Posted by Sharks
I need a help in here. All txtdraws that I try to add, they desapear after creating.
Ideas why this is happening?
|
Did you delete your timer?
Re: Simple Txtdraw don t work, Hel.....pe me please :D! -
Sharks - 22.02.2010
yes, there is now timer now.