|
发表于 2010-4-16 10:01:09
|
显示全部楼层
来自 中国–福建–莆田
本帖最后由 only33 于 2010-4-16 10:14 编辑
如你描述,单纯R3,无刷比赛配置,我发个给你参考吧,代码是截取自乌龟斑竹最强大的比赛插件,1.8.1+METAMOD 1.19-P32+3647和4554环境下均测试无误。没什么技术含量。
==========================
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <hamsandwich>
#include <fakemeta>
#define PLUGIN_NAME "re3"
#define PLUGIN_VERSION "1.0"
#define PLUGIN_AUTHOR "PubMaster b3AR"
public plugin_init()
{
register_plugin(PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR)
register_dictionary("re3.txt")
register_concmd("re3", "fm_re3", ADMIN_KICK)
}
public fm_re3(id, level, cid)
{
if (!cmd_access(id, level, cid, 1))
return PLUGIN_HANDLED
new msg[128]
format(msg, 127, "^x04 ^x01%L", LANG_SERVER, "R_START")
client_color( 0,print_chat, msg)
set_task(1.0,"rr_1")
return PLUGIN_HANDLED
}
public rr_1()
{
new msg[128]
format(msg, 127, "^x04 ^x01%L", LANG_SERVER, "R_1")
client_color( 0,print_chat, msg)
server_cmd ("sv_restartround 1")
set_task(2.0,"rr_2")
}
public rr_2()
{
new msg[128]
format(msg, 127, "^x04 ^x01%L", LANG_SERVER, "R_2")
client_color( 0,print_chat, msg)
server_cmd ("sv_restartround 2")
set_task(3.0,"rr_3")
}
public rr_3()
{
new msg[128]
format(msg, 127, "^x04 ^x01%L", LANG_SERVER, "R_3")
client_color( 0,print_chat, msg)
server_cmd ("sv_restartround 3")
set_task(4.0,"rr_go")
}
public rr_go()
{
new msg[128]
format(msg, 127, "^x04 ^x01%L", LANG_SERVER, "R_GO")
client_color( 0,print_chat, msg)
}
public client_color(playerid, colorid, msg[])
{
message_begin(playerid?MSG_ONE:MSG_ALL,get_user_msgid("SayText"),_,playerid)
write_byte(colorid)
write_string(msg)
message_end()
}
===================
附件里有两个文件,re3.amxx 和 re3.txt
====================
使用方法:
re3.amxx -------- addons\amxmodx\plugins\
re3.txt ---------addons\amxmodx\data\lang\
addons\amxmodx\configs\plugins.ini 添加re3.amxx
=====================
执行方法:
客户端输入OP后控制台,rcon re3 |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?注个册吧
×
|