PDA

View Full Version : Admin Menu Models Help[Counter Strike 1.6]


Twinz
04-19-2017, 08:54
Then, I having a problem with this plugin I put the models where they needed to be, I wrote the name of the plugin in the plugins.ini but still its doesn't work, can someone fix it or tell me what is wrong? here is the SMA Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <colorchat>


#define PLUGIN "Admin Model Menu"
#define VERSION "1.0"
#pragma tabsize 0
#define AUTHOR "Aykou"

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /models", "ADMIN_ALL")
}

public plugin_precache()
{
precache_model("models/player/admin/CT/AnyonymusCT.mdl")
precache_model("models/player/admin/CT/ArctricModelCT.mdl")
precache_model("models/player/admin/CT/PerfectVectorCT.mdl")
precache_model("models/player/admin/TT/KillerTT.mdl")
precache_model("models/player/admin/TT/AssassinTT.mdl")
precache_model("models/player/admin/TT/RedSpidermanTT.mdl")
}

public admin(id)
{
if (get_user_flags(id) & ADMIN_KICK)
{
model_menu(id)
}
else
{
ColorChat(id, GREEN, "**Error-Menu Tylko Dla Admina**")
}

}
public model_menu(id)
{
new menu = menu_create("\rAdmin Model Menu", "menu_wybierz")

menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "1", 0)
menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "2", 0)
menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "3", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "4", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "5", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "6", 0)


menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)

menu_display(id, menu, 0)
}

public menu_wybierz(id, menu, item)
{
if (item == MENU_EXIT)
{
menu_destroy(menu)
return PLUGIN_HANDLED
}
new data[6], iName[64]
new acces, callback
menu_item_getinfo(menu, item, acces, data,5, iName, 63, callback)

new key = str_to_num(data)

switch(key)
{
case 1 : cs_set_user_model(id, "AnyonymusCT")
case 2 : cs_set_user_model(id, "ArctricModelCT")
case 3 : cs_set_user_model(id, "PerfectVectorCT")
case 4 : cs_set_user_model(id, "KillerTT")
case 5 : cs_set_user_model(id, "AssassinTT")
case 6 : cs_set_user_model(id, "RedSpidermanTT")
}
menu_destroy(menu)
return PLUGIN_HANDLED
}

Adomaz1
04-19-2017, 14:11
this is the new plugin submission forum, not the scripting help

OciXCrom
04-19-2017, 14:18
models/player/MODEL_NAME/MODEL_NAME.mdl

PS: that plugin is shit.

VINAGHOST
04-20-2017, 01:04
Then, I having a problem with this plugin I put the models where they needed to be, I wrote the name of the plugin in the plugins.ini but still its doesn't work, can someone fix it or tell me what is wrong? here is the SMA Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <colorchat>


#define PLUGIN "Admin Model Menu"
#define VERSION "1.0"
#pragma tabsize 0
#define AUTHOR "Aykou"

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /models", "ADMIN_ALL")
}

public plugin_precache()
{
precache_model("models/player/admin/CT/AnyonymusCT.mdl")
precache_model("models/player/admin/CT/ArctricModelCT.mdl")
precache_model("models/player/admin/CT/PerfectVectorCT.mdl")
precache_model("models/player/admin/TT/KillerTT.mdl")
precache_model("models/player/admin/TT/AssassinTT.mdl")
precache_model("models/player/admin/TT/RedSpidermanTT.mdl")
}

public admin(id)
{
if (get_user_flags(id) & ADMIN_KICK)
{
model_menu(id)
}
else
{
ColorChat(id, GREEN, "**Error-Menu Tylko Dla Admina**")
}

}
public model_menu(id)
{
new menu = menu_create("\rAdmin Model Menu", "menu_wybierz")

menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "1", 0)
menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "2", 0)
menu_additem(menu, "\wModel \yCT[Zabranjeno TT]", "3", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "4", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "5", 0)
menu_additem(menu, "\wModel \yTT[Zabranjeno CT]", "6", 0)


menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)

menu_display(id, menu, 0)
}

public menu_wybierz(id, menu, item)
{
if (item == MENU_EXIT)
{
menu_destroy(menu)
return PLUGIN_HANDLED
}
new data[6], iName[64]
new acces, callback
menu_item_getinfo(menu, item, acces, data,5, iName, 63, callback)

new key = str_to_num(data)

switch(key)
{
case 1 : cs_set_user_model(id, "AnyonymusCT")
case 2 : cs_set_user_model(id, "ArctricModelCT")
case 3 : cs_set_user_model(id, "PerfectVectorCT")
case 4 : cs_set_user_model(id, "KillerTT")
case 5 : cs_set_user_model(id, "AssassinTT")
case 6 : cs_set_user_model(id, "RedSpidermanTT")
}
menu_destroy(menu)
return PLUGIN_HANDLED
}



can you give me the log of amxx plugins ?

OciXCrom
04-20-2017, 05:07
You don't need any logs. That plugin can't work because the model paths are wrong.