VIP随便换枪摸插件A_A【这玩意最近挺火】
本帖最后由 294421338 于 2013-2-24 23:50 编辑根据点通一个人源码进行了修改
跟久千的差不多一样了A_A
/wq打开 B权限 已开源 又没人看? 去赶作业 帮你顶一下吧 虽然还是喜欢GHW的 嘿,打死你个龟孙。。。。。 hackroad 发表于 2013-2-24 21:52 static/image/common/back.gif
嘿,打死你个龟孙。。。。。
A_A你能再无节操一点吗? 294421338 发表于 2013-2-24 21:56 static/image/common/back.gif
A_A你能再无节操一点吗?
哈哈。。。久千进来开源吧 TAT算了到时候弄个高仿用format做一个A_A 本帖最后由 294421338 于 2013-2-24 23:42 编辑
我还是吧源码发出来吧
#include <amxmodx>
#include <amxmisc>
#include <engine>
new player_flags;
new da,db,dc,dd,de,df
public plugin_init()
{
register_plugin("VIP武器皮肤", "1.0", "不二病后期修改");
register_clcmd( "say /wq","ExtraMenu",ADMIN_KICK)
register_event("HLTV", "event_round_start", "a", "1=0", "2=0")
player_flags = register_cvar("amx_vip_flags","b")
register_event("CurWeapon", "SwitchWeapon", "be", "1=1")
}
public plugin_precache()
{
precache_model("models/v_ak47_vip.mdl");
precache_model("models/v_m4a1_vip.mdl");
precache_model("models/v_awp_vip.mdl");
precache_model("models/v_deagle_vip.mdl");
precache_model("models/v_knife_vip.mdl");
}
public ExtraMenu(id)
{
new menu = menu_create("\r<会员武器皮肤更换菜单>", "menu_handler");
if(da==0) menu_additem(menu, "\r【\y#\r】.按下对应的编号选择菜单^n^n", "0", 0);
else menu_additem(menu, "\r【\y#\r】.按下对应的编号选择菜单^n^n", "0", 0);
if(da==1) menu_additem(menu, "\y黄金AK皮肤|\d普通AK皮肤", "1", 0);
else menu_additem(menu, "\d黄金AK皮肤|\y普通AK皮肤", "1", 0);
if(db==2) menu_additem(menu, "\y黄金M4皮肤|\d普通M4皮肤", "2", 0);
else menu_additem(menu, "\d黄金M4皮肤|\y普通M4皮肤", "2", 0);
if(dc==3) menu_additem(menu, "\y黄金大狙皮肤|\d普通大狙皮肤", "3", 0);
else menu_additem(menu, "\d黄金大狙皮肤|\y普通大狙皮肤", "3", 0);
if(dd==4) menu_additem(menu, "\y黄金沙鹰皮肤|\d普通沙鹰皮肤", "4", 0);
else menu_additem(menu, "\d黄金沙鹰皮肤|\y普通沙鹰皮肤", "4", 0);
if(df==5) menu_additem(menu, "\y黄金背刺皮肤|\d普通刀子皮肤", "6", 0);
else menu_additem(menu, "\d黄金背刺皮肤|\y普通刀子皮肤", "6", 0);
menu_setprop(menu, MPROP_EXIT, MEXIT_ALL);
menu_display(id, menu, 0);
return PLUGIN_HANDLED;
}
public menu_handler(id, menu, item)
{
if( item == MENU_EXIT )
{
menu_destroy(menu);
return PLUGIN_HANDLED;
}
new data, iName;
new access, callback;
menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
new key = str_to_num(data);
switch(key)
{
case 1:
{
if(da==0) da=1
else da=0
client_print(id, print_chat,"【服务器】您的AK47皮肤已经更换")
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
case 2:
{
if(db==0) db=2
else db=0
client_print(id, print_chat,"【服务器】您的M4A1皮肤已经更换")
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
case 3:
{
if(dc==0) dc=3
else dc=0
client_print(id, print_chat,"【服务器】您的大狙皮肤已经更换")
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
case 4:
{
if(dd==0) dd=4
else dd=0
client_print(id, print_chat,"【服务器】您的沙鹰皮肤已经更换")
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
case 6:
{
if(df==0) df=5
else df=0
client_print(id, print_chat,"【服务器】您的刀子皮肤已经更换")
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
}
menu_destroy(menu); // 消除选单
return PLUGIN_HANDLED; // 离开插件
}
public event_round_start() {
client_print(0, print_chat, "本插件使用CS1.6爱好者群主开发的菜单生成器制成,按y输入/wq打开菜单或者在控制台输入say /wq打开菜单")
}
public SwitchWeapon(id)
{
new needaccess;
get_pcvar_string(player_flags, needaccess, 31);
if(get_user_flags(id) & read_flags(needaccess) == 0)
return;
static iwpn, clip, ammo;
iwpn = get_user_weapon(id, clip, ammo);
switch(iwpn)
{
case CSW_AK47:
{
if(da==0){
entity_set_string(id, EV_SZ_viewmodel, "models/v_ak47.mdl");
entity_set_string(id, EV_SZ_weaponmodel, "models/p_ak47.mdl");
}
else{
entity_set_string(id, EV_SZ_viewmodel, "models/v_ak47_vip.mdl");
}
}
case CSW_M4A1:
{
if(db==0){
entity_set_string(id, EV_SZ_viewmodel, "models/v_m4a1.mdl");
entity_set_string(id, EV_SZ_weaponmodel, "models/p_m4a1.mdl");
}
else{
entity_set_string(id, EV_SZ_viewmodel, "models/v_m4a1_vip.mdl");
}
}
case CSW_AWP:
{
if(dc==0){
entity_set_string(id, EV_SZ_viewmodel, "models/v_awp.mdl");
entity_set_string(id, EV_SZ_weaponmodel, "models/p_awp.mdl");
}
else{
entity_set_string(id, EV_SZ_viewmodel, "models/v_awp_vip.mdl");
}
}
case CSW_DEAGLE:
{
if(dd==0){
entity_set_string(id, EV_SZ_viewmodel, "models/v_deagle.mdl");
entity_set_string(id, EV_SZ_weaponmodel, "models/p_deagle.mdl");
}
else{
entity_set_string(id, EV_SZ_viewmodel, "models/v_deagle_vip.mdl");
}
}
case CSW_KNIFE:
{
if(df==0){
entity_set_string(id, EV_SZ_viewmodel, "models/v_knife.mdl");
entity_set_string(id, EV_SZ_weaponmodel, "models/p_knife.mdl");
}
else{
entity_set_string(id, EV_SZ_viewmodel, "models/v_knife_vip.mdl");
}
}
}
}
有源码,赞一个
页:
[1]
2