if(pickupid == arrowpickup[1])
{
new Text:Arrowpickup;
Arrowpickup = TextDrawCreate(310,200, "San Fierro Prison Vehicle entrance");
TextDrawAlignment(Arrowpickup, 2);
TextDrawFont(Arrowpickup, 3);
TextDrawSetOutline(Arrowpickup, 1);
TextDrawSetShadow(Arrowpickup, -1);
TextDrawColor(Arrowpickup,0x0066CCCC);
TextDrawLetterSize(Arrowpickup, 0.8, 1.5);
TextDrawShowForPlayer(playerid, Arrowpickup);
new Text:Arrowpickup2;
Arrowpickup2 = TextDrawCreate(310, 225, "/enter");
TextDrawAlignment(Arrowpickup2, 2);
TextDrawFont(Arrowpickup2, 3);
TextDrawSetOutline(Arrowpickup2, 1);
TextDrawSetShadow(Arrowpickup2, -1);
TextDrawLetterSize(Arrowpickup2, 0.8, 1.5);
TextDrawShowForPlayer(playerid, Arrowpickup2);
// Remove Textdraws
SetTimer("RemoveTextDraw", 2000, false);
}
//use SetTimerEx to pass the td id!
SetTimerEx("RemoveTextDraw", 2000, false "i",Arrowpickup); //set for each TD
SetTimerEx("RemoveTextDraw", 2000, false "i",Arrowpickup2); //set for each TD
// and heres the public to call.
forward RemoveTextDraw(Text:tid);
public RemoveTextDraw(Text:tid)
{
TextDrawDestroy(tid);
}
SetTimerEx("RemoveTextDraw", 2000, false, "i",Arrowpickup); //set for each TD
SetTimerEx("RemoveTextDraw", 2000, false, "i",Arrowpickup2); //set for each TD
C:\Users\Ben\Desktop\SF-RP\gamemodes\bensamp.pwn(569) : warning 213: tag mismatch
C:\Users\Ben\Desktop\SF-RP\gamemodes\bensamp.pwn(570) : warning 213: tag mismatch
SetTimerEx("RemoveTextDraw", 2000, false, "i",_:Arrowpickup); //set for each TD
SetTimerEx("RemoveTextDraw", 2000, false, "i",_:Arrowpickup2); //set for each TD
try it this way
pawn Код:
|