SA-MP Forums Archive
Textdraws - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Textdraws (/showthread.php?tid=494362)



Textdraws - Ananisiki - 12.02.2014

~~~~~~


Re: Textdraws - Spydah - 12.02.2014

Hmm, do you get any erroers/warnings with compiling?
And make sure you don't use the same name for the Welcome's message textdraw and the Admin cmd textdraw.


Re: Textdraws - Ananisiki - 13.02.2014

~~~~~~


Re: Textdraws - Spydah - 13.02.2014

Hmm, could you provide some codes?


Re: Textdraws - Ananisiki - 13.02.2014

~~~~~~


Re: Textdraws - Spydah - 13.02.2014

Where are the admin textdraws?


Re: Textdraws - [KHK]Khalid - 13.02.2014

I can't get you. You destroy all the 'intro' textdraws inside the function 'IntroTextDestroy' which is called 10 seconds after a player connects [?]. So, this is what happens: you join, 10 seconds pass and the 'intro' textdraws are DESTROYED, and this is why you don't find them when you reconnect because they are no longer present.

Solution:

I suppose you wanna hide the textdraws after 10 seconds and NOT destroy them. So, your 'IntroTextDestroy' code should be:

Код:
public IntroTextDestroy(playerid)
{
	TextDrawHideForPlayer(playerid, introTitle);
	TextDrawHideForPlayer(playerid, introRules);
	TextDrawHideForPlayer(playerid, introRules1);
	TextDrawHideForPlayer(playerid, introRules2);
	TextDrawHideForPlayer(playerid, introRules3);
	TextDrawHideForPlayer(playerid, introRules4);
	TextDrawHideForPlayer(playerid, introRules5);
	TextDrawHideForPlayer(playerid, introRules6);
	TextDrawHideForPlayer(playerid, introRules7);
	TextDrawHideForPlayer(playerid, introRules8);
	TextDrawHideForPlayer(playerid, introRules9);
	TextDrawHideForPlayer(playerid, introRules10);
	TextDrawHideForPlayer(playerid, introRules11);
	TextDrawHideForPlayer(playerid, introRules12);
	return 1;
}



Re: Textdraws - Ananisiki - 13.02.2014

~~~~~~


Re: Textdraws - Ananisiki - 13.02.2014

Also need help with another thing please,

I can type all the cmds with textdraws without getting the current one closed, is there a solution for this?

If there is a textdraw up, it'll be closed before the new one appears, hope you understand


Re: Textdraws - $Marco$ - 13.02.2014

Yea i got you, just hide the previous Textdraw for example:

pawn Код:
CMD:test(playerid)
{
     TextDrawHideForPlayer(playerid, Textdrawname);
     TextDrawShowForPlayer(playerid, OtherTextDraw);
     return 1;
     
}

OR
If you want to make a simple system to close all of it at once without rewritting it all again just:

pawn Код:
forawrd RemoveAllTextdraws(playerid);
stock RemoveAllTextdraws(playerid)
{
     TextDrawHideForPlayer(playerid, Textdrawname);
     TextDrawHideForPlayer(playerid, Textdrawname);
     TextDrawHideForPlayer(playerid, Textdrawname);
     TextDrawHideForPlayer(playerid, Textdrawname);
     return 1;
}

CMD:test(playerid)
{
     RemoveAllTextdraws(playerid);
     TextDrawShowForPlayer(playerid, Textdrawname); // The new one.
     return 1;
}