Quote:
Originally Posted by KinderClans
Create the textdraw ingame and export is as player textdraw.
Then:
pawn Code:
stock MessageHelpBox(playerid, string[], time = 5000) { PlayerTextDrawSetString(playerid, MessageTxd[playerid], string); PlayerTextDrawShow(playerid, MessageTxd[playerid]); SetTimerEx("HideMessageBox", time, false, "d", playerid); return 1; }
forward HideMessageBox(playerid) public HideMessageBox(playerid) { PlayerTextDrawHide(playerid, MessageTxd[playerid]); }
To show it:
pawn Code:
MessageHelpBox(playerid, "Test! You can add ~r~colors ~b~too", 5000);
If you want to paste a string:
pawn Code:
new string[10]; format(string, sizeof(string), "~b~Test string %d", something); MessageHelpBox(playerid, string, 5000);
|
Why are you using stock there?