22.01.2013, 23:54
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; }