Участник
Пользователь
- Сообщения
- 290
- Реакции
- 28
- Помог
- 2 раз(а)
- Ошибка
-
L 08/08/2019 - 02:20:49: Player 11 is not in game.
L 08/08/2019 - 02:20:49: [AMXX] Displaying debug trace (plugin "vip_reapi.amxx", version "0.15")
L 08/08/2019 - 02:20:49: [AMXX] Run time error 10: native error (native "menu_display")
L 08/08/2019 - 02:20:49: [AMXX] [0] vip_reapi.sma::open_vipmenu (line 449)
L 08/08/2019 - 02:20:49: [AMXX] [1] vip_reapi.sma::hand_pistol_menu (line 753)
- ОС
- Linux
- Amx Mod X
-
AMX Mod X 1.9.0.5247
- Билд
-
Protocol version 48
Exe version 1.1.2.7/Stdio (cstrike)
ReHLDS version: 3.6.0.675-dev
Build date: 17:01:39 Jul 30 2019 (1935)
Build from: https://github.com/dreamstalker/rehlds/commit/0c28b70
- ReGamedll
-
ReGameDLL version: 5.9.0.366-dev
Build date: 15:46:24 Jul 30 2019
Build from: https://github.com/s1lentq/ReGameDLL_CS/commit/0104389
- Версия 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
- Список метамодулей
-
Currently loaded plugins:
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.92 ini Start Never
[ 3] ReAuthCheck RUN - reauthcheck_mm_i386.so v0.1.6 ini Start Never
[ 4] AMX Mod X RUN - amxmodx_mm_i386.so v1.9.0.5247 ini Start ANY
[ 5] ReSemiclip RUN - resemiclip_mm_i386.so v2.3.9 ini Chlvl ANY
[ 6] Rechecker RUN - rechecker_mm_i386.so v2.5 ini Chlvl ANY
[ 7] WHBlocker RUN - whblocker_mm_i386.so v1.5.696 ini Chlvl ANY
[ 8] ReSRDetector RUN - resrdetector_mm_i386.so v0.1.0 ini Chlvl ANY
[ 9] MySQL RUN - mysql_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[10] ReAPI RUN - reapi_amxx_i386.so v5.8.0.166-dev pl4 ANY Never
[11] hackdetector RUN - hackdetector_amxx_i386.so v0.15.328.lite pl4 ANY ANY
[12] ReAimDetector RUN - reaimdetector_amxx_i386.so v0.2.2 pl4 ANY Never
[13] Hide Cvars RUN - hidecvars_amxx_i386.so v1.0 pl4 ANY ANY
[14] Engine RUN - engine_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[15] FakeMeta RUN - fakemeta_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[16] Ham Sandwich RUN - hamsandwich_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[17] CStrike RUN - cstrike_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[18] GeoIP RUN - geoip_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
[19] Fun RUN - fun_amxx_i386.so v1.9.0.5247 pl4 ANY ANY
19 plugins, 19 running
- Список плагинов
-
[ 1] [ReAPI] Anti overflow 1.0 Some Author antioverflow.am running
[ 2] Damager Advanced 1.1.2 Radius (based on damager_advance running
[ 3] Advanced Slot Free 2.0 cyby & S.Cosmin advanced_slot.a running
[ 4] Advanced Mute 2.1 OciXCrom crx_advmute.amx running
[ 5] Advanced Experience Sy 0.5.9 [REA serfreeman1337/s aes_main.amxx running
[ 6] AES: CStrike Addon 0.5.9 [REA serfreeman1337/s aes_exp_cstrike running
[ 7] AES: Informer 0.5 Vega serfreeman1337 aes_informer.am running
[ 8] AES: Admin Tools 0.5.9 [REA serfreeman1337/s aes_exp_editor. running
[ 9] AES: Bonus System 0.5.9 Vega serfreeman1337/s aes_bonus_syste running
[ 10] AES: Bonus CSTRIKE 0.5.9.1 [R serfreeman1337/s aes_bonus_cstri running
[ 11] AES Bonus: Flags 0.2 Sonyx aes_bonus_flags running
[ 12] fb_forwards 0.1.4 Kanagava & Realu fb_forwards.amx running
[ 13] FreshBans 1.4.0b kanagava fresh_bans_140_ running
[ 14] Admin Load 3.9.3 Dev F@nt0M adminload.amxx running
[ 15] ReAimDetector API 0.2.2 ReHLDS Team reaimdetector.a running
[ 16] Lista admini (amx_who) cs.area-ga Kobra whobun.amxx running
[ 17] Ultimate SS 1.2 Hack ultimate_ss.amx running
[ 18] Accuracy Fix 3.0 Numb accuracy_fix.am running
[ 19] unknown unknown unknown flash.amxx running
[ 20] Team Transfer 2.1 UnFoRgIvEn transfer_chat.a running
[ 21] MOTD Commands 1.3 OciXCrom crx_motdcommand running
[ 22] Admin Commands 1.9.0.5247 AMXX Dev Team admincmd.amxx running
[ 23] Commands Menu 1.9.0.5247 AMXX Dev Team cmdmenu.amxx running
[ 24] Menus Front-End 1.9.0.5247 AMXX Dev Team menufront.amxx running
[ 25] SHOW IP + LAST IP 2.0 Alka + x amx_showip_last running
[ 26] Players Menu 1.7 neugomon players_menu.am running
[ 27] Pause Plugins 1.9.0.5247 AMXX Dev Team pausecfg.amxx running
[ 28] Admin Help 1.9.0.5247 AMXX Dev Team adminhelp.amxx running
[ 29] Language Menu 1.0 F@nt0M langmenu.amxx running
[ 30] Plugin Menu 1.9.0.5247 AMXX Dev Team pluginmenu.amxx running
[ 31] Admin Chat 1.8.1.3746 AMXX Dev Team adminchat.amxx running
[ 32] Private Message: Core 1.2 Denzer private_message running
[ 33] Private Message: Loggi 1.2 Denzer private_message running
[ 34] CSStatsX SQL 0.7.4+2 serfreeman1337 csstatsx_sql.am running
[ 35] Top Awards 1.0 neygomon top_awards.amxx running
[ 36] Items Restrict Ultimat 0.0.4 Vaqtincha items_restrict_ running
[ 37] AES: StatsX 0.5+1 serfreeman1337 aes_statsx_cstr running
[ 38] Best Player MOTD 1.2.1 OciXCrom crx_bestplayer. running
[ 39] Simple Menu 2.1.1 OciXCrom crx_simplemenu. debug
[ 40] Restricted Names 1.1 Hattrick JM3Ch3R nick.amxx running
[ 41] Whatsapp_Group_Request 3.2 CrAzY MaN whatsapp_group_ running
[ 42] Quick and No Scope Det 1.2 EFFx QuickNoScopeD.a running
[ 43] SERVER TASKS 2.0 HATTRICK (HTTRCK server_tasks.am running
[ 44] Bet 2.2 Filip Vilicic bet.amxx running
[ 45] Stats Configuration 1.9.0.5247 AMXX Dev Team statscfg.amxx running
[ 46] Autoresponder/Advertis 0.5 MaximusBrood ads.amxx running
[ 47] AFK Control ReNew 1.2(a) neygomon afk_control.amx running
[ 48] Style C4 Timer 2.1 OciXCrom crx_c4timer.amx running
[ 49] Ping Faker 1.5a MeRcyLeZZ pingfaker_count running
[ 50] unknown unknown unknown fake.amxx running
[ 51] Ultimele Harti 1.0 M@$t3r_@dy harti.amxx running
[ 52] CFG Slash 1.0 aNNakin cfg_slash.amxx running
[ 53] [ReAPI] TopRoundDamage 1.0.5 Dager* *.* -G- damage_round.am running
[ 54] Fall Damage HP Restore 0.0.1 Vaqtincha FallDamageHpRes running
[ 55] WeaponState Remember 0.0.4 Vaqtincha weaponstate_rem running
[ 56] Objective as GameName 1.1.1 CHEL74 obj_as_gamename running
[ 57] Activitate Admini 2.0c Askhanar activitate.amxx running
[ 58] ResetScore 1.0 Leo_[BH] resetscore_reap running
[ 59] Chat Manager 1.1.2-16 Mistrick chatmanager.amx running
[ 60] Swear Replacement 1.5 kaboomkazoom swear_repl.amxx running
[ 61] Auto Round Restart 1.0 LondoN eXtream restartr.amxx running
[ 62] Simple Online Logger 23.05.19 mx?! simple_online_l running
[ 63] Trial Access 05.07.19 mx?! trial_access.am running
[ 64] Slap/Slay Team 1.0 Kobra slaylslapteam.a running
[ 65] VIP Menu [CS.PLAYARENA 0.15 Leo_[BH](tradus vip_reapi.amxx debug
[ 66] VIP NOU 1.0 test vampire.amxx running
[ 67] Invisible Spectator 1.0 ReHLDS Team invisible_spect running
[ 68] Check Vip 2.0 Leo_[BH] check.amxx running
[ 69] Ultimate Who 2.0 Askhanar AmxWhoMenu.amxx running
[ 70] Slay Losers 1.1.6 [email protected] slay_losers.amx running
[ 71] Map Manager: Core 3.0.0 Mistrick map_manager_cor running
[ 72] Map Manager: Scheduler 0.1.0 Mistrick map_manager_sch running
[ 73] Map Manager: Rtv 0.0.4 Mistrick map_manager_rtv running
[ 74] Map Manager: Nominatio 0.0.8 Mistrick map_manager_nom running
[ 75] Map Manager: BlockList 0.0.3 Mistrick map_manager_blo running
[ 76] Map Manager: Online so 0.0.2 Mistrick map_manager_onl running
[ 77] Map Manager: Effects 0.0.8 Mistrick map_manager_eff running
[ 78] Map Manager: Informer 0.0.5 Mistrick map_manager_inf running
[ 79] Map Manager: Advanced 0.0.4 Mistrick map_manager_adv running
[ 80] Hide HUD/Menu on Vote 1.2.2 d3m37r4 hide_hud_and_me running
[ 81] Auto Team Balance Adva 1.5.1 Radius auto_team_balan running
[ 82] Team Select 1.5.0 F@nt0M teamselect.amxx running
[ 83] Force Gag 1.2 zorken zilla_gag.amxx running
[ 84] unknown unknown unknown parasutaflag.am running
[ 85] [ReAPI:AMXX] Buy Nades 0.1 F@nt0M Buy_Nades_Timeo debug
[ 86] Voiceserver Connect 1.1.015 Nextra voiceserver_con debug
[ 87] Advanced Kill Assists 0.9 Spection next21_kill_ass running
[ 88] Hide 1.1 xPaw hidexpaw.amxx running
[ 89] M_AntiRusher 2.83 Miczu xPaw_Antirusher running
[ 90] Say Me And HP 1.0 Javekson say_me_hp.amxx running
[ 91] Save score & money 1.2.4 Minni Mouse Save_Score_and_ running
[ 92] MultiJump 1.1 twistedeuphoria doublej.amxx running
[ 93] Admin Exec 2.0c Askhanar amxexec.amxx running
[ 94] Admin Spectator ESP 1.3 KoST esp.amxx running
[ 95] Night VIP 1.0 TBONTB vipfreenoaptea. running
[ 96] ReChecker Logging 1.0 custom rc_logging.amxx running
96 plugins, 96 running
- Автор плагина
- Leo_[BH]
- Версия плагина
- PLUGIN_VERSION "0.15"
- Исходный код
-
// Ðвтор плагина: Leo_[BH] (http://vk.com/id64427766)
// Создание плагинов на заказ: https://vk.com/cs_rain
#include <amxmodx>
#include <reapi>
#include <fakemeta_util>
#define PLUGIN_VERSION "0.15"
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new const pistols[6] = {CSW_GLOCK18, CSW_USP, CSW_P228, CSW_DEAGLE, CSW_FIVESEVEN, CSW_ELITE}
new const primary[18] = {CSW_SCOUT, CSW_XM1014, CSW_MAC10, CSW_AUG, CSW_UMP45, CSW_SG550, CSW_GALIL, CSW_FAMAS, CSW_AWP,
CSW_MP5NAVY, CSW_M249, CSW_M3, CSW_M4A1, CSW_TMP, CSW_G3SG1, CSW_SG552, CSW_AK47, CSW_P90}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new g_msg_SayText
new cvar_flag, cvar_round_primary, cvar_round_awp, cvar_grenadepack_limit, cvar_opentime_menu, cvar_auto_open, cvar_chat_show, cvar_custom_type
new bool:map_blocked
new round
new Float:time_open_to_menu
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new const pistols_names[7][] = { "", "GLOCK18", "USP", "P228", "DEAGLE", "FIVESEVEN", "ELITE" }
new const pistols_entnames[7][] = { "", "weapon_glock18", "weapon_usp", "weapon_p228", "weapon_deagle", "weapon_fiveseven", "weapon_elite" }
new const bpammo_pistol[7] = { -1, 120, 100, 52, 35, 100, 100 }
new i_pistol[33]
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new const armor_names[][] = { "Fara armura", "Vesta", "Vesta+Casca" }
new i_armor[33]
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
new const nade_names[][] = { "Fara grenade", "Toate grenadele", "Flash", "He", "Smoke(Item restrictionat)", "He+Flash" }
new i_nades[33]
new i_round_grenades[33]
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public plugin_precache()
{
map_check()
}
public plugin_init()
{
register_plugin("VIP Menu [CS.AREA-GAMES.RO]", PLUGIN_VERSION, "Leo_[BH](tradus Kobra)")
register_cvar("cs_rain_vipmenu", PLUGIN_VERSION, FCVAR_SERVER|FCVAR_SPONLY)
// [data/lang]
register_dictionary("vip.txt")
// Cvars
cvar_flag = register_cvar("vipmenu_access", "t")
cvar_round_primary = register_cvar("vipmenu_round_primary", "2")
cvar_round_awp = register_cvar("vipmenu_round_awp", "3")
cvar_grenadepack_limit = register_cvar("vipmenu_grenade_limit", "4")
cvar_opentime_menu = register_cvar("vipmenu_open_time", "30")
cvar_auto_open = register_cvar("vipmenu_auto_open", "1")
cvar_chat_show = register_cvar("vipmenu_chat_show", "1")
cvar_custom_type = register_cvar("vipmenu_custom_type", "3")
// Client Commands
register_clcmd("vipmenu", "vipmenu")
register_clcmd("say vipmenu", "vipmenu")
register_clcmd("say /vipmenu", "vipmenu")
register_clcmd("say_team vipmenu", "vipmenu")
register_clcmd("say_team /vipmenu", "vipmenu")
// Messages
g_msg_SayText = get_user_msgid("SayText")
if(!map_blocked)
{
// Events
register_event("TextMsg", "event_game_restart", "a", "2=#Game_will_restart_in")
register_event("TextMsg", "event_game_restart", "a", "2=#Game_Commencing")
register_event("HLTV", "event_round_start", "a", "1=0", "2=0")
// Player Spawn
// RegisterHam(Ham_Spawn, "player", "fw_PlayerSpawn_Post", 1)
RegisterHookChain(RG_CBasePlayer_Spawn, "fw_PlayerSpawn_Post", 1)
}
}
public plugin_cfg()
{
server_cmd("exec addons/amxmodx/configs/vip/vip.cfg")
}
public event_game_restart()
{
round = 0
}
public event_round_start()
{
round++
arrayset(i_round_grenades, get_pcvar_num(cvar_grenadepack_limit), 33)
time_open_to_menu = get_gametime() + get_pcvar_float(cvar_opentime_menu)
}
public client_connect(id)
{
i_pistol[id] = 4 // дигл
i_armor[id] = 2 // Ð±Ñ€Ð¾Ð½Ñ + шлем
i_nades[id] = 1 // вÑе гранаты
}
public fw_PlayerSpawn_Post(id)
{
if(!is_user_alive(id)) return;
if(!has_access_vipmenu(id)) return;
give_my_pistol(id)
give_my_armor(id)
give_my_grenades(id)
if(get_pcvar_num(cvar_auto_open)) if(round >= get_pcvar_num(cvar_round_primary)) open_vipmenu(id)
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public vipmenu(id)
{
if(map_blocked)
{
chat_color(id, "%L %L", id, "VIP_CHAT_PREFIX", id, "VIP_CHAT_MAP_BLOCKED")
return PLUGIN_HANDLED;
}
if(!has_access_vipmenu(id))
{
chat_color(id, "%L %L", id, "VIP_CHAT_PREFIX", id, "VIP_CHAT_NOT_ACCESS")
return PLUGIN_HANDLED;
}
open_vipmenu(id)
return PLUGIN_HANDLED;
}
public open_vipmenu(id)
{
static text_vip_menu[9][64]
formatex(text_vip_menu[0], 63, "%L", id, "VIP_MENU_0")
new r_prim = get_pcvar_num(cvar_round_primary)
new r_awp = get_pcvar_num(cvar_round_awp)
if(round < r_awp)
{
formatex(text_vip_menu[1], 63, "\d%L \r[\d%d %s\r]", id, "VIP_MENU_1", r_awp, "a runda")
}
else if(!is_user_alive(id))
{
formatex(text_vip_menu[1], 63, "\d%L", id, "VIP_MENU_1")
}
else if(get_gametime() > time_open_to_menu)
{
formatex(text_vip_menu[1], 63, "\d%L", id, "VIP_MENU_1")
}
else
{
formatex(text_vip_menu[1], 63, "\w%L", id, "VIP_MENU_1")
}
if(round < r_prim)
{
formatex(text_vip_menu[2], 63, "\d%L \r[\d%d %s\r]", id, "VIP_MENU_2", r_prim, "a runda")
formatex(text_vip_menu[3], 63, "\d%L \r[\d%d %s\r]", id, "VIP_MENU_3", r_prim, "a runda")
formatex(text_vip_menu[4], 63, "\d%L \r[\d%d %s\r]^n", id, "VIP_MENU_4", r_prim, "a runda")
}
else if(!is_user_alive(id))
{
formatex(text_vip_menu[2], 63, "\d%L", id, "VIP_MENU_2")
formatex(text_vip_menu[3], 63, "\d%L", id, "VIP_MENU_3")
formatex(text_vip_menu[4], 63, "\d%L^n", id, "VIP_MENU_4")
}
else if(get_gametime() > time_open_to_menu)
{
formatex(text_vip_menu[2], 63, "\d%L", id, "VIP_MENU_2")
formatex(text_vip_menu[3], 63, "\d%L", id, "VIP_MENU_3")
formatex(text_vip_menu[4], 63, "\d%L^n", id, "VIP_MENU_4")
}
else
{
formatex(text_vip_menu[2], 63, "\w%L", id, "VIP_MENU_2")
formatex(text_vip_menu[3], 63, "\w%L", id, "VIP_MENU_3")
formatex(text_vip_menu[4], 63, "\w%L^n", id, "VIP_MENU_4")
}
new custom_type = get_pcvar_num(cvar_custom_type)
clamp(custom_type, 0, 3)
if(custom_type >= 1) formatex(text_vip_menu[5], 63, "%L", id, "VIP_MENU_5", pistols_names[i_pistol[id]])
if(custom_type >= 2) formatex(text_vip_menu[6], 63, "%L", id, "VIP_MENU_6", armor_names[i_armor[id]])
if(custom_type >= 3) formatex(text_vip_menu[7], 63, "%L", id, "VIP_MENU_7", nade_names[i_nades[id]])
formatex(text_vip_menu[8], 63, "%L", id, "VIP_MENU_EXIT")
new menu = menu_create(text_vip_menu[0], "hand_vipmenu")
for (new n = 1; n <= 4+custom_type; n++)
{
new Number[4]
formatex(Number, charsmax(Number), "%i", n)
menu_additem(menu, text_vip_menu[n], Number, 0)
}
menu_setprop(menu, MPROP_EXITNAME, text_vip_menu[8])
menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
menu_display(id, menu, 0)
return PLUGIN_HANDLED;
}
public hand_vipmenu(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_destroy(menu)
return PLUGIN_HANDLED
}
new data[6], iName[64], access, callback
menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
new key = str_to_num(data)
switch(key)
{
case 1:
{
if(!is_user_alive(id)) return PLUGIN_HANDLED
if(round < get_pcvar_num(cvar_round_awp))
{
open_vipmenu(id)
return PLUGIN_HANDLED
}
if(get_gametime() > time_open_to_menu)
{
client_print(id, print_center, "%L", id, "VIP_MSG_TIME", get_pcvar_num(cvar_opentime_menu))
open_vipmenu(id)
return PLUGIN_HANDLED
}
give_primary_weapon(id, 1)
give_my_pistol(id)
give_my_armor(id)
give_my_grenades(id)
}
case 2:
{
if(!is_user_alive(id)) return PLUGIN_HANDLED
if(round < get_pcvar_num(cvar_round_primary))
{
open_vipmenu(id)
return PLUGIN_HANDLED
}
if(get_gametime() > time_open_to_menu)
{
client_print(id, print_center, "%L", id, "VIP_MSG_TIME", get_pcvar_num(cvar_opentime_menu))
open_vipmenu(id)
return PLUGIN_HANDLED
}
give_primary_weapon(id, 2)
give_my_pistol(id)
give_my_armor(id)
give_my_grenades(id)
}
case 3:
{
if(!is_user_alive(id)) return PLUGIN_HANDLED
if(round < get_pcvar_num(cvar_round_primary))
{
open_vipmenu(id)
return PLUGIN_HANDLED
}
if(get_gametime() > time_open_to_menu)
{
client_print(id, print_center, "%L", id, "VIP_MSG_TIME", get_pcvar_num(cvar_opentime_menu))
open_vipmenu(id)
return PLUGIN_HANDLED
}
give_primary_weapon(id, 3)
give_my_pistol(id)
give_my_armor(id)
give_my_grenades(id)
}
case 4:
{
if(!is_user_alive(id)) return PLUGIN_HANDLED
if(round < get_pcvar_num(cvar_round_primary))
{
open_vipmenu(id)
return PLUGIN_HANDLED
}
if(get_gametime() > time_open_to_menu)
{
client_print(id, print_center, "%L", id, "VIP_MSG_TIME", get_pcvar_num(cvar_opentime_menu))
open_vipmenu(id)
return PLUGIN_HANDLED
}
give_primary_weapon(id, 4)
give_my_pistol(id)
give_my_armor(id)
give_my_grenades(id)
}
case 5:
{
open_pistol_menu(id)
}
case 6:
{
open_armor_menu(id)
}
case 7:
{
open_nade_menu(id)
}
}
return PLUGIN_HANDLED;
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public open_pistol_menu(id)
{
new menu = menu_create("\rAlege pistol\y:\w", "hand_pistol_menu")
for (new n = 1; n <= 6; n++)
{
new Number[4]
formatex(Number, charsmax(Number), "%i", n)
menu_additem(menu, pistols_names[n], Number, 0)
}
menu_setprop(menu, MPROP_EXITNAME, "\rIesi")
menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
menu_display(id, menu, 0)
return PLUGIN_HANDLED;
}
public hand_pistol_menu(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_destroy(menu)
open_vipmenu(id)
return PLUGIN_HANDLED
}
new data[6], iName[64], access, callback
menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
new key = str_to_num(data)
if(1 <= key <= 6)
{
i_pistol[id] = key
if(is_user_alive(id)) if(get_gametime() <= time_open_to_menu) give_my_pistol(id)
open_vipmenu(id)
}
return PLUGIN_HANDLED;
}
public open_armor_menu(id)
{
new menu = menu_create("\rAlege armura\y:\w", "hand_armor_menu")
for (new n = 1; n <= 3; n++)
{
new Number[4]
formatex(Number, charsmax(Number), "%i", n)
menu_additem(menu, armor_names[n-1], Number, 0)
}
menu_setprop(menu, MPROP_EXITNAME, "\rIesi")
menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
menu_display(id, menu, 0)
return PLUGIN_HANDLED;
}
public hand_armor_menu(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_destroy(menu)
open_vipmenu(id)
return PLUGIN_HANDLED
}
new data[6], iName[64], access, callback
menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
new key = str_to_num(data)
if(1 <= key <= 3)
{
i_armor[id] = key - 1
if(is_user_alive(id)) give_my_armor(id)
open_vipmenu(id)
}
return PLUGIN_HANDLED;
}
public open_nade_menu(id)
{
new menu = menu_create("\rAlege grenade\y:\w", "hand_grenade_menu")
for (new n = 1; n <= 6; n++)
{
new Number[4]
formatex(Number, charsmax(Number), "%i", n)
menu_additem(menu, nade_names[n-1], Number, 0)
}
menu_setprop(menu, MPROP_EXITNAME, "\rIesi")
menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
menu_display(id, menu, 0)
return PLUGIN_HANDLED;
}
public hand_grenade_menu(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_destroy(menu)
open_vipmenu(id)
return PLUGIN_HANDLED
}
new data[6], iName[64], access, callback
menu_item_getinfo(menu, item, access, data, 5, iName, 63, callback)
new key = str_to_num(data)
if(1 <= key <= 6)
{
i_nades[id] = key - 1
// if(is_user_alive(id)) give_my_grenades(id)
open_vipmenu(id)
}
return PLUGIN_HANDLED;
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public give_primary_weapon(id, num)
{
switch(num)
{
case 1:
{
remove_primary(id)
rg_give_item(id, "weapon_awp")
rg_set_user_bpammo(id, WEAPON_AWP, 30)
if(!get_pcvar_num(cvar_chat_show)) return;
new name[32]
get_user_name(id, name, 31)
chat_color(0, "%L !g%s !tвзÑл !gAWP !tчерез !gвипменю", id, "VIP_CHAT_PREFIX", name)
}
case 2:
{
remove_primary(id)
rg_give_item(id, "weapon_ak47")
rg_set_user_bpammo(id, WEAPON_AK47, 90)
if(!get_pcvar_num(cvar_chat_show)) return;
new name[32]
get_user_name(id, name, 31)
chat_color(0, "%L !g%s !tвзÑл !gAK47 !tчерез !gвипменю", id, "VIP_CHAT_PREFIX", name)
}
case 3:
{
remove_primary(id)
rg_give_item(id, "weapon_m4a1")
rg_set_user_bpammo(id, WEAPON_M4A1, 90)
if(!get_pcvar_num(cvar_chat_show)) return;
new name[32]
get_user_name(id, name, 31)
chat_color(0, "%L !g%s !tвзÑл !gM4A1 !tчерез !gвипменю", id, "VIP_CHAT_PREFIX", name)
}
case 4:
{
remove_primary(id)
rg_give_item(id, "weapon_famas")
rg_set_user_bpammo(id, WEAPON_FAMAS, 90)
if(!get_pcvar_num(cvar_chat_show)) return;
new name[32]
get_user_name(id, name, 31)
chat_color(0, "%L !g%s !tвзÑл !gFAMAS !tчерез !gвипменю", id, "VIP_CHAT_PREFIX", name)
}
}
}
public give_my_pistol(id)
{
remove_secondary(id)
rg_give_item(id, pistols_entnames[i_pistol[id]])
switch(i_pistol[id])
{
case 1: rg_set_user_bpammo(id, WEAPON_GLOCK18, bpammo_pistol[i_pistol[id]])
case 2: rg_set_user_bpammo(id, WEAPON_USP, bpammo_pistol[i_pistol[id]])
case 3: rg_set_user_bpammo(id, WEAPON_P228, bpammo_pistol[i_pistol[id]])
case 4: rg_set_user_bpammo(id, WEAPON_DEAGLE, bpammo_pistol[i_pistol[id]])
case 5: rg_set_user_bpammo(id, WEAPON_FIVESEVEN, bpammo_pistol[i_pistol[id]])
case 6: rg_set_user_bpammo(id, WEAPON_ELITE, bpammo_pistol[i_pistol[id]])
}
}
public give_my_armor(id)
{
switch(i_armor[id])
{
case 1: rg_set_user_armor(id, 100, ARMOR_KEVLAR)
case 2: rg_set_user_armor(id, 100, ARMOR_VESTHELM)
}
}
public give_my_grenades(id)
{
if(i_nades[id] == 0)
return;
if(i_round_grenades[id] <= 0)
return;
switch(i_nades[id])
{
case 1:
{
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_hegrenade")
}
case 2:
{
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
}
case 3:
{
rg_give_item(id, "weapon_hegrenade")
}
case 4:
{
rg_give_item(id, "weapon_hegrenade")
}
case 5:
{
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_hegrenade")
}
}
i_round_grenades[id]--
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public remove_primary(id)
{
for(new i = 0; i < 18; i++)
{
fm_strip_user_gun(id, primary[i])
}
}
public remove_secondary(id)
{
for(new i = 0; i < 6; i++)
{
fm_strip_user_gun(id, pistols[i])
}
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
public map_check()
{
new got_line, line_num, len
new cfgpath[256], mapname[64], txt[256]
get_mapname(mapname, 63)
format(cfgpath, 256, "addons/amxmodx/configs/vip/maps_block.ini")
if (file_exists(cfgpath))
{
got_line = read_file(cfgpath, line_num, txt, 255, len)
while (got_line>0)
{
if (containi(mapname, txt) != -1)
{
map_blocked = true
return 1
}
line_num++
got_line = read_file(cfgpath, line_num, txt, 255, len)
}
}
return 0
}
stock bool:has_access_vipmenu(id)
{
new u_flags[32]
get_flags(get_user_flags(id), u_flags, 31)
new g_szFlagMenu[32]
get_pcvar_string(cvar_flag, g_szFlagMenu, 31)
return (containi(u_flags,g_szFlagMenu) != -1) ? true : false
}
stock chat_color(const id, const input[], any:...)
{
new count = 1, players[32];
static msg[191];
vformat(msg, 190, input, 3);
replace_all(msg, 190, "!g", "^4"); // Green Color
replace_all(msg, 190, "!y", "^1"); // Default Color
replace_all(msg, 190, "!t", "^3"); // Team Color
if (id) players[0] = id; else get_players(players, count, "ch");
{
for ( new i = 0; i < count; i++ )
{
if ( is_user_connected(players[i]) )
{
message_begin(MSG_ONE_UNRELIABLE, g_msg_SayText, _, players[i]);
write_byte(players[i]);
write_string(msg);
message_end();
}
}
}
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
///////////////////////////////////////////////////////////
// ///
// Ðвтор плагина - Leo_[BH] ///
// http://vk.com/id64427766 ///
// Skype: bcnl_leon ///
// ///
// Другие мои плагины: ///
// http://vk.com/cs_rain ///
// ///
///////////////////////////////////////////////////////////
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
I know it's menu related but idk what's the fix to it