Потребителски аватар
iNcolD
Приятели
Приятели
Мнения: 5
Регистриран: 16 яну 2015, 22:18
Ник в играта: Insidious
Скайп профил: cs-pro.player
Вашият пол е: Мъж
Местоположение: r00t~
Контакти:

AMXBans решение на проблема с view.php

Мнение от iNcolD » 05 дек 2018, 22:48

Здравейте, пиша тази тема относно хора с AMXBans GM 1.6 и по-точно бавното зареждане в view.php

Отворете: вашият_път_към_банлистата/include/rcon_hl_net.inc

1. Намерете

Код: Избери всички

//build info array
	$pos=0;
    $result["type"] = $this->parse_buffer($buffer,$pos,"bytestr");
	
	if ($result["type"] == 'I')
	{
		$result["version"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["name"] = $this->parse_buffer($buffer,$pos,"string");
		$result["map"] = $this->parse_buffer($buffer,$pos,"string");
		$result["mod"] = $this->parse_buffer($buffer,$pos,"string");
		$result["game"] = $this->parse_buffer($buffer,$pos,"string");
		$result["appid"] = $this->parse_buffer($buffer,$pos,"short");
		$result["activeplayers"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["maxplayers"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["botplayers"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["dedicated"] = $this->parse_buffer($buffer,$pos,"bytestr");
		$result["os"] = $this->parse_buffer($buffer,$pos,"bytestr");
		$result["password"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["secure"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["sversion"] = $this->parse_buffer($buffer,$pos,"string");
		$result["edf"] = $this->parse_buffer($buffer,$pos,"byte");
		switch ($result["edf"]) {
			case '\x80': // The server's game port # is included 
				$result["port"]= $this->parse_buffer($buffer,$pos,"short");
				break;
			case '\x40': // The spectator port # and then the spectator server name are included 
				$result["specport"]= $this->parse_buffer($buffer,$pos,"short");
				$result["specservername"] = $this->parse_buffer($buffer,$pos,"string");
				break;
			case '\x20': // The game tag data string for the server is included [future use] 
				$result["gametagdata"] = $this->parse_buffer($buffer,$pos,"string");
		}
	}
	else
	{
		$result['adress'] = $this->parse_buffer($buffer,$pos,"string");
		$result['name'] = $this->parse_buffer($buffer,$pos,"string");
		$result['map'] = $this->parse_buffer($buffer,$pos,"string");
		$result['mod'] = $this->parse_buffer($buffer,$pos,"string");
		$result['game'] = $this->parse_buffer($buffer,$pos,"string");
		$result['activeplayers'] = $this->parse_buffer($buffer,$pos,"byte");
		$result['maxplayers'] = $this->parse_buffer($buffer,$pos,"byte");
		$result['protocol'] = $this->parse_buffer($buffer,$pos,"byte");
		$result['dedicated'] = $this->parse_buffer($buffer,$pos,"bytestr");
		$result['os'] = $this->parse_buffer($buffer,$pos,"bytestr");
		$result['password'] = $this->parse_buffer($buffer,$pos,"byte");
		$result['modrunning'] = $this->parse_buffer($buffer,$pos,"byte");
		$result['modurl'] = $this->parse_buffer($buffer,$pos,"string");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$this->parse_buffer($buffer,$pos,"byte");
		$result["secure"] = $this->parse_buffer($buffer,$pos,"byte");
		$result["botplayers"] = $this->parse_buffer($buffer,$pos,"byte");
	}
	$this->Communicate("");
    //return formatted result


1.1. Променето го на:

Код: Избери всички

	//build info array
	$pos=0;
    $result["type"] = $this->parse_buffer($buffer,$pos,"bytestr");
	$result["version"] = $this->parse_buffer($buffer,$pos,"byte");
	$result["name"] = $this->parse_buffer($buffer,$pos,"string");
    $result["map"] = $this->parse_buffer($buffer,$pos,"string");
    $result["mod"] = $this->parse_buffer($buffer,$pos,"string");
    $result["game"] = $this->parse_buffer($buffer,$pos,"string");
	$result["appid"] = $this->parse_buffer($buffer,$pos,"short");
    $result["activeplayers"] = $this->parse_buffer($buffer,$pos,"byte");
    $result["maxplayers"] = $this->parse_buffer($buffer,$pos,"byte");
	$result["botplayers"] = $this->parse_buffer($buffer,$pos,"byte");
	$result["dedicated"] = $this->parse_buffer($buffer,$pos,"bytestr");
	$result["os"] = $this->parse_buffer($buffer,$pos,"bytestr");
	$result["password"] = $this->parse_buffer($buffer,$pos,"byte");
	$result["secure"] = $this->parse_buffer($buffer,$pos,"byte");
	$result["sversion"] = $this->parse_buffer($buffer,$pos,"string");
	$result["edf"] = $this->parse_buffer($buffer,$pos,"byte");
	switch ($result["edf"]) {
		case '\x80': // The server's game port # is included 
			$result["port"]= $this->parse_buffer($buffer,$pos,"short");
			break;
		case '\x40': // The spectator port # and then the spectator server name are included 
			$result["specport"]= $this->parse_buffer($buffer,$pos,"short");
			$result["specservername"] = $this->parse_buffer($buffer,$pos,"string");
			break;
		case '\x20': // The game tag data string for the server is included [future use] 
			$result["gametagdata"] = $this->parse_buffer($buffer,$pos,"string");
	}
    //return formatted result
    return $result;
2. Намерете:

Код: Избери всички

function parse_buffer($buffer,&$pos,$type) {
$result = '';

2.1. Променете го на:

Код: Избери всички

function parse_buffer($buffer,&$pos,$type) {
3. Намерете и изтрийте:

Код: Избери всички

$this->Communicate("");

Отговори

Кой е на линия

Потребители, разглеждащи този форум: Няма регистрирани потребители и 1 гост