Unban help
#1

helloo,
can you help me with a samp command ?
/unban
i want to open some user file and change the "Lock=1" to "Lock=0"
it is enum defined , PlayerInfo[playerid][pLock]
ok thx
Reply
#2

Use SendRconCommand

Код:
stock UnbanIP(const szIPAddress[])
{
  new szRconCommand[30];
  format(szRconCommand, 30, "unbanip %s", szIPAddress);
  SendRconCommand(szRconCommand);
 
  SendRconCommand("reloadbans");
}
Reply
#3

No.I want to unban accounts , am i wrong ?
i want just to switch the lock to 0 on /unban name(ment users in datebase)
Reply
#4

Script Request Thread.
Reply
#5

Here... It's from my gamemode script. You can use it if you want! This is an in-game unban (admin) command.

Код:
}

dcmd_unbanip(playerid, params[])
{
	if (pInfo[playerid][pAdmin] < 5)
	{
	SystemMessage(playerid, "You are not Administrator.");
	return 1;
	}
  if(!strlen(params)) return SystemMessage(playerid, "Correct usage: '/unbanip [ip]'");
  new string[MAX_STRING];
	format(string, sizeof(string), "IP %s unbanned.", params);
  SystemMessage(playerid, string);
  format(string, sizeof(string), "unbanip %s", params);
	SendRconCommandEx(0, string);
	return 1;
}
I don't know how much admin lvl's you have. But you can change the ''5''.

A.McKinley
Reply
#6

OMG.
He doesnt want to unban an IP, he wants to unban an account file.
Reply
#7

yes,i have made when you ban someone PlayerInfo[playerid][pLock] to lock his account and i now just have to make a unlock
that is pLock == 0,but i am not good with managing files so i need a bit help...
Reply
#8

help
Reply
#9

bump,req in that thead but none realy helped me much..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)