Textdraw appears only once.
#1

PHP код:
#include <a_samp>
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
    print(
"\n--------------------------------------");
    print(
" Blank Filterscript by your name here");
    print(
"--------------------------------------\n");
    return 
1;
}
public 
OnFilterScriptExit()
{
    return 
1;
}
#else
new Text:Textdraw0;
new 
Text:Textdraw1;
forward paycheck(playerid);
forward paycheckshow(playerid);
main()
{
    print(
"\n----------------------------------");
    print(
" Blank Gamemode by your name here");
    print(
"----------------------------------\n");
}
#endif
public OnGameModeInit()
{
    
// Don't use these lines if it's a filterscript
    
SetGameModeText("Blank Script");
    
AddPlayerClass(01958.37831343.157215.3746269.1425000000);
    
Textdraw0 TextDrawCreate(493.000000302.000000"PayCheck");
    
TextDrawBackgroundColor(Textdraw0255);
    
TextDrawFont(Textdraw03);
    
TextDrawLetterSize(Textdraw00.8299993.799999);
    
TextDrawColor(Textdraw016711935);
    
TextDrawSetOutline(Textdraw00);
    
TextDrawSetProportional(Textdraw01);
    
TextDrawSetShadow(Textdraw04);
    
Textdraw1 TextDrawCreate(575.000000337.000000"$500");
    
TextDrawBackgroundColor(Textdraw1255);
    
TextDrawFont(Textdraw11);
    
TextDrawLetterSize(Textdraw10.5000003.299998);
    
TextDrawColor(Textdraw116711935);
    
TextDrawSetOutline(Textdraw10);
    
TextDrawSetProportional(Textdraw11);
    
TextDrawSetShadow(Textdraw14);
    return 
1;
}
public 
OnGameModeExit()
{
    return 
1;
}
public 
OnPlayerRequestClass(playeridclassid)
{
    
SetPlayerPos(playerid1958.37831343.157215.3746);
    
SetPlayerCameraPos(playerid1958.37831343.157215.3746);
    
SetPlayerCameraLookAt(playerid1958.37831343.157215.3746);
    return 
1;
}
public 
OnPlayerSpawn(playerid)
{
       
SetTimerEx("paycheck",10000,true,"i",playerid);
    return 
1;
}
public 
paycheckshow(playerid)
{
    
TextDrawHideForPlayer(playerid,Text:Textdraw0);
    
TextDrawHideForPlayer(playerid,Text:Textdraw1);
}
public 
paycheck(playerid)
{
    
TextDrawShowForPlayer(playerid,Text:Textdraw0);
    
TextDrawShowForPlayer(playerid,Text:Textdraw1);
    
SetTimerEx("paycheckshow",10000,true,"i",playerid);
    
GivePlayerMoney(playerid,500);

This works like the textdraw only once but I kept on getting the the money after the 10sec,I want the textdraw to show also after each sec like after each 10sec I get money,I want the texdraw to appear at the same time I get the money.
ThAnKs.
Reply
#2

bump...please I need it
Reply
#3

You'll have to use TextDrawHideForPlayer to, before you show it again.
Reply
#4

Can you add that in the code I provided please.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)