21.10.2014, 13:08
pawn Код:
CMD:changefont(playerid,params[])
{
new fontid;
if(sscanf(params,"i",fontid)) return SendClientMessage(playerid,COLOR_RED,"<!>Type /changefont [fontid]");
if(fontid >= 5) return SendClientMessage(playerid,COLOR_RED,"<!>Invalid font");
TextDrawFont(MYTEXTDRAW, fontid);
TextDrawHideForPlayer(playerid,MYTEXTDRAW);
TextDrawShowForPlayer(playerid,MYTEXTDRAW);
return true;
}
Altho dont forget that 4 is for sprites
and fontid 5 is for preview model.
If you want to change text you use 1,2,3
pawn Код:
TextDrawSetFont(MYTXT,1-2-3);
pawn Код:
TextDrawSetFont(MYTXT,1);