123 lines
3.9 KiB
Erlang
123 lines
3.9 KiB
Erlang
|
|
%%%-------------------------------------------------------------------
|
||
|
|
%%% @author panhao
|
||
|
|
%%% @copyright (C) 2017, <COMPANY>
|
||
|
|
%%% @doc
|
||
|
|
%%%
|
||
|
|
%%% @end
|
||
|
|
%%% Created : 28. 二月 2017 10:42
|
||
|
|
%%%-------------------------------------------------------------------
|
||
|
|
-module(proto_112).
|
||
|
|
|
||
|
|
%% API
|
||
|
|
|
||
|
|
-export([
|
||
|
|
info/0
|
||
|
|
,cfg/0
|
||
|
|
]
|
||
|
|
).
|
||
|
|
-include("protocol.hrl").
|
||
|
|
|
||
|
|
info() -> {
|
||
|
|
""
|
||
|
|
,["formation.hrl"]
|
||
|
|
}.
|
||
|
|
|
||
|
|
cfg() ->
|
||
|
|
[
|
||
|
|
#rpc{
|
||
|
|
code = 11200
|
||
|
|
,log_title = "请求自身阵法"
|
||
|
|
,req_desc = "请求自身阵法"
|
||
|
|
,req = []
|
||
|
|
,reply = [
|
||
|
|
{rec, base_info, formation_base_p, ?p_g_set(formation_base_p, [
|
||
|
|
{uint8, id, "当前使用阵法"}
|
||
|
|
,{array, formation_pos, pos_info, "站位", [
|
||
|
|
{uint8, pos, "阵位"}
|
||
|
|
,{uint8, id, "伙伴id"}
|
||
|
|
]}
|
||
|
|
,{array, single, formation_list, "已学会阵法", [
|
||
|
|
{uint8, id, "阵法ID"}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
,{uint32, hallows_id, "使用的圣器id"}
|
||
|
|
])}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
,#rpc{
|
||
|
|
code = 11201
|
||
|
|
,log_title = "更换自身阵法(更换成功推送11200)"
|
||
|
|
,req_desc = "更换自身阵法(更换成功推送11200)"
|
||
|
|
,req = [
|
||
|
|
{uint8, id, "阵法id"}
|
||
|
|
,{array, tuple, pos_info, "站位", [
|
||
|
|
{uint8, pos, "阵位"}
|
||
|
|
,{uint8, id, "伙伴id"}
|
||
|
|
]}
|
||
|
|
,{uint32, hallows_id, "使用的圣器id(没有传0)"}
|
||
|
|
]
|
||
|
|
,reply = [
|
||
|
|
{uint8, flag, "是否成功"}
|
||
|
|
,{string, msg, "提示语"}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
,#rpc{
|
||
|
|
code = 11211
|
||
|
|
,log_title = "功能阵法信息"
|
||
|
|
,req_desc = "功能阵法信息"
|
||
|
|
,req = [
|
||
|
|
{uint8, type, "功能类型"}
|
||
|
|
]
|
||
|
|
,reply = [
|
||
|
|
{uint8, type, "功能类型"}
|
||
|
|
,{uint8, formation_type, "阵法类型"}
|
||
|
|
,{array, formation_pos, pos_info, "站位信息", [
|
||
|
|
{uint8, pos, "位置"}
|
||
|
|
,{uint32, id, "伙伴ID"}
|
||
|
|
]}
|
||
|
|
,{uint32, hallows_id, "使用的圣器id(没有传0)"}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
,#rpc{
|
||
|
|
code = 11212
|
||
|
|
,log_title = "设置功能阵法"
|
||
|
|
,req_desc = "设置功能阵法"
|
||
|
|
,req = [
|
||
|
|
{uint8, type, "功能类型"}
|
||
|
|
,{uint8, formation_type, "阵法类型"}
|
||
|
|
,{array, tuple, pos_info, "站位信息", [
|
||
|
|
{uint8, pos, "位置"}
|
||
|
|
,{uint32, id, "伙伴ID"}
|
||
|
|
]}
|
||
|
|
,{uint32, hallows_id, "使用的圣器id"}
|
||
|
|
]
|
||
|
|
,reply = [
|
||
|
|
{uint8, code, "标志(0:失败 1:成功)"}
|
||
|
|
,{string, msg, "提示信息"}
|
||
|
|
,{uint8, type, "功能类型"}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
,#rpc{
|
||
|
|
code = 11213
|
||
|
|
,log_title = "多阵法信息"
|
||
|
|
,req_desc = "多阵法信息"
|
||
|
|
,req = [
|
||
|
|
{array, single, type_list, "功能类型", [
|
||
|
|
{uint8, type, "功能类型"}
|
||
|
|
]}
|
||
|
|
]
|
||
|
|
,reply = [
|
||
|
|
{array, tuple, info, "类型", [
|
||
|
|
{uint8, type, "功能类型"}
|
||
|
|
,{uint8, formation_type, "阵法类型"}
|
||
|
|
,{array, formation_pos, pos_info, "站位信息", [
|
||
|
|
{uint8, pos, "位置"}
|
||
|
|
,{uint32, id, "伙伴ID"}
|
||
|
|
]}
|
||
|
|
,{uint32, hallows_id, "使用的圣器id(没有传0)"}
|
||
|
|
]}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
|
||
|
|
].
|