Не работает AES Flags by Bonus 0.1

Статус
В этой теме нельзя размещать новые ответы.
Сообщения
18
Реакции
3
Ошибка
Отсутствует подключение к базе
ОС
Linux
Amx Mod X
AMX Mod X 1.8.3-Re
Билд
ReHLDS version: 3.4.0.656-dev-myarena.ru
Build date: 14:57:29 Aug 6 2018 (1577)
ReGamedll
ReGameDLL version: 5.7.0.312-dev
Build date: 07:53:34 May 31 2018
Версия Metamod
Metamod-r v1.3.0.127, API (5:13)
Metamod-r build: 10:49:17 Jun 15 2018
Список метамодулей
[ 1] Reunion          RUN   -    reunion_mm_i386.so          v0.1.0.92       ini  Start Never
[ 2] VoiceTranscoder RUN - VoiceTranscoder.so v2017RC3 ini ANY ANY
[ 3] AMX Mod X RUN - amxmodx_mm_i386.so v1.8.3-Re ini Start ANY
[ 4] ReSemiclip RUN - resemiclip_mm_i386.so v2.3.9 ini Chlvl ANY
[ 5] ReSRDetector RUN - resrdetector_mm_i386.so v0.1.0 ini Chlvl ANY
[ 6] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never
[ 7] Rechecker RUN - rechecker_mm_i386.so v2.5 ini Chlvl ANY
[ 8] WHBlocker RUN - whblocker_mm_i386.so v1.5.695 ini Chlvl ANY
[ 9] ReAPI RUN - reapi_amxx_i386.so v5.6.0.157-dev pl3 ANY Never
[10] CStrike RUN - cstrike_amxx_i386.so v1.8.3-Re pl3 ANY ANY
[11] ReAimDetector RUN - reaimdetector_amxx_i386.so v0.2.2 pl3 ANY Never
[12] FakeMeta RUN - fakemeta_amxx_i386.so v1.8.3-Re pl3 ANY ANY
[13] MySQL RUN - mysql_amxx_i386.so v1.8.3-Re pl3 ANY ANY
[14] hackdetector RUN - hackdetector_amxx_i386.so v0.15.328.lite pl3 ANY ANY
[15] Engine RUN - engine_amxx_i386.so v1.8.3-Re pl3 ANY ANY
[16] Fun RUN - fun_amxx_i386.so v1.8.3-Re pl3 ANY ANY
[17] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.8.3-Re pl3 ANY ANY
Список плагинов
[  1] Ultimate Chats Control  4.5         neygomon          ucc.amxx         running  
[ 2] UCC Addon: VoteGAG 1.2 neygomon ucc_votegag.amx running
[ 3] Lite Bans 2.2 neygomon lite_bans.amxx running
[ 4] ScreenMaker 1.1 neygomon screen_maker.am running
[ 5] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a running
[ 6] ReChecker Logging freesrv AMXX rc_logging.amxx running
[ 7] RC BaseChanger freesrv AMXX rc_basechanger. running
[ 8] CSStatsX SQL 0.7.4 serfreeman1337 csstatsx.amxx running
[ 9] Admin Loader 3.5 neygomon admin_loader.am running
[ 10] Lite Translit 2.8 neygomon lite_translit.a running
[ 11] Advanced Client Checke 0.3.4 Mistrick cmdchecker.amxx running
[ 12] ReAPI AWP Limitter 2.2 neygomon awp_limitter.am stopped
[ 13] AFK Control 1.4.1 [Rnd neygomon afk_control.amx running
[ 14] Lite Recoder 1.0.1 neygomon amx_demorec.amx running
[ 15] GameName Changer 1.0 neugomon gamename_change running
[ 16] Steam Bonus 1.1 ill+F@nToM steam_bonus.amx running
[ 17] [ReAPI] No Team Flash 1.0 ReHLDS Team noteamflash.amx running
[ 18] [ReAPI] AdminFreeLook 1.0 ReHLDS Team adminfreelook.a running
[ 19] Admin Commands 1.8.3-Re AMXX Dev Team admincmd.amxx running
[ 20] Admin Votes 1.8.3-Re AMXX Dev Team adminvote.amxx running
[ 21] Admin Chat 1.8.3-Re AMXX Dev Team adminchat.amxx running
[ 22] Commands Menu 1.8.3-Re AMXX Dev Team cmdmenu.amxx running
[ 23] Advanced MapChooser 1.4 neygomon map_chooser.amx running
[ 24] Menus Front-End 1.5 untest neugomon menufront.amxx running
[ 25] CS Misc. Stats 1.8.3-Re AMXX Dev Team miscstats.amxx running
[ 26] Players Menu 1.7 neugomon plmenu.amxx running
[ 27] Maps Menu 1.4.1 neugomon mapsmenu.amxx running
[ 28] Weapon Restrict 1.7 s1lent restmenu.amxx running
[ 29] CS Stats Logging 1.8.3-Re AMXX Dev Team stats_logging.a running
[ 30] Stats Configuration 1.8.3-Re AMXX Dev Team statscfg.amxx running
[ 31] resetscore(ReAPI) 1.0 Phantom resetscore.amxx running
[ 32] Ping Checker 26.0.1 RC1 h1k3 ping_checker.am running
[ 33] C4 Timer on roundtime 0.3.3a neygomon c4timer.amxx running
[ 34] Parachute Lite 1.0 Leo_[BH] parachute.amxx running
[ 35] [ReVIP] System Core 2.5 full pUzzlik re_vip_core.amx running
[ 36] [ReVIP] Menu 2.5 full pUzzlik re_vip_menu.amx running
[ 37] [ReVIP] Add HP 2.5 full pUzzlik re_vip_hp_add.a stopped
[ 38] [ReVIP] Damager 2.5 full pUzzlik re_vip_damager. stopped
[ 39] [ReVIP] Custom Shop 2.5 full pUzzlik re_vip_shop.amx running
[ 40] [ReVIP] Custom Knife 2.5 full pUzzlik re_vip_custom_k stopped
[ 41] [ReVIP] Custom Deagle 2.5 full pUzzlik re_vip_custom_d stopped
[ 42] [ReVIP] Custom Famas 2.5 full pUzzlik re_vip_custom_f stopped
[ 43] [ReVIP] Custom AK-47 2.5 full pUzzlik re_vip_custom_a stopped
[ 44] [ReVIP] Custom M4A1 2.5 full pUzzlik re_vip_custom_m stopped
[ 45] [ReVIP] Custom Scout 2.5 full pUzzlik re_vip_custom_s stopped
[ 46] [ReVIP] Custom AWP 2.5 full pUzzlik re_vip_custom_a stopped
[ 47] AES: Bonus System 0.5.9 Vega serfreeman1337/s aes_bonus_syste stopped
[ 48] AES Bonus: Flags 0.1 Sonyx aes_bonus_flags running
[ 49] Advanced Experience Sy 0.5.9 [REA serfreeman1337/s aes_main.amxx running
[ 50] AES: Informer 0.5.9 [REA serfreeman1337/s aes_informer.am running
[ 51] AES: Admin Tools 0.5.9 [REA serfreeman1337/s aes_exp_editor. running
[ 52] AES: CStrike Addon 0.5.9 [REA serfreeman1337/s aes_exp_cstrike running
[ 53] AES: Bonus CSTRIKE 0.5.9 [REA serfreeman1337/s aes_bonus_cstri stopped
[ 54] AES: StatsX 0.6 Dev-CS serfreeman1337/s aes_statsx_cstr running
Автор плагина
Sonyx
Версия плагина
0.1
Исходный код
#include <amxmodx>
#include <sqlx>
#if AMXX_VERSION_NUM < 183
#include <colorchat>
#endif

forward amxbans_sql_initialized(Handle:sqlTuple, const dbPrefix[]);
forward fbans_sql_connected(Handle:sqlTuple);

enum (+=1) {
NONE = 0,
AMX,
FB
}

enum _:qState { AddOne, AddTwo }

new g_System = NONE;
new Handle:g_DBTuple;
new g_TableAdmins[32], g_TableSAdmins[32], g_TableSInfo[32], g_ServerIp[25];
new g_szQuery[512], g_Data[2];

public plugin_init()
{
#define PNAME "AES Bonus: Flags"
#define PVERSION "0.1"
#define PAUTHOR "Sonyx"
register_plugin(PNAME, PVERSION, PAUTHOR);
}

public amxbans_sql_initialized(Handle:sqlTuple, const dbPrefix[])
{
if (g_System != NONE) {
return PLUGIN_CONTINUE;
}

g_DBTuple = sqlTuple;
g_System = AMX;

formatex(g_TableAdmins, charsmax(g_TableAdmins), "%s_amxadmins", dbPrefix);
formatex(g_TableSInfo, charsmax(g_TableSInfo), "%s_serverinfo", dbPrefix);
formatex(g_TableSAdmins, charsmax(g_TableSAdmins), "%s_admins_servers", dbPrefix);

get_cvar_string("amxbans_server_address", g_ServerIp, charsmax(g_ServerIp));
if (!g_ServerIp[0]) {
get_user_ip(0, g_ServerIp, charsmax(g_ServerIp), 0);
}

return PLUGIN_CONTINUE;
}

public fbans_sql_connected(Handle:sqlTuple)
{
new i_Ip[16], i_Port[8];
if (g_System != NONE) {
return PLUGIN_CONTINUE;
}

g_DBTuple = sqlTuple;
g_System = FB;
if (!get_cvar_string("amx_amxadmins_table", g_TableAdmins, charsmax(g_TableAdmins)))
g_TableAdmins = "amx_amxadmins";
if (!get_cvar_string("amx_admins_table", g_TableSAdmins, charsmax(g_TableSAdmins)))
g_TableSAdmins = "amx_admins_servers";
get_cvar_string("fb_servers_table", g_TableSInfo, charsmax(g_TableSInfo));
get_cvar_string("fb_server_ip", i_Ip, charsmax(i_Ip));
get_cvar_string("fb_server_port", i_Port, charsmax(i_Port));

formatex(g_ServerIp, charsmax(g_ServerIp), "%s:%s", i_Ip, i_Port);

return PLUGIN_CONTINUE;
}

public SQL_Handler(failstate, Handle:query, err[], errcode, dt[], datasize)
{
switch(failstate)
{
case TQUERY_CONNECT_FAILED, TQUERY_QUERY_FAILED:
{
log_amx("[SQL ERROR #%d][Query State %d] %s", errcode, dt[0], err);
SQL_FreeHandle(query);
return;
}
}

switch(dt[0])
{
case AddOne:
{
g_Data[0] = AddTwo;
new szAuth[25], iID = SQL_GetInsertId(query);
get_user_authid(dt[1], szAuth, charsmax(szAuth));
formatex(g_szQuery, charsmax(g_szQuery), "INSERT INTO %s (admin_id, server_id, custom_flags, use_static_bantime) VALUES ('%d', (SELECT id FROM %s WHERE address = '%s'), '', 'no')", g_TableSAdmins, iID, g_TableSInfo, g_ServerIp);
SQL_ThreadQuery(g_DBTuple, "SQL_Handler", g_szQuery, g_Data, sizeof(g_Data));
}
case AddTwo:
{
SQL_FreeHandle(query);
server_cmd("amx_reloadadmins");
}
}
}

public pointBonus_GiveFlags(id, flags[], days)
{
if(!flags[0] || !days)
return 0;
if (g_System == NONE)
{
client_print_color(id, id, "^4[ЗВАНИЯ] ^3Отсутствует подключение к Базе!");
return 0;
}
if (get_user_flags(id) & read_flags(flags))
{
client_print_color(id, id, "^4[ЗВАНИЯ] ^3У вас уже есть данная привилегия!");
return 0;
}
new szAuth[25], szName[32], szPlayerEnd;

get_user_authid(id, szAuth, charsmax(szAuth));
get_user_name(id, szName, charsmax(szName));
szPlayerEnd = get_systime() + days * 86400;

g_Data[0] = AddOne;
g_Data[1] = id;

formatex(g_szQuery, charsmax(g_szQuery), "INSERT INTO %s (username, access, flags, steamid, nickname, ashow, created, expired, days) VALUES ('%s', '%s', 'ce', '%s', '%s', '0', UNIX_TIMESTAMP(NOW()), '%d', '%d')", g_TableAdmins, szAuth, flags, szAuth, szName, szPlayerEnd, days);
SQL_ThreadQuery(g_DBTuple, "SQL_Handler", g_szQuery, g_Data, sizeof(g_Data));

return 1;
}
Возможно ли это то, что я перешел на lite bans by neugomon ?
До перехода покупка випки через /anew работала.
 
В этой теме было размещено решение! Перейти к решению.
Сообщения
18
Реакции
3
Sonyx, Работает, Спасибо за быстрое реагирование проблемы)) Тему Можно закрыввать
 
Статус
В этой теме нельзя размещать новые ответы.

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

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