我有个 任务失败 处死的源码 谁帮忙改下 谢谢了
现在死亡后是在聊天列表 显示 任务失败处死能不能修改成 在界面上显示 就像amxx中间显示的欢迎信息样
显示的位置 您感觉在哪比较好点 我见过在右侧中间显示的
还有就是能不能改成 死亡人数也不扣除的?? #define PLUGIN"Friends_slaylosers"
#define VERSION "0.3.16"
#define AUTHOR"iG_os"
#include <amxmodx>
#include <amxmisc>
public End_terwin()
{
set_task(1.2,"Kill_losers",2)// 传送输的队伍 CT
return PLUGIN_CONTINUE
}
public End_ctwin()
{
set_task(1.2,"Kill_losers",1)// 传送输的队伍 T
return PLUGIN_CONTINUE
}
public Kill_losers(LoseTeam)
{
if(!get_cvar_num("mp_slaylosers"))
return
new name, team
new numplayers = get_maxplayers()
for
(new i=1; i<=numplayers;i++){
if
(!is_user_connected(i))
continue
team = get_user_team(i)
if
((team==LoseTeam) && (is_user_alive(i))){
get_user_name(i,name,31)
client_cmd(i, "spk ambience/mgun_burst2")//播放机枪声音
client_print(0,print_chat,"<处死任务失败者> %s",name)
user_kill(i,1) //不扣分
//user_kill(i,0) //失败者扣一分
}
}
}
public plugin_init()
{
register_plugin(PLUGIN,VERSION,AUTHOR)
register_event("SendAudio","End_terwin","a","2&%!MRAD_terwin")
register_event("SendAudio","End_ctwin","a","2&%!MRAD_ctwin")
register_cvar("mp_slaylosers","1",FCVAR_SERVER)
} 大家帮忙下啊
自己修改不来了 #define PLUGIN"Friends_slaylosers"
#define VERSION "0.3.16"
#define AUTHOR"iG_os"
#include <amxmodx>
#include <amxmisc>
public End_terwin()
{
set_task(1.2,"Kill_losers",2)// 传送输的队伍 CT
return PLUGIN_CONTINUE
}
public End_ctwin()
{
set_task(1.2,"Kill_losers",1)// 传送输的队伍 T
return PLUGIN_CONTINUE
}
public Kill_losers(LoseTeam)
{
if(!get_cvar_num("mp_slaylosers"))
return
new name, team
new numplayers = get_maxplayers()
for
(new i=1; i<=numplayers;i++){
if
(!is_user_connected(i))
continue
team = get_user_team(i)
if
((team==LoseTeam) && (is_user_alive(i))){
get_user_name(i,name,31)
client_cmd(i, "spk ambience/mgun_burst2")//播放机枪声音
set_hudmessage(49, 179, 113, -1.0, 0.25, 0, 0.01, 15.0, 0.01, 0.01, -1)
show_hudmessage(0,"<处死任务失败者>")
user_kill(i,1) //不扣分
//user_kill(i,0) //失败者扣一分
}
}
}
public plugin_init()
{
register_plugin(PLUGIN,VERSION,AUTHOR)
register_event("SendAudio","End_terwin","a","2&%!MRAD_terwin")
register_event("SendAudio","End_ctwin","a","2&%!MRAD_ctwin")
register_cvar("mp_slaylosers","1",FCVAR_SERVER)
}
改了下 但是有警告,不知道什么原因:'( thank you!
支持LZ 期待能帮忙完全解决下 谢谢8874323 兄弟了 自己做 sam 個吧 就是做不来 想让大家帮助下 顺便对比学习下
麻烦会的出手下了。。 client_print(0,print_chat,"<处死任务失败者> %s",name)改为
client_print(0,print_center,"<处死任务失败者> %s",name)
user_kill(i,1) //不扣分
//user_kill(i,0) //失败者扣一分,改为
//user_kill(i,1) //不扣分
user_kill(i,0) //失败者扣一分 又学习了。。
页:
[1]
2