I've made one:
pawn Код:
Textdraw0 = TextDrawCreate(494.000000, 128.000000, "Error:");
TextDrawBackgroundColor(Textdraw0, 255);
TextDrawFont(Textdraw0, 1);
TextDrawLetterSize(Textdraw0, 0.500000, 1.000000);
TextDrawColor(Textdraw0, -1);
TextDrawSetOutline(Textdraw0, 0);
TextDrawSetProportional(Textdraw0, 1);
TextDrawSetShadow(Textdraw0, 1);
TextDrawUseBox(Textdraw0, 1);
TextDrawBoxColor(Textdraw0, 255);
TextDrawTextSize(Textdraw0, 620.000000, -40.000000);
Textdraw1 = TextDrawCreate(494.000000, 140.000000, "string");
TextDrawBackgroundColor(Textdraw1, 255);
TextDrawFont(Textdraw1, 1);
TextDrawLetterSize(Textdraw1, 0.300000, 1.000000);
TextDrawColor(Textdraw1, -1);
TextDrawSetOutline(Textdraw1, 0);
TextDrawSetProportional(Textdraw1, 1);
TextDrawSetShadow(Textdraw1, 1);
TextDrawUseBox(Textdraw1, 1);
TextDrawBoxColor(Textdraw1, -871318750);
TextDrawTextSize(Textdraw1, 620.000000, 170.000000);
Stock&Timer:
pawn Код:
forward MessageBoxTimer(playerid);
public MessageBoxTimer(playerid)
{
TextDrawHideForPlayer(playerid, Text:Textdraw0);
TextDrawHideForPlayer(playerid, Text:Textdraw1);
return 1;
}
stock MessageBox(playerid, title[], message[], time)
{
TextDrawSetString(Textdraw0, title);
TextDrawSetString(Textdraw1, message);
TextDrawShowForPlayer(playerid, Text:Textdraw0);
TextDrawShowForPlayer(playerid, Text:Textdraw1);
SetTimer("MessageBoxTimer", time, 0);
return 1;
}
pawn Код:
CMD:test(playerid, params[])
{
MessageBox(playerid, "Test", "Testing", 5000);
return 1;
}
But the textdraws aren't showing and nothing is happening(no console errors or message IG)