Text Drawer not opening -
ajmac22 - 16.12.2012
pawn Код:
public OnPlayerSpawn(playerid)
{
Textdraw0[playerid] = CreatePlayerTextDraw(playerid, 152.628448, 100.693260, "WELCOME TO MY TEST SERVER");
PlayerTextDrawLetterSize(playerid, Textdraw0[playerid], 0.500398, 3.322310);
PlayerTextDrawAlignment(playerid, Textdraw0[playerid], 2);
PlayerTextDrawColor(playerid, Textdraw0[playerid], -2147483393);
PlayerTextDrawSetShadow(playerid, Textdraw0[playerid], 0);
PlayerTextDrawSetOutline(playerid, Textdraw0[playerid], 1);
PlayerTextDrawBackgroundColor(playerid, Textdraw0[playerid], 51);
PlayerTextDrawFont(playerid, Textdraw0[playerid], 3);
PlayerTextDrawSetProportional(playerid, Textdraw0[playerid], 1);
//spawnmessages
SendClientMessage(playerid, COLOR_GREEN, "Welcome to my Server");
SendClientMessage(playerid, COLOR_RED, "Here are my scripts and maps for testing.");
SendClientMessage(playerid, COLOR_ORANGE, "This is only a test server");
SendClientMessage(playerid, COLOR_WHITE, "/info for a list of commands");
SetPlayerInterior(playerid, 0);
return 1;
}
it compiles but I cant see it?
Re: Text Drawer not opening -
Mike_Peterson - 16.12.2012
add PlayerTextDrawShow(playerid, Textdraw0[playerid]);
under PlayerTextDrawSetProportional
Re: Text Drawer not opening -
[DOG]irinel1996 - 16.12.2012
Also, as I see you create a TextDraw everytime the player spawns.
Create it in OnGameModeInit and show it to players in OnPlayerSpawn, or OnPlayerConnect, then hide it.
The script you're using isn't good for optimization.
Re: Text Drawer not opening -
ajmac22 - 16.12.2012
Can you explain to me how to do that?
Re: Text Drawer not opening -
[DOG]irinel1996 - 16.12.2012
If TextDraw's text will be always the same, do this:
pawn Код:
public OnPlayerConnect(playerid) {
Textdraw0[playerid] = CreatePlayerTextDraw(playerid, 152.628448, 100.693260, "WELCOME TO MY TEST SERVER");
PlayerTextDrawLetterSize(playerid, Textdraw0[playerid], 0.500398, 3.322310);
PlayerTextDrawAlignment(playerid, Textdraw0[playerid], 2);
PlayerTextDrawColor(playerid, Textdraw0[playerid], -2147483393);
PlayerTextDrawSetShadow(playerid, Textdraw0[playerid], 0);
PlayerTextDrawSetOutline(playerid, Textdraw0[playerid], 1);
PlayerTextDrawBackgroundColor(playerid, Textdraw0[playerid], 51);
PlayerTextDrawFont(playerid, Textdraw0[playerid], 3);
PlayerTextDrawSetProportional(playerid, Textdraw0[playerid], 1);
PlayerTextDrawShow(playerid, TextDraw0[playerid]);
return 1;
}
public OnPlayerSpawn(playerid) {
PlayerTextDrawHide(playerid, TextDraw0[playerid]);
return 1;
}
Re: Text Drawer not opening -
ajmac22 - 16.12.2012
so I cant do other text draws if I do this?
edit
I tried this is doesnt work, I used a editor to make this, I can make this textdraw show up but idk how to make it hide?