#3

Try this
PHP код:
#define ADV_TIME 120000
CMD:advertise(playeridparams[]) 

    new 
string[128], name[MAX_PLAYER_NAME+1]; 
    if(
sscanf(params"s[128]"params)) return SendClientMessage(playeridCOLOR_CORRECTION"USAGE: (/ad)vertise [Advert Text]"); 
    if(
PlayerInfo[playerid][pAdmin] < 1) return 0;
    if(
GetPlayerScore <= 1) return SendClientMessage(playeridCOLOR_CORRECTION"You must be level 2 to place an advertise!"); 
    { 
            
GetPlayerName(playeridnamesizeof(name)); 
            
format(stringsizeof(string), "Advertisement: %s Contact: %s Ph: %d"paramsnamePlayerInfo[playerid][Phone]); 
            
SendClientMessageToAll(COLOR_ADVERTISEstring); 
            
GivePlayerMoney(playerid, -1000); 
            
SetTimerEx("AdvertiseWait"ADV_TIME,1"i"playerid); 
    } 
    return 
1
}  
forward AdvertiseWait(playerid);
public 
AdvertiseWait(playerid)
{
 new 
string[100];
 
format(stringsizeof(string), "Please wait %d seconds for next advertise"ADV_TIME);
 
SendClientMessage(playeridCOLOR_CORRECTIONstring);

Reply


Messages In This Thread
/ad - by Jaua10 - 16.04.2018, 05:41
Re: /ad - by TitoRayne - 16.04.2018, 09:01
Re: /ad - by ProScripter - 16.04.2018, 09:45

Forum Jump:


Users browsing this thread: 2 Guest(s)