Need help on Helpers
#1

If i restart my Sever it don't wanna Save,can i have it like in my scriptfiles? Helper 0 for no,Helper 1 for Yes.i wanna save it under scriptfiles
Code:
COMMAND:sethelper(playerid, params[])
{
    new pID, str[128];
    if(!IsPlayerAdmin(playerid))
    return SendClientMessage(playerid, -1, "Only admins can use this command.");
    if(sscanf(params,"u", pID))
    return SendClientMessage(playerid,-1,"USAGE: /sethelper [PlayerID]");
    if(!IsPlayerConnected(pID))
    return SendClientMessage(playerid, -1, "ERROR: Selected player is not connected.");
    if(playerHelper[pID])
    return SendClientMessage(playerid, -1, "Selected player is a helper already.");
    new name[MAX_PLAYER_NAME+1], pName[MAX_PLAYER_NAME+1];
    GetPlayerName(pID, name, sizeof name);
    GetPlayerName(playerid, pName, sizeof pName);
    playerHelper[pID] = true;
    format(str, sizeof str, "Admin %s made you a helper.", pName);
    SendClientMessage(pID, -1, str);
    format(str, sizeof str, "You made %s a helper.", name);
    SendClientMessage(playerid, -1, str);
    return 1;
}
Reply


Messages In This Thread
Need help on Helpers - by DerickClark - 22.01.2013, 23:54
Re: Need help on Helpers - by Infinity90 - 23.01.2013, 00:27
Re: Need help on Helpers - by DerickClark - 23.01.2013, 00:29
Re: Need help on Helpers - by Deviant96 - 23.01.2013, 00:55
Re: Need help on Helpers - by DerickClark - 23.01.2013, 01:01

Forum Jump:


Users browsing this thread: 3 Guest(s)