• Регистрация на форуме отключена.
    Она будет открываться первого числа каждого месяца на 24 часа.

    Другие способы описаны>> тут <<

Team Select

Сообщения
433
Реакции
51
Предупреждения
5
Помог
4 раз(а)
Ошибка
Ошибок нет.
ОС
Linux
Amx Mod X
AMX Mod X 1.9.0.5270 (http://www.amxmodx.org)
Authors:
David "BAILOPAN" Anderson, Pavol "PM OnoTo" Marko
Felix "SniperBeamer" Geyer, Jonny "Got His Gun" Bergstrom
Lukasz "SidLuke" Wlasinski, Christian "Basic-Master" Hammacher
Borja "faluco" Ferrer, Scott "DS" Ehlert
Compiled: Jun 3 2020 15:25:29
Built from: https://github.com/alliedmodders/amxmodx/commit/1bfec70
Build ID: 5270:1bfec70
Core mode: JIT+ASM32
Билд
Protocol version 48
Exe version 1.1.2.7/Stdio (cstrike)
ReHLDS version: 3.7.0.696-dev
Build date: 18:46:47 May 18 2020 (2228)
Build from: https://github.com/dreamstalker/rehlds/commit/987ee51
ReGamedll
ReGameDLL version: 5.18.0.469-dev
Build date: 09:39:41 Jun 13 2020
Build from: https://github.com/s1lentq/ReGameDLL_CS/commit/532c132
Версия Metamod
Metamod-r v1.3.0.128, API (5:13)
Metamod-r build: 17:47:54 Aug 24 2018
Metamod-r from: https://github.com/theAsmodai/metamod-r/commit/0cf2f70
Список метамодулей
description      stat pend  file                        vers             src  load  unload
[ 1] SafeNameAndChat RUN - SafeNameAndChat.so v1.1 ini ANY ANY
[ 2] Reunion RUN - reunion_mm_i386.so v0.1.0.92c ini Start Never
[ 3] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never
[ 4] VoiceTranscoder RUN - VoiceTranscoder.so v2017RC5 ini ANY ANY
[ 5] AMX Mod X RUN - amxmodx_mm_i386.so v1.9.0.5270 ini Start ANY
[ 6] WHBlocker RUN - whblocker_mm_i386.so v1.5.697 ini Chlvl ANY
[ 7] ReSemiclip RUN - resemiclip_mm_i386.so v2.3.9 ini Chlvl ANY
[ 8] Rechecker RUN - rechecker_mm_i386.so v2.5 ini Chlvl ANY
[ 9] YaPB RUN - yapb.so v2.92 ini Chlvl ANY
[10] ReAimDetector RUN - reaimdetector_amxx_i386.so v0.2.2 pl5 ANY Never
[11] ReAPI RUN - reapi_amxx_i386.so v5.14.0.195-dev pl5 ANY Never
[12] SQLite RUN - sqlite_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[13] hackdetector RUN - hackdetector_amxx_i386.so v0.15.328.lite pl5 ANY ANY
[14] CStrike RUN - cstrike_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[15] Engine RUN - engine_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[16] FakeMeta RUN - fakemeta_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[17] CSX RUN - csx_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[18] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
[19] SxGeo RUN - sxgeo_amxx_i386.so v2.2 pl5 ANY Never
[20] Fun RUN - fun_amxx_i386.so v1.9.0.5270 pl5 ANY ANY
20 plugins, 20 running
Список плагинов
Currently loaded plugins:
name version author file status
[ 1] FreshBans 1.4.2b kanagava fresh_bans_142_ running
[ 2] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a running
[ 3] ScreenMaker 1.1 neygomon screen_maker.am running
[ 4] CSStatsX SQL 0.7.4+2 serfreeman1337 csstatsx_sql.am running
[ 5] Top Awards 0.11c Safety1st Top_Awards.amxx running
[ 6] RC BaseChanger freesrv custom rc_basechanger. stopped
[ 7] ReChecker Logging freesrv custom rc_logging.amxx running
[ 8] Lite Admin ESP 1.1 neygomon, AcE admin_esp_ace.a running
[ 9] Advanced Kill Assists 1.3b Xelson next21_kill_ass running
[ 10] Admin Base 1.9.0.5263 AMXX Dev Team admin.amxx running
[ 11] Ping Control 1.33 neygomon+wopox+H ping_control_N_ running
[ 12] AFK Control ReNew 1.2(a) neygomon afk_control.amx running
[ 13] AES: StatsX 0.5+1 serfreeman1337 aes_statsx_cstr running
[ 14] Stats Configuration 1.9.0.5263 AMXX Dev Team statscfg.amxx running
[ 15] Team Select 1.6.0 [email protected] teamselect.amxx running
[ 16] Maps Menu 1.9.0.5263 AMXX Dev Team mapsmenu.amxx running
[ 17] Server Menu 1.5.0 [email protected] server_menu.amx running
[ 18] Parachute Lite [ReAPI] 14.0 Leo_[BH] parachute_leo_1 running
[ 19] Demo Recorder 2.4.1 [email protected] demo_recorder.a running
[ 20] Rock to Ban 1.02 Safety1st rock2ban.amxx running
[ 21] Players Menu 1.7 neugomon players_menu.am running
[ 22] [ReAPI] Kills Counter 0.3 serfreeman1337 kills_counter.a running
[ 23] lite screen fade 1.0 AcE re_lite_screen_ running
[ 24] [ReAPI] Bullet Damage 0.0.1 ConnorMcLeod re_bullet_damag running
[ 25] SF Warn Menu 0.1.4g serfreeman1337 sf_admin_warns. running
[ 26] AES: StatsX Info Rank 0.1 serfreeman1337 aes_statsx_rank running
[ 27] Adverts 1.0 pUzzlik adverts_message running
[ 28] Advanced MapChooser 1.4 neygomon map_chooser_CSD running
[ 29] GameName Changer 1.0 neugomon gamename_change running
[ 30] DM AutoBalance 0.4.0 Nordic Warrior AutoBalance.amx running
[ 31] AntiFlood Change Name 28.11.2018 sergrib AntiFlood_Chang running
[ 32] Radio Hudmsg Block 1.0 AcE radio_hudmsg_bl running
[ 33] resetscore(ReAPI) 1.0 Phantom resetscore.amxx running
[ 34] ProKreedz Hook v2.3 vato loco [GE-S] dr_hook.amxx running
[ 35] BunnyHop 1.0 PurposeLess bunnyhop.amxx running
[ 36] Easy MultiJump 1.6 twistedeuphoria/ reapi_multijump debug
[ 37] CSDM Core 0.0.8 Vaqtincha csdm_core.amxx running
[ 38] CSDM Equip Manager 0.0.8 Vaqtincha csdm_equip_mana running
[ 39] CSDM Map Cleaner 0.0.8 Vaqtincha csdm_map_cleane running
[ 40] CSDM Misc 0.0.8 Vaqtincha csdm_misc.amxx running
[ 41] CSDM Protection 0.0.8 Vaqtincha csdm_protection running
[ 42] CSDM Spawn Manager 0.0.8 Vaqtincha csdm_spawn_mana running
[ 43] [ReAPI] AMX Vampire 0.1 [email protected] amx_vampire.amx running
[ 44] [SxGeo] Connect Info 1.0p s1lent sxgeo_connect_i running
[ 45] Steam Models 0.1b+mod.l Freedo.m steam_models.am running
[ 46] Admin Loger 1.0 HARDCORE admin_loger.amx running
[ 47] Weaponmenu 1.0 HARDCORE weaponmenu.amxx running
[ 48] Blood Fountain 1.0 HARDCORE Blood_Fountain. running
[ 49] Ultimate KillStreak Ad 0.7 SAMURAI ut_killstreak_a running
[ 50] Music Connection 1.0.0 Jumper Music_Connectio running
[ 51] Models Replacement 0.0.2 ConnorMcLeod | V models_replacem running
[ 52] Smoke: HealthNade 0.0.4 wopox1337 Smoke_HealthNad running
[ 53] Chat Manager: Addon 0.0.4-70 Mistrick chatmanager_add running
[ 54] Chat Manager 1.1.2-16 Mistrick chatmanager.amx running
[ 55] Advanced Experience Sy 0.5.9 [REA serfreeman1337/s aes_main.amxx running
[ 56] AES: CStrike Addon 0.5.9 [REA serfreeman1337/s aes_exp_cstrike running
[ 57] AES: Informer 0.5.9 [REA serfreeman1337/s aes_informer.am running
[ 58] AES: Admin Tools 0.5.9 [REA serfreeman1337/s aes_exp_editor. running
[ 59] Chat Additions Core 1.0.0-beta Sergey Shorokhov ChatAdditions_C debug
[ 60] [CA] Gag 1.0.0-beta Sergey Shorokhov CA_Gag.amxx debug
[ 61] [CA] Mute menu 1.0.0-beta Sergey Shorokhov CA_Mute.amxx debug
Автор плагина
[email protected]
Версия плагина
1.6.0
Исходный код
/**
*
* Name: Team Menu
* Version: 1.6.0 (09.05.2020)
* Author: [email protected]
* Description: The plugin show custom team select menu instead of default
*
* Thanks rian18 (https://dev-cs.ru/members/6256/) to add german translation
*
* Requirements: ReHLDS, ReGameDLL, AmxModX 1.9.0, ReAPI
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
*/

#pragma semicolon 1

#include <amxmodx>
#include <reapi>

enum {
MODE_NORMAL_TEAM,
MODE_RANDOM_TEAM,
};

enum {
SPEC_ALWAYS,
SPEC_AFTER_JOIN,
};

new HookChain:HookShowMenuPre;
new Mode, Spectators, Appearance, Unlimited, Float:TimeLimit;
new AdminFlags = ADMIN_BAN, Autojoin, AutojoinImminity = ADMIN_BAN;
new Float:NextChooseTeamTime[MAX_PLAYERS + 1];
new bool:FreezePeriodChanged = false;

public plugin_init() {
register_plugin("Team Select", "1.6.0", "[email protected]");
register_dictionary("teamselect.txt");

RegisterHookChain(RG_ShowVGUIMenu, "ShowVGUIMenu_Pre", false);
RegisterHookChain(RG_HandleMenu_ChooseTeam, "HandleMenu_ChooseTeam_Pre", false);
RegisterHookChain(RG_HandleMenu_ChooseTeam, "HandleMenu_ChooseTeam_Post", true);
HookShowMenuPre = RegisterHookChain(RG_ShowMenu, "ShowMenu_Pre", false);
DisableHookChain(HookShowMenuPre);

bind_pcvar_num(create_cvar(
"amx_ts_mode", "0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_MODE_DESC"),
true, 0.0, true, 1.0
), Mode);

bind_pcvar_num(create_cvar(
"amx_ts_spec", "0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_SPEC_DESC"),
true, 0.0, true, 1.0
), Spectators);

bind_pcvar_num(create_cvar(
"amx_ts_appearance", "0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_APPEARANCE_DESC"),
true, 0.0, true, 1.0
), Appearance);

bind_pcvar_num(create_cvar(
"amx_ts_unlimited", "0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_UNLIMITED_DESC"),
true, 0.0, true, 1.0
), Unlimited);

bind_pcvar_float(create_cvar(
"amx_ts_time_limit", "0.0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_TIME_LIMIT_DESC"),
true, 0.0
), TimeLimit);

bind_pcvar_num(create_cvar(
"amx_ts_autojoin", "0", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_AUTOJOIN_DESC"),
true, 0.0, true, 1.0
), Autojoin);

hook_cvar_change(create_cvar(
"amx_ts_admin_flags", "d", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_FLAGS_DESC")
), "HookChangeFlag");

hook_cvar_change(create_cvar(
"amx_ts_autojoin_immunity", "d", FCVAR_SERVER,
fmt("%L", LANG_SERVER, "TS_AUTOJOIN_IMMUNITY_DESC"),
true, 0.0, true, 1.0
), "HookChangeImmunity");

AutoExecConfig(true, "teamselect");
}

public HookChangeFlag(const pcvar, const oldValue[], const newValue[]) {
AdminFlags = read_flags(newValue);
}

public HookChangeImmunity(const pcvar, const oldValue[], const newValue[]) {
AutojoinImminity = read_flags(newValue);
}

public client_putinserver(id) {
NextChooseTeamTime[id] = 0.0;
if (!Autojoin) {
return PLUGIN_CONTINUE;
}
if (AutojoinImminity && (get_user_flags(id) & AutojoinImminity == AutojoinImminity)) {
return PLUGIN_CONTINUE;
}
rg_join_team(id, rg_get_join_team_priority());
return PLUGIN_CONTINUE;
}

public ShowVGUIMenu_Pre(const id, VGUIMenu:menuType) {
if (is_user_bot(id) || menuType != VGUI_Menu_Team) {
return HC_CONTINUE;
}

if (TimeLimit && NextChooseTeamTime[id] >= get_gametime()) {
client_printex(id, print_center, "#Only_1_Team_Change");
set_member(id, m_iMenu, Menu_ChooseTeam);
return HC_SUPERCEDE;
}

new bool:newPlayer = bool:(TeamName:get_member(id, m_iTeam) == TEAM_UNASSIGNED);
SetGlobalTransTarget(id);

new menu[MAX_MENU_LENGTH], keys;
new len = formatex(menu, charsmax(menu), "\w%l^n^n", "TS_SELECT_TEAM");
if (Mode == MODE_NORMAL_TEAM) {
len += formatex(menu[len], charsmax(menu) - len, "\d[\r1\d] \r%l \d[\y%d\d]^n", "TS_TEAM_T", get_member_game(m_iNumTerrorist));
len += formatex(menu[len], charsmax(menu) - len, "\d[\r2\d] \r%l \d[\y%d\d]^n", "TS_TEAM_CT", get_member_game(m_iNumCT));
keys |= MENU_KEY_1 | MENU_KEY_2;
} else {
len += formatex(menu[len], charsmax(menu) - len, "\d[\r1\d] \r%l^n", newPlayer ? "TS_ENTER_GAME" : "TS_CHANGE_TEAM");
keys |= MENU_KEY_1;
}

if (
Spectators == SPEC_ALWAYS
|| (Spectators == SPEC_AFTER_JOIN && !newPlayer)
|| (AdminFlags && (get_user_flags(id) & AdminFlags) == AdminFlags)
) {
len += formatex(menu[len], charsmax(menu) - len, "^n\d[\r6\d] \w%l^n", "TS_SPECTATOR");
keys |= MENU_KEY_6;
}

if (!newPlayer) {
len += formatex(menu[len], charsmax(menu) - len, "^n^n\d[\r0\d] \w%l^n", "TS_CLOSE");
keys |= MENU_KEY_0;
}

set_member(id, m_bForceShowMenu, true);
SetHookChainArg(3, ATYPE_INTEGER, keys);
SetHookChainArg(4, ATYPE_STRING, menu);

// https://wiki.alliedmods.net/Half-Life_1_Game_Events#ShowMenu
// https://github.com/alliedmodders/amxmodx/blob/c86813697acf3a3b577ca35426053db8dd7f8902/amxmodx/util.cpp#L48
if (strlen(menu) > 175) {
EnableHookChain(HookShowMenuPre);
}
return HC_CONTINUE;
}

// Fix menu limit in ReGameDLL (https://github.com/s1lentq/ReGameDLL_CS/blob/9d89a347fa22662b716697c97150ddea2bd00d99/regamedll/dlls/client.cpp#L394)
public ShowMenu_Pre(const id, const keys, const time, const needMore, const menu[]) {
DisableHookChain(HookShowMenuPre);
show_menu(id, keys, menu, time);
set_member(id, m_iMenu, Menu_ChooseTeam); // AMXX overide m_iMenu after show_menu
return HC_SUPERCEDE;
}

public HandleMenu_ChooseTeam_Pre(const id, const MenuChooseTeam:slot) {
if (is_user_bot(id)) {
return HC_CONTINUE;
}

if (slot == MenuChoose_Spec) {
if (is_user_alive(id) && !get_member_game(m_bFreezePeriod)) {
set_member_game(m_bFreezePeriod, true);
FreezePeriodChanged = true;
}
} else {
if (Mode == MODE_RANDOM_TEAM) {
new MenuChooseTeam:team;
switch (TeamName:get_member(id, m_iTeam)) {
case TEAM_TERRORIST: team = MenuChoose_CT;
case TEAM_CT: team = MenuChoose_T;
default: team = MenuChoose_AutoSelect;
}
SetHookChainArg(2, ATYPE_INTEGER, team);
}

if (!Appearance) {
set_member_game(m_bSkipShowMenu, true);
}
}
return HC_CONTINUE;
}

public HandleMenu_ChooseTeam_Post(const id, const MenuChooseTeam:slot) {
if (FreezePeriodChanged) {
set_member_game(m_bFreezePeriod, false);
}
if (!GetHookChainReturn(ATYPE_INTEGER)) {
return;
}
if (Unlimited) {
set_member(id, m_bTeamChanged, false);
}

NextChooseTeamTime[id] = get_gametime() + TimeLimit;
if (slot == MenuChoose_Spec || Appearance) {
return;
}

set_member_game(m_bSkipShowMenu, false);
if (get_member(id, m_bJustConnected)) {
set_member(id, m_iJoiningState, GETINTOGAME);
set_member(id, m_bJustConnected, false);
} else if (slot != MenuChoose_Spec && !Appearance && is_user_alive(id)) {
user_kill(id);
}

set_member(id, m_iMenu, Menu_ChooseAppearance);
rg_internal_cmd(id, "joinclass", "5");
}
Доброго всем времени суток. Возникла такая проблема после входа на сервер режим наблюдателя работает хотя выставил в настройках "Только после входа"
+ хотел добавить что при первом запуске сервера всё работает нормально. Проблема возникает после перехода/смены на другую карту.
В консоль когда ввожу amx_ts_spec выводит "amx_ts_spec" is "1"
Настройки прикрепил ниже.
C++:
// This file was auto-generated by AMX Mod X (v1.9.0.5270)
// Cvars for plugin "Team Select" by "[email protected]" (teamselect.amxx, v1.6.0)


// Режим меню. 0 - Нормальное, 1 - Случайная команда
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_mode "0"

// Режим наблюдателя. 0 - Всегда, 1 - Только после входа
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_spec "1"

// Выбор класса. 1 - Вкл., 0 - Выкл.
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_appearance "1"

// Безлимитный выбор команды. 1 - Вкл., 0 - Выкл.
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_unlimited "1"

// Ограничить выбор команды по времени. 0.0 - Выкл.
// -
// Default: "0.0"
// Minimum: "0.000000"
amx_ts_time_limit "0.0"

// Автовход. 1 - On, 0 - Off
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_autojoin "0"

// Флаги админа для режима наблюдателя. "" - Выкл.
// -
// Default: "d"
amx_ts_admin_flags ""

// Флаги иммунитета автовхода. "" - Выкл.
// -
// Default: "d"
// Minimum: "0.000000"
// Maximum: "1.000000"
amx_ts_autojoin_immunity ""
 
В этой теме было размещено решение! Перейти к решению.
Сообщения
429
Реакции
276
Предупреждения
5
Помог
13 раз(а)
amx_who вывод.
 
Сообщения
433
Реакции
51
Предупреждения
5
Помог
4 раз(а)
Shel,
C++:
Сейчас на сервере:
 #  nick             authid               userid   и   с   права
 1  K_E_I_R_O_W      VALVE_13:0:1543650539 1        Не   Не   z
 3  cUTTerDupeRR |   STEAM_0:0:103915492  6        Не   Не   z
 4  HARDCORE         STEAM_0:0:90693370   5        Да   Да   abcdefghijklmnopqrsuz
Всего 3
 
Сообщения
429
Реакции
276
Предупреждения
5
Помог
13 раз(а)
156 удали если хочешь. Либо сними флаги, либо меняй флаги на 95.
 
Сообщения
433
Реакции
51
Предупреждения
5
Помог
4 раз(а)
Shel, спасибо попробую отпишу.
26 Июн 2020
Shel, сработало удаление. Ещё раз спасибо!
 
Сообщения
2,275
Реакции
2,523
Помог
58 раз(а)
HARDCORE, квар amx_ts_admin_flags пустое значение и не нужно ничего удалять
 
  • Нравится
Реакции: Ayk

Пользователи, просматривающие эту тему

Сейчас на форуме нет ни одного пользователя.
Сверху Снизу