|
发表于 2009-9-27 12:40:21
|
显示全部楼层
来自 中国–江苏–南京
14# ken19971030 - /* 本插件由 AMXX-Studio 中文版自动生成 */
- /* UTF-8 func by www.DT-Club.net */
- #include <amxmodx>
- #include <amxmisc>
- #define PLUGIN_NAME "New Plug-In"
- #define PLUGIN_VERSION "1.0"
- #define PLUGIN_AUTHOR "suli"
- public plugin_init()
- {
- register_plugin(PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR);
-
- register_clcmd("say","cmd_say",-1," - say")
-
- // 在此处添加您的代码...
- }
- public cmd_say(id){
-
- new a_text[64],p_name[32],p_message[128]
- read_args (a_text,63)
- remove_quotes(a_text)
- get_user_name(id,p_name,31)
- if ((get_user_flags(id) & ADMIN_LEVEL_A)){//管理员提示
- format(p_message,127,"^x04[OP]^x03%s^x01:%s",p_name,a_text)
- client_color(0,id,p_message)
-
- }else if((get_user_flags(id) & ADMIN_VOTE)){//VIP提示
- format(p_message,127,"^x04[VIP]^x03%s^x01:%s",p_name,a_text)
- client_color(0,id,p_message)
-
- }
- return PLUGIN_CONTINUE
- }
- public client_color(playerid, colorid, msg[])
- {
- message_begin(playerid?MSG_ONE:MSG_ALL,get_user_msgid("SayText"),{0,0,0},playerid)
- write_byte(colorid)
- write_string(msg)
- message_end()
- }
复制代码 |
|