help with /unban [name] plz -
Flo_White - 25.02.2009
hi
i have 2 different bans system in my adminfilterscript.
1. /banacc = in the Playerfile "Banned=0" changes to "Banned=1"
2. the "normal" ban
now i tried to make a command /unban [name] to switch the "Banned=1" in the playerfile back to "Banned=0"
hope someone can help me
(i'm using dudb not dini)
greetings
Re: help with /unban [name] plz -
radhakr - 25.02.2009
Copy and paste /banacc so there are 2.
Change "/banacc" to "/unban".
Change the bit which sets Banned to "1" so that it sets it to "0".
Does this not work?
You may also want to make sure that /banacc definatley doesn't ban them the "normal" way.
Re: help with /unban [name] plz -
Flo_White - 25.02.2009
no this doesn't work :/
here is the code:
Код:
dcmd_banacc(playerid,params[])
{
if(PlayerData[playerid][Level] >= 1)
{
new grund[128],opfer;
if(sscanf(params,"uz",opfer,grund)) return SendClientMessage(playerid, COLOR_SYSTEM, "Usage: /ban [playerid] [reason]");
if (!IsPlayerConnected(opfer)) return SendClientMessage(playerid, COLOR_SYSTEM, "Invalid ID!");
new pname[MAX_PLAYER_NAME], oname[MAX_PLAYER_NAME],string[128];
GetPlayerName(playerid,pname,sizeof(pname)); GetPlayerName(opfer,oname,sizeof(oname));
format(string,sizeof(string),"[Server] %s has been namebanned by Admin %s [Reason: %s]",oname,pname,grund);
SendClientMessageToAll(COLOR_RED,string);
PlayerData[opfer][Banned] = 1;
Kick(opfer);
return 1;
}
else return SendClientMessage(playerid,COLOR_RED,"Admins only!");
}
for this code i need a /unban [name] command
Re: help with /unban [name] plz -
Flo_White - 26.02.2009
anyone?
Re: help with /unban [name] plz -
MenaceX^ - 26.02.2009
It's not possible, also it's possible if you use MySQL as your database.
Re: help with /unban [name] plz -
Flo_White - 26.02.2009
oh okay :/
Re: help with /unban [name] plz -
Flo_White - 27.02.2009
why doesn't it work without a mysql databse?
Re: help with /unban [name] plz -
Outbreak - 20.04.2009
I managed to write my own /unban [name] command with dini account system...
It unbans a player who isn't connected to the server by editing their user file and unbanning their ip also
Re: help with /unban [name] plz -
Flo_White - 20.04.2009
do you or did you released it publicly yet?
Re: help with /unban [name] plz -
Jakku - 20.04.2009
Easiest way to unban player is go to server folder and open samp.ban- file and remove line what player you want to ne unbanned