SA-MP Forums Archive
GameTextForPlayer Not showing - 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: GameTextForPlayer Not showing (/showthread.php?tid=481142)



GameTextForPlayer Not showing - skydux123 - 14.12.2013

Hello everybody. I have one little problem I created Jail system with time, then player go to the jail the server should show the gametext who show the time, but it's don't show. I don't know why, can you help me?
Code:
Код HTML:
		if( JAILLAIKAS[ playerid ] > 0 )
		{
		    new str[24], jmin = JAILLAIKAS[ playerid ]/60, jh = jmin /60;
		    JAILLAIKAS[ playerid ] --;
	    	format(str, 30, "Liko sedeti: ~r~%d ~w~val. ~r~%d ~w~min. ~r~%d ~w~sek.",jh,jmin, JAILLAIKAS[ playerid ]);
	    	GameTextForPlayer(playerid, str, 1000, 5);
	    	if( JAILLAIKAS[ playerid ] <=0 )
	    	{

				SetPlayerPos( playerid,631.0467,-571.9198,16.3359);
				SetPlayerInterior( playerid, 0 );
				SetPlayerVirtualWorld( playerid, 0 );
	    	    GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~y~PALEISTAS IS KALEJIMO", 5000, 5);
	    	}
		}
All this are in the timer.
Sorry for my bad english


Re: GameTextForPlayer Not showing - Harris11 - 14.12.2013

if( JAILLAIKAS[ playerid ] > 0 )
{
new str[24], jmin = JAILLAIKAS[ playerid ]/60, jh = jmin /60;
JAILLAIKAS[ playerid ] --;
format(str, 30, "Liko sedeti: ~r~%d ~w~val. ~r~%d ~w~min. ~r~%d ~w~sek.",jh,jmin, JAILLAIKAS[ playerid ]);
GameTextForPlayer(playerid, str, 1000, 5);
if( JAILLAIKAS[ playerid ] <=0 )
{

SetPlayerPos( playerid,631.0467,-571.9198,16.3359);
SetPlayerInterior( playerid, 0 );
SetPlayerVirtualWorld( playerid, 0 );
GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~y~PALEISTAS IS KALEJIMO", 5000, 5);
}
return 1;
}