Disable the Account
#1

Hello everybody I am a new Scripter and i need the help of all you.

This is the accountdisable command
PHP код:
dcmd_accountdisable(playeridparams[])
{
        new 
TargetID,Reason[64];
        if(
pInfo[playerid][Adminlevel] < 7) return SendClientMessage(playeridCOLOR_RED""ERROR_MESSAGE"");
        if(
sscanf(params"us"TargetIDReason)) return SendClientMessage(playeridCOLOR_RED"USAGE: /accountdisable [id] [Reason]");
        if(
TargetID == INVALID_PLAYER_ID || !IsPlayerConnected(TargetID )) return SendClientMessage(playeridCOLOR_RED"* Player Is Not Connected.");
        if(
pInfo[TargetID][Adminlevel] > 0) return SendClientMessage(playerid, -1"You cant disable admin.");
        else
        {
               
pInfo[TargetID][Adisable] =1;
               new 
str[128],str1[128];
               new 
targetname[MAX_PLAYER_NAME];
               
GetPlayerName(TargetID,targetname,24);
               
format(str,sizeof(str),"%s (%d) Has Been Disabled By An Admin. Reason: %s"targetnameTargetIDReason);
               
SendClientMessageToAll(COLOR_HOTPINKstr);
               
format(str1,sizeof(str1),"**KICK: %s (%d) (ACCOUNT DISABLED) Account Disabled"targetnameTargetID);
               
SendClientMessageToAll(COLOR_HOTPINKstr1);
               
KickWithMessage(TargetID,"You Have Been Removed From The Server.");
               print(
str);
               print(
str1);
        }
        return 
1;

And now i need to make it with day's.
I want to disable the account with some day's.
Example to disable account for 5 days in the real day's}|

Help mee and i will rep you :P
Reply


Messages In This Thread
Disable the Account - by arlindi - 08.06.2014, 18:52
Re : Disable the Account - by S4t3K - 08.06.2014, 19:08
Re: Disable the Account - by arlindi - 08.06.2014, 19:18
Re : Disable the Account - by S4t3K - 08.06.2014, 19:36
Re: Disable the Account - by arlindi - 08.06.2014, 19:38
Re : Disable the Account - by S4t3K - 08.06.2014, 19:46
Re: Disable the Account - by arlindi - 08.06.2014, 19:57
Re: Disable the Account - by arlindi - 09.06.2014, 12:18

Forum Jump:


Users browsing this thread: 2 Guest(s)