1 Star 0 Fork 121

blog/kbengine

forked from likecg/kbengine 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
bots_interface.hpp 1.98 KB
一键复制 编辑 原始数据 按行查看 历史
liquidx 提交于 2013-01-23 11:10 +08:00 . bots添加addbots方法。
/*
This source file is part of KBEngine
For the latest info, see http://www.kbengine.org/
Copyright (c) 2008-2012 KBEngine.
KBEngine is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
KBEngine is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License
along with KBEngine. If not, see <http://www.gnu.org/licenses/>.
*/
#if defined(DEFINE_IN_INTERFACE)
#undef __BOTS_INTERFACE_H__
#endif
#ifndef __BOTS_INTERFACE_H__
#define __BOTS_INTERFACE_H__
// common include
#if defined(BOTS)
#include "bots.hpp"
#endif
#include "bots_interface_macros.hpp"
#include "network/interface_defs.hpp"
#include "client_lib/common.hpp"
//#define NDEBUG
// windows include
#if KBE_PLATFORM == PLATFORM_WIN32
#else
// linux include
#endif
namespace KBEngine{
/**
Bots所有消息接口在此定义
*/
NETWORK_INTERFACE_DECLARE_BEGIN(BotsInterface)
// 某app主动请求look。
BOTS_MESSAGE_DECLARE_ARGS0(lookApp, MERCURY_FIXED_MESSAGE)
// 请求关闭服务器
BOTS_MESSAGE_DECLARE_STREAM(reqCloseServer, MERCURY_VARIABLE_MESSAGE)
// console远程执行python语句。
BOTS_MESSAGE_DECLARE_STREAM(onExecScriptCommand, MERCURY_VARIABLE_MESSAGE)
// 某个app向本app告知处于活动状态。
BOTS_MESSAGE_DECLARE_ARGS2(onAppActiveTick, MERCURY_FIXED_MESSAGE,
COMPONENT_TYPE, componentType,
COMPONENT_ID, componentID)
// 添加bots。
BOTS_MESSAGE_DECLARE_STREAM(addBots, MERCURY_VARIABLE_MESSAGE)
NETWORK_INTERFACE_DECLARE_END()
#ifdef DEFINE_IN_INTERFACE
#undef DEFINE_IN_INTERFACE
#endif
}
#endif
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/blog/kbengine.git
git@gitee.com:blog/kbengine.git
blog
kbengine
kbengine
0.1.2

搜索帮助