Нужна ваша помощь

Статус
В этой теме нельзя размещать новые ответы.
Сообщения
53
Реакции
2
Помог
1 раз(а)
Ошибка
В работе плагина
ОС
Linux
Amx Mod X
AMX Mod X 1.10.0.5467
Билд
Protocol version 48
Exe version 1.1.2.7/Stdio (cstrike)
ReHLDS version: 3.13.0.788-dev
Build date: 07:36:33 Jul 12 2023 (3378)
Build from: https://github.com/dreamstalker/rehlds/commit/f955b07
ReGamedll
ReGameDLL version: 5.26.0.668-dev
Build date: 19:02:48 Dec 31 2023
Build from: https://github.com/s1lentq/ReGameDLL_CS/commit/d3c0ec8
Версия Metamod
Metamod-r v1.3.0.149, API (5:13)
Metamod-r build: 18:21:12 Jan 15 2024
Metamod-r from: https://github.com/theAsmodai/metamod-r/commit/603a257
Список метамодулей
[ 1] Reunion               RUN   -    reunion_mm_i386.so         v0.1.0.137         ini  Start Never
[ 2] AMX Mod X RUN - amxmodx_mm_i386.so v1.10.0.5467 ini Start ANY
[ 3] Print Center Fix RUN - printcenterfix_mm_i386.so v2.0.1 ini ANY ANY
[ 4] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never
[ 5] Rechecker RUN - rechecker_mm_i386.so v2.7 ini Chlvl ANY
[ 6] ReSRDetector RUN - resrdetector_mm_i386.so v0.1.0 ini Chlvl ANY
[ 7] WHBlocker RUN - whblocker_mm_i386.so v1.5.697 ini Chlvl ANY
[ 8] ReSemiclip RUN - resemiclip_mm_i386.so v2.4.3 ini Chlvl ANY
[ 9] HitBox Fix RUN - hitbox_fix_mm_i386.so v1.1.5 ini Start ANY
[10] SafeNameAndChat RUN - SafeNameAndChat.so v1.2 Beta 3 ini ANY ANY
[11] VoiceTranscoder RUN - VoiceTranscoder.so v2017RC5 ini ANY ANY
[12] Ultimate Unprecacher RUN - unprecacher_i386.so vBeta 2.5.3 ini Chlvl Chlvl
[13] Accuracy Fix RUN - accuracyfix_mm.so v1.0.7 ini ANY ANY
[15] MySQL RUN - mysql_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[16] ReAPI RUN - reapi_amxx_i386.so v5.24.0.300-dev pl2 ANY Never
[17] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[18] FakeMeta RUN - fakemeta_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[19] CSX RUN - csx_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[20] CStrike RUN - cstrike_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[21] AuthEmu RUN - authemu_amxx_i386.so v5.2.12.525-dev+m pl2 ANY Never
[22] Engine RUN - engine_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
[23] SQLite RUN - sqlite_amxx_i386.so v1.10.0.5467 pl2 ANY ANY
Список плагинов
[  1] 0   Admin Base              1.10.0.546  AMXX Dev Team                                      admin.amxx   running  
[ 2] 1 Admin Commands 1.10.0.546 AMXX Dev Team admincmd.am running
[ 3] 2 AuthEmu API 1.0 Dev-MS Team authemu.amx running
[ 4] 3 [Customizable] AmxModM 0.0.5 Albertio amxmodmenu. running
[ 5] 4 Maps Menu 1.10.0.546 AMXX Dev Team mapsmenu.am running
[ 6] 5 Players Menu 1.10.0.546 AMXX Dev Team plmenu.amxx running
[ 7] 6 Stats Configuration 1.10.0.546 AMXX Dev Team statscfg.am running
[ 8] 7 FreshBans 1.4.8b kanagava unknown fresh_bans_ running
[ 9] 8 Unreal Cheater Cry 1.0.12 Karaulov unreal_chea running
[ 10] 9 AES: StatsX 0.5+1 serfreeman1337 aes_statsx_ running
[ 11] 10 CSStatsX SQL 0.7.4+2 serfreeman1337 csstatsx_sq running
[ 12] 11 Reset Score 1.2 maFFyoZZyk resetscore_ running
[ 13] 12 GameCMS_API 5.6.3 zhorzh78 unknown gamecms_api running
[ 14] 13 Auto Team Balance Adva 1.5.1 Radius unknown auto_team_b running
[ 15] 14 Parachute Lite [ReAPI] 11.0 Leo_[BH] parachute_l running
[ 16] 15 Auto recording demo 2.0 IzI | Bonaqua (R amx_autodem running
[ 17] 16 GameName Changer 1.0.0 Nordic Warrior gamenamecha running
[ 18] 17 Block Manager 1.1 maFFyoZZyk block_manag running
[ 19] 18 Say me and Say hp 1.4 neygomon KillHp.amxx running
[ 20] 19 Knife Duel with Telepo 1.2 neygomon knife_duel. running
[ 21] 20 Plugins Core 1.5.1 Radius unknown plugins_cor running
[ 22] 21 Killer ScreenFade 0.0.5 Vaqtincha reapi_kille running
[ 23] 22 Custom InfoConnect 1.1.1 ApXuTekToR Custom_Info running
[ 24] 23 adminconnect 0.1 Zone admin_conne running
[ 25] 24 Custom Weapons API 0.7.5 ArKaNeMaN CustomWeapo running
[ 26] 25 Advanced Kill Assists 1.5 Xelson next21_kill running
[ 27] 26 ACS injection med-kit 1.0.6.2 DEV-CS.RU acs_injecti running
[ 28] 27 Kills Counter 0.3 serfreeman1337 kills_count running
[ 29] 28 Icons Color Changer 1.1 xPaw IconsColorC running
[ 30] 29 Game Messages & Sounds 3.0 OciXCrom crx_gamemes running
[ 31] 30 [ReAPI] Best player of 1.1.2 F@nt0M best_player running
[ 32] 31 AFK Control 1.0.3 Emma Jule reapi_afk.a running
[ 33] 32 Ping Control 1.2 mx?! ping_contro running
[ 34] 33 AWP Limiter 1.4.0 Nordic Warrior awp_limiter running
[ 35] 34 AWPL: Disabled maps 1.0.0 Nordic Warrior awp_limiter running
[ 36] 35 Menu System 0.1.2 serfreeman1337 menuSystem. running
[ 37] 36 Mode 2x2 2.5re s1lent mode.amxx running
[ 38] 37 Light Style 0.0.2b b0t. LightStyle. running
[ 39] 38 Steam_GSClient_Bonus 1.0.5 ApXuTekToR Steam_GSCli running
[ 40] 39 aes_exp_on_win 1.0 w0w aes_exp_on_ running
[ 41] 40 [CWAPI] ANew Func 1.0.0 ArKaNeMaN CWAPI-ANewF running
[ 42] 41 Kill Sounds 1.0.0 Unknown & Ki95NG killsound.a running
[ 43] 42 Info Rank 0.4.5 ConnorMcLeod info_rank.a running
[ 44] 43 [GM] Weapon Models 2.0.0 [GM] NWC gm_weapon_m running
[ 45] 44 Damager 2.4.2 ArKaNeMaN https://arkanaplugins.ru/plugin Damager.amx running
[ 46] 45 Test AD 1.0 PAffAEJIkA :3 advert.amxx running
[ 47] 46 Revive Teammates 1.26 Unknown unknown revive_team running
[ 48] 47 Private Message: Admin 1.1 Denzer private_mes running
[ 49] 48 Private Message: Core 1.5 Denzer private_mes running
[ 50] 49 Private Message: Loggi 1.3 Denzer private_mes running
[ 51] 50 [AZ] Graffiti System R3.7Fix3 XxXx#xXxX graffiti_sy running
[ 52] 51 ScoreBoard Title 1.0 xPaw ScoreBoardT running
[ 53] 52 CT Bomb Cracker 0.0.4 Vaqtincha re_ct_bomb_ running
[ 54] 53 ExItem: MegaGrenade 1.5 mx?! exitem_mega running
[ 55] 54 Auto revive 1.1.1 SNauPeR auto_revive running
[ 56] 55 Molotov Cocktail API 2.31 CHEL74 + mx?! unknown molotov_coc running
[ 57] 56 Molotov Cocktail Spawn 1.8 mx?! molotov_coc running
[ 58] 57 Molotov Ext 2.0 mx?! molotov_ext running
[ 59] 58 [ReAPI] Grenade Trile 1.2 Base Code: Fatih reapi_grena running
[ 60] 59 [ReAPI] Healthnade 0.0.15f DEV-CS.RU Commun healthnade. running
[ 61] 60 C4 Timer on roundtime 0.3.3a neygomon c4timer.amx running
[ 62] 61 Custom Smoke 1.2.1 (non medusa custom_smok running
[ 63] 62 Grenade Effects 1.4 F@nt0M, d3m37r4 grenade_eff running
[ 64] 63 Bomb Taker 0.0.3c Vaqtincha bomb_taker. running
[ 65] 64 Bomb Scenario Notifica 0.2 Emma Jule bomb_scenar running
[ 66] 65 Back Weapons New 0.1 Vaqtincha backweapon. running
[ 67] 66 Fake Ping 1.1 MeRcyLeZZ/gyxoBk FakePing.am running
[ 68] 67 ChatAdditions: Core v1.9.4 Sergey Shorokhov ChatAdditio debug
[ 69] 68 ChatAdditions: SQLite v1.9.4 Sergey Shorokhov CA_Storage_ debug
[ 70] 69 CA: Mute v1.9.4 Sergey Shorokhov CA_Mute.amx debug
[ 71] 70 CA Addon: Death mute v1.9.4 Sergey Shorokhov CA_Addon_De debug
[ 72] 71 CA: VoteGAG 1.0.1-alph Sergey Shorokhov CA_Addon_Vo debug
[ 73] 72 CA Addon: Request UnGA v1.9.4 steelzzz CA_Addon_Re debug
[ 74] 73 CA: Gag v1.9.4 Sergey Shorokhov CA_Gag.amxx debug
[ 75] 74 Chat Manager (uni + sk 1.1.2-16xx Mistrick chatmanager running
[ 76] 75 Chat Manager: Addon 0.0.4-70 Mistrick chatmanager running
[ 77] 76 Map Manager: Core 3.2.1 Mistrick map_manager running
[ 78] 77 Map Manager: Scheduler 0.2.1 Mistrick map_manager running
[ 79] 78 Map Manager: Rtv 0.1.5 Mistrick map_manager running
[ 80] 79 Map Manager: Nominatio 0.3.5 Mistrick map_manager running
[ 81] 80 Map Manager: Effects 0.1.3 Mistrick map_manager running
[ 82] 81 Map Manager: Informer 0.0.5 Mistrick map_manager running
[ 83] 82 Map Manager: Sounds 0.0.3 Mistrick map_manager running
[ 84] 83 Custom Player Models A 0.2.5 F@nt0M & BlackSi custom_play running
[ 85] 84 Custom Player Models C 0.2.2 BlackSignature custom_play running
[ 86] 85 Custom Player Models T 0.2.1 BlackSignature custom_play running
[ 87] 86 Advanced Experience Sy 0.5.9 [REA serfreeman1337/s aes_main.am running
[ 88] 87 AES: CStrike Addon 0.5.9 [REA serfreeman1337/s aes_exp_cst running
[ 89] 88 AES: Informer 0.5.9 [REA serfreeman1337/s aes_informe running
[ 90] 89 AES: Admin Tools 0.5.9 [REA serfreeman1337/s aes_exp_edi running
[ 91] 90 AES: Bonus System 0.5.9 Vega serfreeman1337/s aes_bonus_s running
[ 92] 91 AES: Bonus CSTRIKE 0.5.9.1 [R serfreeman1337/s aes_bonus_c running
[ 93] 92 [VipM][I] Default 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-I-Defa running
[ 94] 93 [VipM-I] Limits 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-I-Limi running
[ 95] 94 [VipM] Items Controlle 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-ItemsC running
[ 96] 95 [VipM][L] Default 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-L-Defa running
[ 97] 96 [VipM][L] Logic 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-L-Logi running
[ 98] 97 [VipM][M] Spawn Health 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-M-Spaw running
[ 99] 98 [VipM-M] Spawn Items 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-M-Spaw running
[100] 99 [VipM][M] Vampire 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-M-Vamp running
[101] 100 [VipM-M] Vip in TAB 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-M-VipI running
[102] 101 [VipM][M] Weapon Menu 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-M-Weap running
[103] 102 [VipM] Misc 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-Misc.a running
[104] 103 [VipM] Modules Limiter 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipM-Module running
[105] 104 Vip Modular 5.0.0-b12 ArKaNeMaN https://github.com/ArKaNeMaN/am VipModular. running
[106] 105 [VipM-I] CWAPI 1.0.0 ArKaNeMaN VipM-I-Cwap running
[107] 106 [VipM-M] Multi Jump 1.2.0 ArKaNeMaN VipM-M-Mult running
[108] 107 [VipM-I] ACS-Injection 1.1.0 ArKaNeMaN VipM-I-ACSI running
[109] 108 [VipM-I] BlackSignatur 1.0.0 ArKaNeMaN VipM-I-Blac running
[110] 109 [VipM-I] Health Nade 1.1.0 ArKaNeMaN VipM-I-Heal running
Автор плагина
SNauPeR
Версия плагина
1.1.1
Исходный код
#include <amxmodx>
#include <amxmisc>
#include <reapi>

#if !defined MAX_CLIENTS
#define MAX_CLIENTS 32
#endif

#define rg_get_user_team(%0) TeamName:get_member(%0, m_iTeam)

#define TASK_CHECK 329158

new g_iCvarCountT; // Сколько игроков возродить T
new g_iCvarCountCT; // Сколько игроков возродить CT
new g_iCvarTime; // В течении скольки секунд с начала раунда ресаем
new g_iCvarMoney; // Сколько денег даем
new g_iCvarMinPl; // Минимальный онлайн
new g_iCvarRoundStart; // Минимальный онлайн

new g_iTimeOut; // Во сколько заканчивается
new g_iCountReviveT; // Сколько возродили T
new g_iCountReviveCT; // Сколько возродили CT

new TeamName:g_iUserTeam[MAX_CLIENTS + 1];
new bool:g_bUserForceSpawn[MAX_CLIENTS + 1];

new g_iMaxClients;

public plugin_init() {
register_plugin("Auto revive", "1.1.1", "SNauPeR");

register_dictionary("auto_revive.txt");

RegisterHookChain(RG_CSGameRules_RestartRound, "refwd_NewRound_Post", true);
RegisterHookChain(RG_CBasePlayer_Killed, "refwd_PlayerKilled_Post", true);
RegisterHookChain(RG_CBasePlayer_Spawn, "refwd_CBasePlayer_Spawn", true);


g_iCvarCountT = register_cvar(
"arev_players_t",
"2"
);
g_iCvarCountCT = register_cvar(
"arev_players_ct",
"2"
);
g_iCvarTime = register_cvar(
"arev_time",
"30"
);
g_iCvarMoney = register_cvar(
"arev_money",
"300"
);
g_iCvarMinPl = register_cvar(
"arev_minplayers",
"14"
);
g_iCvarRoundStart = register_cvar(
"arev_roundstart",
"2"
);


new szFileDir[128];
get_localinfo("amxx_configsdir", szFileDir, charsmax(szFileDir));
formatex(szFileDir, charsmax(szFileDir), "%s/plugins/auto_revive.cfg", szFileDir);
switch(file_exists(szFileDir)) {
case 0: log_amx("[Auto Revive] Файл ^"%s^" не найден.", szFileDir);
case 1: server_cmd("exec %s", szFileDir);
}

g_iMaxClients = get_maxplayers();
}

public refwd_NewRound_Post() {
new iRound = get_member_game(m_iTotalRoundsPlayed) + 1; // какой по счету раунд
if(iRound >= get_pcvar_num(g_iCvarRoundStart)) {
g_iCountReviveT = get_pcvar_num(g_iCvarCountT);
g_iCountReviveCT = get_pcvar_num(g_iCvarCountCT);
g_iTimeOut = get_systime(get_pcvar_num(g_iCvarTime) > 0 ? get_pcvar_num(g_iCvarTime) : floatround(get_cvar_float("mp_buytime") * 60.0));
} else
g_iCountReviveT = g_iCountReviveCT = g_iTimeOut = 0;

arrayset(g_bUserForceSpawn, false, MAX_CLIENTS+1);
for(new i = 1; i <= g_iMaxClients; i++)
remove_task(TASK_CHECK+i);
}

public refwd_PlayerKilled_Post(iVictim, iKiller, iGib) {
g_iUserTeam[iVictim] = rg_get_user_team(iVictim);
new iPlayerCount = get_playersnum_ex(GetPlayers_MatchTeam, "CT") + get_playersnum_ex(GetPlayers_MatchTeam, "TERRORIST");

if(g_iTimeOut >= get_systime() && ((g_iCountReviveCT && rg_get_user_team(iVictim) == TEAM_CT) || (g_iCountReviveT && rg_get_user_team(iVictim) == TEAM_TERRORIST)) && (!iPlayerCount || iPlayerCount < g_iCvarMinPl))
set_task(0.1, "reviveCheck", TASK_CHECK+iVictim);

return HC_CONTINUE;
}

public reviveCheck(taskid) {
new id = taskid - TASK_CHECK;
if(is_user_alive(id) || g_iUserTeam[id] != rg_get_user_team(id))
return PLUGIN_HANDLED;

new iPlayerCount = get_playersnum_ex(GetPlayers_MatchTeam, "CT") + get_playersnum_ex(GetPlayers_MatchTeam, "TERRORIST");

if(g_iTimeOut >= get_systime() && ((g_iCountReviveCT && rg_get_user_team(id) == TEAM_CT) || (g_iCountReviveT && rg_get_user_team(id) == TEAM_TERRORIST)) && (!iPlayerCount || iPlayerCount < g_iCvarMinPl)) {
if(rg_get_user_team(id) == TEAM_CT)
g_iCountReviveCT--;
else
g_iCountReviveT--;

new szName[32]; get_user_name(id, szName, charsmax(szName));
client_print_color(0, id, "%L", LANG_SERVER, "AUTO_REVIVE_CHAT", szName);
set_member(id, m_flRespawnPending, 0.15);
g_bUserForceSpawn[id] = true;
}
return PLUGIN_HANDLED;
}

public refwd_CBasePlayer_Spawn(id) {
if(g_bUserForceSpawn[id]) {
if(get_pcvar_num(g_iCvarMoney)) {
client_print_color(id, id, "%L", LANG_SERVER, "AUTO_REVIVE_CHAT_YOU", get_pcvar_num(g_iCvarMoney));
rg_add_account(id, get_pcvar_num(g_iCvarMoney), AS_ADD);
}
}
}
Доброго времени суток форумчане! Плагин компилируется, но возраждение работает при онлайне от 2х игроков. Несмотря что в исходнике стоит minplayer: 14
Помогите исправить
 
В этой теме было размещено решение! Перейти к решению.
Сообщения
112
Реакции
14
Помог
1 раз(а)
Покажите вывод arev_minplayers из консоли сервера.
 
Сообщения
1,082
Реакции
58
Помог
11 раз(а)
Ну конечноже, функуия register_cvat вернет нам id зарегистрированного квара и мы записываем в g_iCvarMinP, вот поэтому там значение непонятно, а не 14 и тут мы делаем эту проверку iPlayerCount < g_iCvarMinP, где сравниваете количество игроков с id квара
 
Последнее редактирование:
Сообщения
53
Реакции
2
Помог
1 раз(а)
@Code_0xABC,Можете помочь с кодом?если не затруднит
 
Сообщения
53
Реакции
2
Помог
1 раз(а)
Проблема решена!
Код переписал https://dev-cs.ru/members/10921/ , спасибо за помощь!
Если кому-то понадобиться оставлю исходник здесь
Код:
#include <amxmodx>
#include <amxmisc>
#include <reapi>

#define rg_get_user_team(%0)  TeamName:get_member(%0, m_iTeam)
#define is_user(%0) bool:(0 < %0 <= MaxClients)
const TASK_CHECK = 0x505C6;

enum any:DATA_USER {
    TeamName:TEAM,
    COUNT
};

enum any:DATA_REVIVE {
    RV_COUNT_TER,
    RV_COUNT_CT,
    RV_TIME,
    RV_MONAY,
    RV_MIN_USER,
    RV_ROUND
};

enum any:DATA_GAME {
    TIME,
    COUNT_TER,
    COUNT_CT
};

new
    gl_eCvar[DATA_REVIVE],
    gl_eCurrent[DATA_GAME],
    bool:gl_bUserSpawn[MAX_PLAYERS +1];

public plugin_init() {
    new const szNamePlugin[] = "(REAPI)Auto_Revive";
    register_plugin(szNamePlugin, "10.04.24", "DEV-CS.RU");

    RegisterHookChain(RG_CSGameRules_RestartRound, "RG_CSGameRules_RestartRound_Post", true);
    RegisterHookChain(RG_CBasePlayer_Killed, "RG_CBasePlayer_Killed_Post", true);
    RegisterHookChain(RG_CBasePlayer_Spawn, "RG_CBasePlayer_Spawn_Post", true);

    UTIL_Cvar(szNamePlugin[7]);
}

UTIL_Cvar(const szBuffer[]) {
    bind_pcvar_num(create_cvar("arev_players_t", "2"), gl_eCvar[RV_COUNT_TER]);
    bind_pcvar_num(create_cvar("arev_players_ct", "2"), gl_eCvar[RV_COUNT_CT]);
    bind_pcvar_num(create_cvar("arev_time", "30"), gl_eCvar[RV_TIME]);
    bind_pcvar_num(create_cvar("arev_money", "0"), gl_eCvar[RV_MONAY]);
    bind_pcvar_num(create_cvar("arev_minplayers", "9"), gl_eCvar[RV_MIN_USER]);
    bind_pcvar_num(create_cvar("arev_roundstart", "2"), gl_eCvar[RV_ROUND]);

    AutoExecConfig(true, szBuffer);
}

public client_disconnected(id)
    gl_bUserSpawn[id] = false;

public RG_CSGameRules_RestartRound_Post() {
    new iRound = get_member_game(m_iTotalRoundsPlayed) +1;

    if(iRound >= gl_eCvar[RV_ROUND]) {
        gl_eCurrent[COUNT_TER] = gl_eCvar[RV_COUNT_TER];
        gl_eCurrent[COUNT_CT] = gl_eCvar[RV_COUNT_CT];

        gl_eCurrent[TIME] = get_systime(gl_eCvar[RV_TIME] > 0 ? gl_eCvar[RV_TIME] : floatround(get_cvar_float("mp_buytime") * 60.0));
    }

    else gl_eCurrent[COUNT_TER] = gl_eCurrent[COUNT_CT] = gl_eCurrent[TIME] = 0;

    arrayset(gl_bUserSpawn, false, MaxClients);
}

public RG_CBasePlayer_Killed_Post(const pVictim, const pKiller, const iGib) {
    new eBuffer[DATA_USER];

    eBuffer[TEAM] = rg_get_user_team(pVictim);
    eBuffer[COUNT] = get_playersnum_ex(GetPlayers_MatchTeam, "CT") + get_playersnum_ex(GetPlayers_MatchTeam, "TERRORIST");

    if(is_user_bot(pVictim) || !is_user(pVictim) || gl_eCurrent[TIME] < get_systime())
        return HC_CONTINUE;

    if((!gl_eCurrent[COUNT_CT] && eBuffer[TEAM] == TEAM_CT) || (!gl_eCurrent[COUNT_TER] && eBuffer[TEAM] == TEAM_TERRORIST))
        return HC_CONTINUE;

    if(TEAM_TERRORIST > eBuffer[TEAM] > TEAM_CT)
        return HC_CONTINUE;

    if(eBuffer[COUNT] > gl_eCvar[RV_MIN_USER])
        set_task(0.1, "UTIL_ReviveCheck", TASK_CHECK +pVictim, eBuffer, COUNT);

    return HC_CONTINUE;
}

public UTIL_ReviveCheck(const eBuffer[], id) {
    id -= TASK_CHECK;

    if(!is_user_alive(id)) {
        set_member(id, m_flRespawnPending, 0.15);

        eBuffer[TEAM] == TEAM_CT ? --gl_eCurrent[COUNT_CT] : --gl_eCurrent[COUNT_TER];
        gl_bUserSpawn[id] = true;

        client_print_color(0, id, "^4• ^1Игрок ^3%n ^1был возрожден", id);
    }
}

public RG_CBasePlayer_Spawn_Post(const id) {
    if(gl_bUserSpawn[id]) {
        if(gl_eCvar[RV_MONAY]) {
            client_print_color(id, id, "^4* ^1Вы были возрождены, вам выдано ^3%d$", gl_eCvar[RV_MONAY]);
            rg_add_account(id, gl_eCvar[RV_MONAY], AS_ADD);
        }
    }
}
Тему можно закрывать.
 
Статус
В этой теме нельзя размещать новые ответы.

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

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