230 lines
5.4 KiB
Protocol Buffer
230 lines
5.4 KiB
Protocol Buffer
|
||
package com.ljsd.jieling.protocols;
|
||
|
||
option optimize_for = SPEED;
|
||
|
||
// 嵌套的proto 必须在当前 proto 之前声明
|
||
|
||
message ErrorResponse{
|
||
optional int32 errCode =1 ; // 错误码,默认为0
|
||
optional string errMsg =2 ; // 错误信息
|
||
}
|
||
|
||
message Player{
|
||
optional int32 uid = 1;
|
||
optional string nickName = 2;
|
||
optional int32 level = 3;
|
||
optional int32 exp = 4;
|
||
optional int32 vipLevel = 5;
|
||
optional string familyId = 6;
|
||
optional string head = 7;
|
||
optional int32 curMapId = 8;
|
||
|
||
optional int32 energy = 9; //精力
|
||
optional int32 lastUpdateEnergyTime = 10 ;// 上次更新精力时间,-1 代表在队伍中,不需要进行定时恢复。
|
||
|
||
optional int32 serverTime = 11; //服务器时间
|
||
optional int32 dayFightCount = 12; // 副本今日已战斗次数
|
||
optional int32 buyFightCount = 13; // 今日已购买挑战次数
|
||
}
|
||
|
||
|
||
message Item{
|
||
optional int32 itemId = 1;
|
||
optional int32 itemNum = 2;
|
||
optional int32 endingTime = 3;
|
||
}
|
||
|
||
|
||
message SpecialEffects{
|
||
optional int32 propertyId = 1;
|
||
optional int32 propertyValue = 2;
|
||
}
|
||
|
||
|
||
|
||
message Equip{
|
||
optional string id = 1;
|
||
optional int32 equipId = 2;
|
||
optional SpecialEffects mainAttribute = 3;
|
||
repeated SpecialEffects secondAttribute = 4;
|
||
}
|
||
|
||
|
||
message Hero{
|
||
optional string id = 1;
|
||
optional int32 heroId = 2;
|
||
optional int32 level = 3;
|
||
optional int32 breakId = 4;
|
||
optional int32 star = 5;
|
||
optional int32 skinId = 6;
|
||
|
||
repeated int32 skillIdList = 7;
|
||
repeated string equipIdList = 8;
|
||
|
||
optional int32 createTime = 9; //入手时间
|
||
|
||
}
|
||
|
||
message FightUnitInfo {
|
||
optional string unitId = 1;//单位静态id
|
||
optional string unitSkillIds = 2;//点技#滑技#被动技能1#被动技能2#被动技能3....
|
||
optional string property = 3;//1#2390#2390#169#271#95#176#0#0#0.3#0.15#0.3#1.5#1#0.05#0#0#0#0#0#0.05#0#0#0#0#0
|
||
}
|
||
|
||
|
||
message FightTeamInfo {
|
||
repeated FightUnitInfo fightUnitList = 1;
|
||
optional string teamSkillList = 2;//异妖(队伍技能)技能1#技能2#技能3
|
||
}
|
||
|
||
|
||
message EventBehaviorValues{
|
||
repeated int32 behaviorValues = 1;
|
||
}
|
||
// 事件行为结果
|
||
message EventBehaviorCommon{
|
||
// 行为类型
|
||
optional int32 behaviorType = 1;
|
||
// 行为参数
|
||
repeated EventBehaviorValues eventBehaviorValues = 2;
|
||
}
|
||
|
||
|
||
|
||
// 地图每个格子的信息
|
||
message Cell{
|
||
// 格子id
|
||
optional int32 cellId = 1;
|
||
// mapPointConfig id
|
||
optional int32 pointId = 2;
|
||
}
|
||
|
||
|
||
message Mission{
|
||
optional int32 itemId = 1;
|
||
optional string state = 2;
|
||
optional int32 missionStep = 3;
|
||
// 完成任务所用时间(秒)
|
||
optional int32 time = 4;
|
||
}
|
||
|
||
|
||
message Mail{
|
||
optional string mailId = 1;
|
||
optional int32 state = 2; //0:未读 1:已读取 2: 未领取 3 已领取
|
||
optional string head = 3;
|
||
optional string content = 4;
|
||
optional string mailItem = 5; //附件
|
||
optional int32 sendTime = 6;
|
||
optional int32 effectiveTime = 7; // 秒 0:永久有效
|
||
optional string sendName = 8 ; //发送者名字
|
||
optional int32 mailType = 9; //邮件类型 1:系统邮件 2:idip 业务邮件
|
||
|
||
}
|
||
|
||
|
||
message Drop{
|
||
repeated Item itemlist = 1;
|
||
repeated Equip equipId = 2;
|
||
repeated Hero Hero = 3;
|
||
}
|
||
|
||
message GMCommand{
|
||
optional string command =1 ; // 指令字符串 type#prarm1#param2
|
||
}
|
||
|
||
message AdventureStateInfo{
|
||
optional int32 positionId = 1; // 区域编号
|
||
repeated string heroIdList =2 ; // 驻扎英雄id
|
||
optional int32 startTime = 3 ; //开始时间
|
||
}
|
||
|
||
message AdventureRecommendHeroInfo{
|
||
optional int32 positionId = 1; // 区域编号
|
||
repeated int32 recommenedId =2 ; // 推荐英雄
|
||
}
|
||
|
||
message TeamHeroInfo{
|
||
optional int32 position =1;
|
||
optional string heroId = 2;
|
||
}
|
||
|
||
message TeamPokemonInfo{
|
||
optional int32 position =1;
|
||
optional int32 pokemonId = 2;
|
||
}
|
||
|
||
message TeamPosInfo{
|
||
optional int32 teamId = 1; //第几编队
|
||
optional string teamName =2; //编码名称
|
||
repeated TeamHeroInfo teamHeroInfos = 3; //队伍英雄id
|
||
repeated TeamPokemonInfo teamPokemonInfos = 4; // 异妖id
|
||
}
|
||
|
||
message Pokemoncomonpent{
|
||
optional int32 id =1;
|
||
optional int32 level =2;
|
||
}
|
||
|
||
message PokemonInfo{
|
||
optional int32 id = 1; //异妖id
|
||
optional int32 stage =2; //异妖进阶阶数
|
||
repeated Pokemoncomonpent pokemoncomonpent =3; //组件信息
|
||
}
|
||
message WorkShopBaseInfo{
|
||
optional int32 type =1; // 1: 工坊 2:百味居
|
||
optional int32 levle =2 ;
|
||
optional int32 exp =3;
|
||
}
|
||
message WorkShopUnLockInfo{
|
||
optional int32 type =1 ; // 类型 1: 基础锻造 2: 装备打造
|
||
repeated int32 id =4 ; // 蓝图已经解锁的id
|
||
}
|
||
|
||
|
||
message FightData {
|
||
// 战斗属性
|
||
optional FightTeamInfo heroFightInfos = 1;
|
||
// 怪物属性
|
||
repeated FightTeamInfo monsterList = 2;
|
||
//战斗随机种子
|
||
optional int32 fightSeed = 3;
|
||
}
|
||
|
||
message ExploreDetail{
|
||
optional int32 id =1;
|
||
optional int32 progress =2 ; //进度
|
||
}
|
||
|
||
message FoodBuffer {
|
||
optional int32 bufferId = 1;
|
||
optional int32 leftStep = 2;
|
||
}
|
||
|
||
message NewPlayerGuidePoint{
|
||
optional int32 type = 1;
|
||
optional int32 id =2;
|
||
}
|
||
|
||
message LevelDifficulty{
|
||
optional int32 fightId = 1;
|
||
optional int32 state = 2; //2 已开启 3:已打过未通过,=4:已通过
|
||
optional int32 num = 3;
|
||
optional int32 type = 4; //1:简单 2:中等 3:困难
|
||
}
|
||
|
||
message LevelDifficultyInfos{
|
||
optional int32 areaId = 1;
|
||
repeated LevelDifficulty LevelDifficulty = 2;
|
||
}
|
||
|
||
// 副本信息
|
||
message MapInfo {
|
||
optional int32 mapId = 1;
|
||
// 最少时间
|
||
optional int32 leastTime = 2;
|
||
// 所得星数 (1:完成任务 2:时间小于指定时间 3:100% 探索度)
|
||
repeated int32 stars = 3;
|
||
}
|