30.05.2013, 17:06
Why bother using sscanf() and format() ?
Why bother hiding/showing the TD?
Why bother using return's that do nothing ?
Why bother hiding/showing the TD?
Why bother using return's that do nothing ?
pawn Код:
new Text:ann;
forward HideAnn();
public OnGameModeInit()
{
ann = TextDrawCreate(320.000000, 240.000000, "_");
TextDrawAlignment(ann, 2);
TextDrawBackgroundColor(ann, 255);
TextDrawFont(ann, 3);
TextDrawLetterSize(ann, 1.0, 1.400003);
TextDrawColor(ann, -1);
TextDrawSetOutline(ann, 1);
TextDrawSetProportional(ann, 1);
}
public OnPlayerConnect(playerid)
{
TextDrawShowForPlayer(ann, playerid);
}
CMD:announce(playerid, params[])
{
if(isnull(params)) SendClientMessage(playerid, -1, "/announce [message]");
else
{
TextDrawSetString(ann, params);
SetTimer("HideAnn", 10000, false);
}
return 1;
}
public HideAnn()
{
TextDrawSetString(ann, "_");
}