Доступ к архиву

Переход в группу "Пользователь"

300.00 ₽
Одноразовый платёж
Быстрый переход в группу "Пользователи", без надобности написания постов и ожидания.

Покупка дает возможность:
Быть полноправным участником форума
Нормальное копирование кода
Создавать темы
Скачивать файлы
Доступ к архиву Pawno-Info

моя система регт как её переделать

Статус
В этой теме нельзя размещать новые ответы.

Vadik_

Умник
PHP:
	SetPVarInt(playerid, "Deaths", 0);
	SetPVarInt(playerid, "Kills", 0);
	SetPVarInt(playerid, "Jailed", 0);
	SetPVarInt(playerid, "Frozen", 0);
	SetPVarInt(playerid, "Level", 0);
	SetPVarInt(playerid, "LoggedIn", 0);
	SetPVarInt(playerid, "Registered", 0);
	SetPVarInt(playerid, "God", 0);
	SetPVarInt(playerid, "GodCar", 0);
	SetPVarInt(playerid, "TimesSpawned", 0);
	SetPVarInt(playerid, "Muted", 0);
	SetPVarInt(playerid, "MuteWarnings", 0);
	SetPVarInt(playerid, "Warnings", 0);
	SetPVarInt(playerid, "Caps", 0);
	SetPVarInt(playerid, "DoorsLocked", 0);
	SetPVarInt(playerid, "pCar", -1);
	for(new i; i<PING_MAX_EXCEEDS; i++) SetPVarIntEx(playerid,"pPing_%d",i,0);
	SetPVarInt(playerid, "SpamCount", 0);
	SetPVarInt(playerid, "SpamTime", 0);
	SetPVarInt(playerid, "PingCount", 0);
	SetPVarInt(playerid, "PingTime", 0);
	SetPVarInt(playerid, "FailLogin", 0);
	SetPVarInt(playerid, "ConnectTime", gettime());
	//------------------------------------------------------
	new PlayerName[MAX_PLAYER_NAME], string[128], str[128], file[256];
	GetPlayerName(playerid, PlayerName, MAX_PLAYER_NAME);
	new tmp3[50]; GetPlayerIp(playerid,tmp3,50);
	//-----------------------------------------------------
	if(ServerInfo[ConnectMessages] == 1)
	{
	    new pAKA[256]; pAKA = dini_Get("ladmin/config/aka.txt",tmp3);
		if (strlen(pAKA) < 3) format(str,sizeof(str),"*** %s (ID: %d) зашел на сервер", PlayerName, playerid);
		else if (!strcmp(pAKA,PlayerName,true)) format(str,sizeof(str),"*** %s (ID: %d) зашел на сервер", PlayerName, playerid);
		else format(str,sizeof(str),"*** %s (%d) зашел на сервер (aka %s)", PlayerName, playerid, pAKA );

		for(new i = 0; i < MAX_PLAYERS; i++) if(IsPlayerConnected(i) && playerid != i)
		{
			if(GetPVarInt(i,"level") > 2) SendClientMessage(i,grey,str);
			else {
				format(string,sizeof(string),"*** %s (%d) зашел на сервер", PlayerName, playerid);
			 	SendClientMessage(i,grey,string);
			}
		}
	}
	//-----------------------------------------------------
    if (dUserINT(PlayerName2(playerid)).("banned") == 1)
    {
        SendClientMessage(playerid, red, "Этот ник забанен на сервере!");
		format(string,sizeof(string),"%s (ID: %d) автоматически кикнут. Причина: Ник забанен на сервере",PlayerName,playerid);
		SendClientMessageToAll(grey, string);  print(string);
		SaveToFile("KickLog",string);  Kick(playerid);
    }
	//-----------------------------------------------------
	if(ServerInfo[NameKick] == 1) {
		for(new s = 0; s < BadNameCount; s++) {
  			if(!strcmp(BadNames[s],PlayerName,true)) {
				SendClientMessage(playerid,red, "Ваш ник находится в черном списке, вы автоматически кикнуты.");
				format(string,sizeof(string),"%s (ID: %d) автоматически кикнут. (Причина: Запрещенный ник)",PlayerName,playerid);
				SendClientMessageToAll(grey, string);  print(string);
				SaveToFile("KickLog",string);  Kick(playerid);
				return 1;
			}
		}
	}
	//-----------------------------------------------------
	if(ServerInfo[PartNameKick] == 1) {
		for(new s = 0; s < BadPartNameCount; s++) {
			new pos;
			while((pos = strfind(PlayerName,BadPartNames[s],true)) != -1) for(new i = pos, j = pos + strlen(BadPartNames[s]); i < j; i++)
			{
				SendClientMessage(playerid,red, "Ваш ник не одобрен сервером, вы автоматически кикнуты.");
				format(string,sizeof(string),"%s (ID:%d) автоматически кикнут. (Причина: Запрещенный ник)",PlayerName,playerid);
				SendClientMessageToAll(grey, string);  print(string);
				SaveToFile("KickLog",string);  Kick(playerid);
				return 1;
			}
		}
	}
	//-----------------------------------------------------
	if(ServerInfo[Locked] == 1) {
		SetPVarInt(playerid, "AllowedIn", false);
		SendClientMessage(playerid,red,"Сервер закрыт!  У вас есть 20 чтобы авторизоваться на сервере или вас кикнет!");
		SendClientMessage(playerid,red,"Используйте /password [ваш пароль]");
		SetPVarInt(playerid, "LockKickTimer", SetTimerEx("AutoKick", 20000, 0, "i", playerid));
	}
	//-----------------------------------------------------
	if(strlen(dini_Get("ladmin/config/aka.txt", tmp3)) == 0) dini_Set("ladmin/config/aka.txt", tmp3, PlayerName);
 	else
	{
	    if( strfind( dini_Get("ladmin/config/aka.txt", tmp3), PlayerName, true) == -1 )
		{
		    format(string,sizeof(string),"%s,%s", dini_Get("ladmin/config/aka.txt",tmp3), PlayerName);
		    dini_Set("ladmin/config/aka.txt", tmp3, string);
		}
	}
	//-----------------------------------------------------
	if(!udb_Exists(PlayerName2(playerid))) SendClientMessage(playerid,orange, "Аккаунт: Используйте /register [пароль] чтобы зарегистрироваться на сервере");
	else
	{
	    SetPVarInt(playerid, "Registered", 1);
		format(file,sizeof(file),"/ladmin/users/%s.sav",udb_encode(PlayerName));
		new tmp2[256]; tmp2 = dini_Get(file,"ip");
		if( (!strcmp(tmp3,tmp2,true)) && (ServerInfo[AutoLogin] == 1) )
		{
			LoginPlayer(playerid);
			if(GetPVarInt(playerid, "Level") > 0)
			{
				format(string,sizeof(string),"Аккаунт: Вы автоматически авторизированы. (Уровень %d)", GetPVarInt(playerid, "Level") );
				SendClientMessage(playerid,green,string);
       		}
	   		else SendClientMessage(playerid,green,"Аккаунт: Вы автоматически авторизированы.");
  	    }
 		else SendClientMessage(playerid, green, "Аккаунт: Этот ник зарегистрирован, используйте /login [пароль], чтобы войти.");
	}
	return 1;
}
как можно её переделать в деалоги
 
Статус
В этой теме нельзя размещать новые ответы.
Сверху Снизу