Участник
Пользователь
- Сообщения
- 460
- Реакции
- 68
- Помог
- 7 раз(а)
Всем привет помогите розобратся.
Слепил плагин. Компилится но не работает.
P.S не скриптер просто попытки.
Слепил плагин. Компилится но не работает.
C++:
[ 46] unknown unknown unknown weaponmenu.amxx bad load
( 46) Load fails: Plugin file open error (plugin "weaponmenu.amxxx")
C++:
#include <amxmodx>
#include <reapi>
#if (AMXX_VERSION_NUM < 183)
#include <colorchat>
#endif
new round_number
public plugin_init()
{
register_plugin("Weaponmenu", "1.0", "HARDCORE")
register_clcmd("weaponmenu", "weaponmenu")
register_clcmd("say /wpn", "weaponmenu")
register_clcmd("say wpn", "weaponmenu")
register_clcmd("say_team /wpn", "weaponmenu")
register_clcmd("say_team wpn", "weaponmenu")
register_event("HLTV", "event_round_start", "a", "1=0", "2=0")
}
public event_round_start ( )
{
round_number++
}
public weaponmenu(id)
{
if(get_user_flags(id) & ADMIN_RCON)
{
new menu = menu_create("\rОружейка", "menu_handler");
menu_additem(menu, "\yВзять \w[\rAWP+USP+ Набор гранат\w]", "1");
menu_additem(menu, "\yВзять \w[\rAK-47+USP+Набор гранат\w]", "2");
menu_additem(menu, "\yВзять \w[\rM4A1+USP+Набор гранат\w]", "3");
menu_additem(menu, "\yВзять \w[\rScout+USP+Набор гранат\w]", "4");
menu_additem(menu, "\yВзять \w[\rM249+Deagle+Набор гранат\w]", "5");
menu_additem(menu, "\yВзять \w[\rUSP+Набор гранат\w]", "6");
menu_setprop(menu, MPROP_EXITNAME, "\rВыход");
menu_display(id, menu, 0)
}
else
{
client_print_color(id, print_chat, "^4[Оружейка] ^1Это меню только для ^4Админ ^1игроков")
}
return PLUGIN_HANDLED;
}
public menu_handler(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, 64, callback)
new key = str_to_num(data)
switch(key)
{
case 1:
{
rg_give_item(id, "weapon_awp")
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_set_user_bpammo(id, WEAPON_AWP, 20)
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
case 2:
{
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_give_item(id, "weapon_ak47")
rg_set_user_bpammo(id, WEAPON_AK47, 90)
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
case 3:
{
rg_give_item(id, "weapon_m4a1")
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_set_user_bpammo(id, WEAPON_M4A1, 90)
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
case 4:
{
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_give_item(id, "weapon_scout")
rg_set_user_bpammo(id, WEAPON_SCOUT, 30)
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
case 5:
{
rg_give_item(id, "weapon_m249")
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_set_user_bpammo(id, WEAPON_M249, 200)
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
case 6:
{
rg_give_item(id, "weapon_usp")
rg_give_item(id, "weapon_hegrenade")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_flashbang")
rg_give_item(id, "weapon_smokegrenade")
rg_set_user_bpammo(id, WEAPON_USP, 90)
}
}
return PLUGIN_HANDLED;
}