上传小游戏离线机制
This commit is contained in:
parent
a08417a98c
commit
33ca47e77b
@ -511,7 +511,8 @@ const ( //Rpc
|
|||||||
|
|
||||||
RPC_XXLOffLine core.Rpc_Key = "RPC_XXLOffLine" //三消离线
|
RPC_XXLOffLine core.Rpc_Key = "RPC_XXLOffLine" //三消离线
|
||||||
|
|
||||||
Rpc_AccountBan core.Rpc_Key = "Rpc_AccountBan" // 账号状态
|
Rpc_AccountBan core.Rpc_Key = "Rpc_AccountBan" // 账号状态
|
||||||
|
RPC_GameinviteOffline core.Rpc_Key = "RPC_GameinviteOffline" // 游戏邀请离线通知
|
||||||
)
|
)
|
||||||
|
|
||||||
// 事件类型定义处
|
// 事件类型定义处
|
||||||
|
@ -464,11 +464,13 @@ type (
|
|||||||
//查询战斗数
|
//查询战斗数
|
||||||
QueryBattle(id string) (battle *pb.DBPvpBattle, err error)
|
QueryBattle(id string) (battle *pb.DBPvpBattle, err error)
|
||||||
//创建实时Pvp
|
//创建实时Pvp
|
||||||
CreatePvp(red, blue *pb.PvpUserInfo, ptype pb.PvpType) (battleId string, errdata *pb.ErrorData)
|
CreateRoom(sessions []IUserSession, rulesStr string) (roomid string, err error)
|
||||||
//推送战斗输出指令
|
//推送战斗输出指令
|
||||||
PvpOutCmdPush(out *pb.PvpOutCmdPush)
|
PvpOutCmdPush(out *pb.PvpOutCmdPush)
|
||||||
//推送战斗结束
|
//推送战斗结束
|
||||||
PvpFinishPush(out *pb.BattleFinishPush)
|
PvpFinishPush(out *pb.BattleFinishPush)
|
||||||
|
//用户离线
|
||||||
|
UserOffline(roomid string, uid string) (err error)
|
||||||
}
|
}
|
||||||
|
|
||||||
ISmithy interface {
|
ISmithy interface {
|
||||||
@ -671,10 +673,12 @@ type (
|
|||||||
//游戏邀请
|
//游戏邀请
|
||||||
IDColor interface {
|
IDColor interface {
|
||||||
CreateRoom(sessions []IUserSession, rulesStr string) (roomid string, err error)
|
CreateRoom(sessions []IUserSession, rulesStr string) (roomid string, err error)
|
||||||
|
UserOffline(roomid string, uid string) (err error)
|
||||||
}
|
}
|
||||||
//犬兔大战
|
//犬兔大战
|
||||||
ICanineRabbit interface {
|
ICanineRabbit interface {
|
||||||
CreateRoom(sessions []IUserSession, rulesStr string) (roomid string, err error)
|
CreateRoom(sessions []IUserSession, rulesStr string) (roomid string, err error)
|
||||||
|
UserOffline(roomid string, uid string) (err error)
|
||||||
}
|
}
|
||||||
IEntertainment interface {
|
IEntertainment interface {
|
||||||
// 添加三消卡片资源
|
// 添加三消卡片资源
|
||||||
|
@ -158,3 +158,15 @@ func (this *CanineRabbit) CreateRoom(sessions []comm.IUserSession, rulesStr stri
|
|||||||
go room.GameStart()
|
go room.GameStart()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//用户离线
|
||||||
|
func (this *CanineRabbit) UserOffline(roomid string, uid string) (err error) {
|
||||||
|
var (
|
||||||
|
room *Room
|
||||||
|
)
|
||||||
|
if room, err = this.rooms.queryRoom(roomid); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
err = room.PlayerWin(uid, &pb.CanineRabbitWinReq{Roomid: roomid, Iswin: false})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -162,6 +162,7 @@ func (this *Room) PlayerWin(uid string, handle *pb.CanineRabbitWinReq) (err erro
|
|||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *Room) Broadcast(stype string, msg proto.Message) (err error) {
|
func (this *Room) Broadcast(stype string, msg proto.Message) (err error) {
|
||||||
if err = this.module.SendMsgToSession(string(this.module.GetType()), stype, msg, this.sessions...); err != nil {
|
if err = this.module.SendMsgToSession(string(this.module.GetType()), stype, msg, this.sessions...); err != nil {
|
||||||
this.module.Errorln(err)
|
this.module.Errorln(err)
|
||||||
|
@ -51,6 +51,7 @@ func (this *DColor) Start() (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.gameInvite = module.(comm.IGameInvite)
|
this.gameInvite = module.(comm.IGameInvite)
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -122,3 +123,15 @@ func (this *DColor) CreateRoom(sessions []comm.IUserSession, rulesStr string) (r
|
|||||||
go room.GameStart()
|
go room.GameStart()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//用户离线
|
||||||
|
func (this *DColor) UserOffline(roomid string, uid string) (err error) {
|
||||||
|
var (
|
||||||
|
room *Room
|
||||||
|
)
|
||||||
|
if room, err = this.rooms.queryRoom(roomid); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
err = room.PlayerOffline(uid)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -138,6 +138,60 @@ func (this *Room) PlayerHandle(uid string, handle *pb.DColorHandleReq) (err erro
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (this *Room) PlayerOffline(uid string) (err error) {
|
||||||
|
var (
|
||||||
|
conf *cfg.GameGColorGetfractionData
|
||||||
|
tconf *cfg.GameGColortTmedecayData
|
||||||
|
)
|
||||||
|
endtime := int32(configure.Now().Sub(this.starttime).Seconds())
|
||||||
|
if conf, err = this.module.configure.getGameGColorGetfractionData(int32(this.data.Difficulty)+1, this.data.Repeat, 8); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if tconf, err = this.module.configure.getGameGColortTmedecayData(endtime); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.currside = 3
|
||||||
|
if uid == this.data.Blue.Info.Uid {
|
||||||
|
this.data.Red.Score = int32(math.Floor(float64(conf.Fraction) * float64(tconf.Pro) / float64(1000)))
|
||||||
|
this.data.Blue.Score = this.data.Red.Score / 2
|
||||||
|
} else {
|
||||||
|
this.data.Blue.Score = int32(math.Floor(float64(conf.Fraction) * float64(tconf.Pro) / float64(1000)))
|
||||||
|
this.data.Red.Score = this.data.Red.Score / 2
|
||||||
|
}
|
||||||
|
|
||||||
|
this.data.Red.Integral += this.data.Red.Score
|
||||||
|
this.data.Red.Accruedintegral += this.data.Blue.Score
|
||||||
|
if this.data.Red.Score > this.data.Red.Maxintegral {
|
||||||
|
this.data.Red.Maxintegral = this.data.Red.Score
|
||||||
|
}
|
||||||
|
this.data.Blue.Integral += this.data.Blue.Score
|
||||||
|
this.data.Blue.Accruedintegral += this.data.Blue.Score
|
||||||
|
if this.data.Blue.Score > this.data.Blue.Maxintegral {
|
||||||
|
this.data.Blue.Maxintegral = this.data.Blue.Score
|
||||||
|
}
|
||||||
|
this.module.model.Change(this.data.Red.Info.Uid, map[string]interface{}{
|
||||||
|
"integral": this.data.Red.Integral,
|
||||||
|
"accruedintegral": this.data.Red.Accruedintegral,
|
||||||
|
"maxintegral": this.data.Red.Maxintegral,
|
||||||
|
})
|
||||||
|
this.module.model.Change(this.data.Blue.Info.Uid, map[string]interface{}{
|
||||||
|
"integral": this.data.Blue.Integral,
|
||||||
|
"accruedintegral": this.data.Blue.Accruedintegral,
|
||||||
|
"maxintegral": this.data.Blue.Maxintegral,
|
||||||
|
})
|
||||||
|
if err = this.Broadcast("gameover", &pb.DColorGameOverPush{
|
||||||
|
Winside: this.currside,
|
||||||
|
RedIntegral: this.data.Red.Score,
|
||||||
|
BlueIntegral: this.data.Blue.Score,
|
||||||
|
}); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
}
|
||||||
|
this.module.rooms.removeRoom(this.data.Rid)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
func (this *Room) comparison(results []int32) (allright, halfpair int32) {
|
func (this *Room) comparison(results []int32) (allright, halfpair int32) {
|
||||||
var (
|
var (
|
||||||
resultscolor []int32
|
resultscolor []int32
|
||||||
|
@ -110,6 +110,16 @@ func (this *apiComp) Accept(session comm.IUserSession, req *pb.GameInviteAcceptR
|
|||||||
&pb.GameInviteQiecuonotifyPush{User: comm.GetUserBaseInfo(user), NotifyType: 2, Gtype: req.Gtype}, req.Uid)
|
&pb.GameInviteQiecuonotifyPush{User: comm.GetUserBaseInfo(user), NotifyType: 2, Gtype: req.Gtype}, req.Uid)
|
||||||
|
|
||||||
switch req.Gtype {
|
switch req.Gtype {
|
||||||
|
case 1:
|
||||||
|
if roomid, err = this.module.pvp.CreateRoom(sessions, rules); err != nil {
|
||||||
|
errdata = &pb.ErrorData{
|
||||||
|
Code: pb.ErrorCode_DBError,
|
||||||
|
Title: pb.ErrorCode_DBError.ToString(),
|
||||||
|
Message: err.Error(),
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
break
|
||||||
case 2:
|
case 2:
|
||||||
if roomid, err = this.module.caninerabbit.CreateRoom(sessions, rules); err != nil {
|
if roomid, err = this.module.caninerabbit.CreateRoom(sessions, rules); err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
@ -132,25 +142,27 @@ func (this *apiComp) Accept(session comm.IUserSession, req *pb.GameInviteAcceptR
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
redRecord.Status = 1
|
redRecord.Status = 1
|
||||||
redRecord.Battid = roomid
|
redRecord.Roomid = roomid
|
||||||
|
redRecord.Spath = fmt.Sprintf("%s/%s", this.module.service.GetType(), this.module.service.GetId())
|
||||||
gamedata.Member = []string{session.GetUserId(), req.Uid}
|
gamedata.Member = []string{session.GetUserId(), req.Uid}
|
||||||
blueRecord.Status = 1
|
blueRecord.Status = 1
|
||||||
blueRecord.Battid = roomid
|
blueRecord.Roomid = roomid
|
||||||
blueRecord.Invite[redRecord.Gtype] = &pb.GameInviteData{
|
blueRecord.Spath = fmt.Sprintf("%s/%s", this.module.service.GetType(), this.module.service.GetId())
|
||||||
Member: []string{session.GetUserId(), req.Uid},
|
blueRecord.Invite[redRecord.Gtype] = gamedata
|
||||||
Rules: gamedata.Rules,
|
|
||||||
}
|
|
||||||
this.module.model.Change(session.GetUserId(), map[string]interface{}{
|
this.module.model.Change(session.GetUserId(), map[string]interface{}{
|
||||||
"status": 1,
|
"status": redRecord.Status,
|
||||||
|
"gtype": req.Gtype,
|
||||||
"invite": blueRecord.Invite,
|
"invite": blueRecord.Invite,
|
||||||
"battid": blueRecord.Battid,
|
"roomid": blueRecord.Roomid,
|
||||||
|
"spath": blueRecord.Spath,
|
||||||
})
|
})
|
||||||
this.module.model.Change(req.Uid, map[string]interface{}{
|
this.module.model.Change(req.Uid, map[string]interface{}{
|
||||||
"status": 1,
|
"status": blueRecord.Status,
|
||||||
|
"gtype": req.Gtype,
|
||||||
"invite": redRecord.Invite,
|
"invite": redRecord.Invite,
|
||||||
"battid": redRecord.Battid,
|
"roomid": redRecord.Roomid,
|
||||||
|
"spath": redRecord.Spath,
|
||||||
})
|
})
|
||||||
|
|
||||||
session.SendMsg(string(this.module.GetType()), "accept", &pb.GameInviteAcceptResp{
|
session.SendMsg(string(this.module.GetType()), "accept", &pb.GameInviteAcceptResp{
|
||||||
IsSucc: true,
|
IsSucc: true,
|
||||||
})
|
})
|
||||||
|
@ -1,9 +1,13 @@
|
|||||||
package gameinvite
|
package gameinvite
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"context"
|
||||||
|
"fmt"
|
||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
|
"go_dreamfactory/lego/sys/event"
|
||||||
"go_dreamfactory/modules"
|
"go_dreamfactory/modules"
|
||||||
|
"go_dreamfactory/pb"
|
||||||
)
|
)
|
||||||
|
|
||||||
type GameInvite struct {
|
type GameInvite struct {
|
||||||
@ -11,6 +15,7 @@ type GameInvite struct {
|
|||||||
service comm.IService
|
service comm.IService
|
||||||
api *apiComp
|
api *apiComp
|
||||||
model *modelComp
|
model *modelComp
|
||||||
|
pvp comm.IPvp
|
||||||
dcolor comm.IDColor
|
dcolor comm.IDColor
|
||||||
caninerabbit comm.ICanineRabbit
|
caninerabbit comm.ICanineRabbit
|
||||||
}
|
}
|
||||||
@ -41,6 +46,10 @@ func (this *GameInvite) Start() (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
var module core.IModule
|
var module core.IModule
|
||||||
|
if module, err = this.service.GetModule(comm.ModulePvp); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.pvp = module.(comm.IPvp)
|
||||||
if module, err = this.service.GetModule(comm.ModuleDcolor); err != nil {
|
if module, err = this.service.GetModule(comm.ModuleDcolor); err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -49,8 +58,51 @@ func (this *GameInvite) Start() (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.caninerabbit = module.(comm.ICanineRabbit)
|
this.caninerabbit = module.(comm.ICanineRabbit)
|
||||||
|
this.service.RegisterFunctionName(string(comm.RPC_GameinviteOffline), this.trusteeship)
|
||||||
|
event.RegisterGO(comm.EventUserOffline, this.Useroffline)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
func (this *GameInvite) GameInviteEnd(gtype int32, uid string) {
|
func (this *GameInvite) GameInviteEnd(gtype int32, uid string) {
|
||||||
this.model.endQiecuo(gtype, uid)
|
this.model.endQiecuo(gtype, uid)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 用户离线处理
|
||||||
|
func (this *GameInvite) Useroffline(uid, sessionid string) {
|
||||||
|
var (
|
||||||
|
info *pb.GameInviteQiecuoRecord
|
||||||
|
spath string = fmt.Sprintf("%s/%s", this.service.GetType(), this.service.GetId())
|
||||||
|
err error
|
||||||
|
)
|
||||||
|
if info, err = this.model.queryQiecuo(uid); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if info.Status == 1 {
|
||||||
|
if info.Spath == spath {
|
||||||
|
this.trusteeship(context.Background(), &pb.RPC_GameInviteOfflineReq{Gtype: info.Gtype, Roomid: info.Roomid, Offuid: uid}, &pb.RPC_GameInviteOfflineResp{})
|
||||||
|
} else {
|
||||||
|
err = this.service.RpcCall(
|
||||||
|
context.Background(),
|
||||||
|
spath,
|
||||||
|
string(comm.RPC_GameinviteOffline),
|
||||||
|
&pb.RPC_GameInviteOfflineReq{Gtype: info.Gtype, Roomid: info.Roomid, Offuid: uid},
|
||||||
|
&pb.RPC_GameInviteOfflineResp{})
|
||||||
|
if err != nil {
|
||||||
|
this.Errorln(err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 用户离线处理
|
||||||
|
func (this *GameInvite) trusteeship(ctx context.Context, req *pb.RPC_GameInviteOfflineReq, resp *pb.RPC_GameInviteOfflineResp) (err error) {
|
||||||
|
switch req.Gtype {
|
||||||
|
case 1:
|
||||||
|
err = this.pvp.UserOffline(req.Roomid, req.Offuid)
|
||||||
|
case 2:
|
||||||
|
err = this.caninerabbit.UserOffline(req.Roomid, req.Offuid)
|
||||||
|
case 3:
|
||||||
|
err = this.dcolor.UserOffline(req.Roomid, req.Offuid)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -1,140 +0,0 @@
|
|||||||
package practice
|
|
||||||
|
|
||||||
import (
|
|
||||||
"go_dreamfactory/comm"
|
|
||||||
"go_dreamfactory/lego/sys/log"
|
|
||||||
"go_dreamfactory/pb"
|
|
||||||
"go_dreamfactory/sys/configure"
|
|
||||||
"time"
|
|
||||||
)
|
|
||||||
|
|
||||||
//接受切磋
|
|
||||||
|
|
||||||
func (this *apiComp) AcceptCheck(session comm.IUserSession, req *pb.PracticeAcceptReq) (errdata *pb.ErrorData) {
|
|
||||||
if req.Uid == "" {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_ReqParameterError,
|
|
||||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *apiComp) Accept(session comm.IUserSession, req *pb.PracticeAcceptReq) (errdata *pb.ErrorData) {
|
|
||||||
if errdata = this.AcceptCheck(session, req); errdata != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
var (
|
|
||||||
err error
|
|
||||||
redRecord *pb.DBPracticeQiecuoRecord
|
|
||||||
blueRecord *pb.DBPracticeQiecuoRecord
|
|
||||||
keep bool
|
|
||||||
)
|
|
||||||
|
|
||||||
//校验切磋请求是否超时
|
|
||||||
if redRecord, err = this.module.modelQiecuo.queryQiecuo(req.Uid); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if blueRecord, err = this.module.modelQiecuo.queryQiecuo(session.GetUserId()); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if redRecord.Status == 1 { //已经在战斗中了
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_PracticeQiecuoing,
|
|
||||||
Title: pb.ErrorCode_PracticeQiecuoing.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
keep = false
|
|
||||||
for _, v := range redRecord.Targets {
|
|
||||||
if v.Uid == session.GetUserId() {
|
|
||||||
if configure.Now().Sub(time.Unix(v.Timestamp, 0)).Seconds() > 10 {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_PracticeInviteTimeOut,
|
|
||||||
Title: pb.ErrorCode_PracticeInviteTimeOut.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
keep = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if !keep {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_ReqParameterError,
|
|
||||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
//发起者 red
|
|
||||||
red, err := this.module.ModuleUser.GetUser(req.Uid)
|
|
||||||
if err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_UserNofound,
|
|
||||||
Title: pb.ErrorCode_UserNofound.ToString(),
|
|
||||||
}
|
|
||||||
this.module.Error("未找到红方信息", log.Field{Key: "uid", Value: req.Uid})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
blue, err := this.module.ModuleUser.GetUser(session.GetUserId())
|
|
||||||
if err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_UserNofound,
|
|
||||||
Title: pb.ErrorCode_UserNofound.ToString(),
|
|
||||||
}
|
|
||||||
this.module.Error("未找到蓝方信息", log.Field{Key: "uid", Value: session.GetUserId()})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if redRecord.Battid, errdata = this.module.pvp.CreatePvp(
|
|
||||||
&pb.PvpUserInfo{Uid: red.Uid, Name: red.Name, Avatar: red.Avatar, Lv: red.Lv},
|
|
||||||
&pb.PvpUserInfo{Uid: blue.Uid, Name: blue.Name, Avatar: blue.Avatar, Lv: blue.Lv},
|
|
||||||
pb.PvpType_friends,
|
|
||||||
); errdata != nil {
|
|
||||||
this.module.Error("CreatePvp", log.Field{Key: "code", Value: errdata})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
redRecord.Status = 1
|
|
||||||
redRecord.Member = []string{session.GetUserId(), req.Uid}
|
|
||||||
blueRecord.Status = 1
|
|
||||||
blueRecord.Member = []string{session.GetUserId(), req.Uid}
|
|
||||||
this.module.modelQiecuo.Change(session.GetUserId(), map[string]interface{}{
|
|
||||||
"status": 1,
|
|
||||||
"member": redRecord.Member,
|
|
||||||
"battid": redRecord.Battid,
|
|
||||||
})
|
|
||||||
this.module.modelQiecuo.Change(req.Uid, map[string]interface{}{
|
|
||||||
"status": 1,
|
|
||||||
"member": redRecord.Member,
|
|
||||||
"battid": redRecord.Battid,
|
|
||||||
})
|
|
||||||
|
|
||||||
if err := session.SendMsg(string(this.module.GetType()), "accept", &pb.PracticeAcceptResp{
|
|
||||||
IsSucc: true,
|
|
||||||
}); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_SystemError,
|
|
||||||
Title: pb.ErrorCode_SystemError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
this.module.SendMsgToUser(string(this.module.GetType()), "qiecuonotify",
|
|
||||||
&pb.PracticeQiecuonotifyPush{Uid: session.GetUserId(), NotifyType: 2}, req.Uid)
|
|
||||||
_session, _ := this.module.GetUserSession(req.Uid)
|
|
||||||
|
|
||||||
go this.module.AsynHandleSession(_session.Clone(), func(session comm.IUserSession) {
|
|
||||||
this.module.ModuleBuried.TriggerBuried(session, comm.GetBuriedParam(comm.Rtype183, 1))
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
@ -1,143 +0,0 @@
|
|||||||
package practice
|
|
||||||
|
|
||||||
import (
|
|
||||||
"go_dreamfactory/comm"
|
|
||||||
"go_dreamfactory/lego/sys/log"
|
|
||||||
"go_dreamfactory/pb"
|
|
||||||
"go_dreamfactory/sys/configure"
|
|
||||||
"time"
|
|
||||||
)
|
|
||||||
|
|
||||||
// 踢馆(熊猫武馆)
|
|
||||||
func (this *apiComp) QiecuoCheck(session comm.IUserSession, req *pb.PracticeQiecuoReq) (errdata *pb.ErrorData) {
|
|
||||||
if req.Fid == "" {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_ReqParameterError,
|
|
||||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *apiComp) Qiecuo(session comm.IUserSession, req *pb.PracticeQiecuoReq) (errdata *pb.ErrorData) {
|
|
||||||
if errdata = this.QiecuoCheck(session, req); errdata != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
var (
|
|
||||||
err error
|
|
||||||
result *pb.DBPracticeQiecuoRecord
|
|
||||||
fresult *pb.DBPracticeQiecuoRecord
|
|
||||||
user *pb.DBUser
|
|
||||||
battle *pb.DBPvpBattle
|
|
||||||
keep bool
|
|
||||||
)
|
|
||||||
|
|
||||||
//切磋请求处理
|
|
||||||
if result, err = this.module.modelQiecuo.queryQiecuo(session.GetUserId()); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if fresult, err = this.module.modelQiecuo.queryQiecuo(req.Fid); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
if result.Status == 1 || fresult.Status == 1 { //已经在战斗中了
|
|
||||||
if result.Battid == fresult.Battid { //两个人正在战斗中
|
|
||||||
if battle, err = this.module.pvp.QueryBattle(result.Battid); err != nil {
|
|
||||||
this.module.Error("查询pvp数据失败!", log.Field{Key: "id", Value: result.Battid}, log.Field{Key: "err", Value: err.Error()})
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_SystemError,
|
|
||||||
Title: pb.ErrorCode_SystemError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if err = session.SendMsg(string(this.module.GetType()), "qiecuo", &pb.PracticeQiecuoResp{Fid: req.Fid, Isbattle: true, Battle: battle}); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_SystemError,
|
|
||||||
Title: pb.ErrorCode_SystemError.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
return
|
|
||||||
} else {
|
|
||||||
if result.Status == 1 {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_PracticeYouQiecuoing,
|
|
||||||
Title: pb.ErrorCode_PracticeYouQiecuoing.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
} else {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_PracticeTargetQiecuoing,
|
|
||||||
Title: pb.ErrorCode_PracticeTargetQiecuoing.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//目标是否在线
|
|
||||||
if !this.module.ModuleUser.IsOnline(req.Fid) {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_UserOffline,
|
|
||||||
Title: pb.ErrorCode_UserOffline.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
if user, err = this.module.ModuleUser.GetUser(session.GetUserId()); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
keep = false
|
|
||||||
for _, v := range result.Targets {
|
|
||||||
if v.Uid == req.Fid {
|
|
||||||
keep = true
|
|
||||||
if configure.Now().Sub(time.Unix(v.Timestamp, 0)).Seconds() > 10 {
|
|
||||||
v.Timestamp = configure.Now().Unix()
|
|
||||||
} else {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_PracticeSent,
|
|
||||||
Title: pb.ErrorCode_PracticeSent.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if !keep {
|
|
||||||
result.Targets = append(result.Targets, &pb.DBPracticeQiecuoInvite{
|
|
||||||
Uid: req.Fid,
|
|
||||||
Timestamp: configure.Now().Unix(),
|
|
||||||
})
|
|
||||||
}
|
|
||||||
this.module.modelQiecuo.Change(session.GetUserId(), map[string]interface{}{
|
|
||||||
"targets": result.Targets,
|
|
||||||
})
|
|
||||||
|
|
||||||
if err = session.SendMsg(string(this.module.GetType()), "qiecuo", &pb.PracticeQiecuoResp{Fid: req.Fid}); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_SystemError,
|
|
||||||
Title: pb.ErrorCode_SystemError.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
this.module.SendMsgToUser(string(this.module.GetType()), "qiecuonotify",
|
|
||||||
&pb.PracticeQiecuonotifyPush{Uid: session.GetUserId(), Name: user.Name, NotifyType: 1}, req.Fid)
|
|
||||||
|
|
||||||
return
|
|
||||||
}
|
|
@ -1,87 +0,0 @@
|
|||||||
package practice
|
|
||||||
|
|
||||||
import (
|
|
||||||
"go_dreamfactory/comm"
|
|
||||||
"go_dreamfactory/pb"
|
|
||||||
)
|
|
||||||
|
|
||||||
// 切磋终止
|
|
||||||
func (this *apiComp) RefuseCheck(session comm.IUserSession, req *pb.PracticeRefuseReq) (errdata *pb.ErrorData) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
//拒绝切磋
|
|
||||||
func (this *apiComp) Refuse(session comm.IUserSession, req *pb.PracticeRefuseReq) (errdata *pb.ErrorData) {
|
|
||||||
if errdata = this.RefuseCheck(session, req); errdata != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
var (
|
|
||||||
err error
|
|
||||||
result *pb.DBPracticeQiecuoRecord
|
|
||||||
keep bool
|
|
||||||
room *pb.DBPracticeRoom
|
|
||||||
)
|
|
||||||
|
|
||||||
//切磋请求处理
|
|
||||||
if result, err = this.module.modelQiecuo.queryQiecuo(req.Uid); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
keep = false
|
|
||||||
for i, v := range result.Targets {
|
|
||||||
if v.Uid == session.GetUserId() {
|
|
||||||
result.Targets = append(result.Targets[0:i], result.Targets[i+1:]...)
|
|
||||||
keep = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if !keep {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_ReqParameterError,
|
|
||||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
this.module.modelQiecuo.Change(session.GetUserId(), map[string]interface{}{
|
|
||||||
"targets": result.Targets,
|
|
||||||
})
|
|
||||||
|
|
||||||
if room, err = this.module.modelPandata.queryUserMartialhall(req.Uid); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_DBError,
|
|
||||||
Title: pb.ErrorCode_DBError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
for i, v := range room.Statuers {
|
|
||||||
if v.Uid == session.GetUserId() { //移除雕像
|
|
||||||
room.Statuers = append(room.Statuers[0:i], room.Statuers[i+1:]...)
|
|
||||||
this.module.modelPandata.Change(req.Uid, map[string]interface{}{
|
|
||||||
"statuers": room.Statuers,
|
|
||||||
})
|
|
||||||
break
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if err := session.SendMsg(string(this.module.GetType()), "refuse", &pb.PracticeRefuseResp{
|
|
||||||
IsSucc: true,
|
|
||||||
}); err != nil {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_SystemError,
|
|
||||||
Title: pb.ErrorCode_SystemError.ToString(),
|
|
||||||
Message: err.Error(),
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
this.module.SendMsgToUser(string(this.module.GetType()), "qiecuonotify",
|
|
||||||
&pb.PracticeQiecuonotifyPush{Uid: session.GetUserId(), Name: "", NotifyType: 3}, req.Uid)
|
|
||||||
return
|
|
||||||
}
|
|
@ -1,75 +0,0 @@
|
|||||||
package practice
|
|
||||||
|
|
||||||
import (
|
|
||||||
"go_dreamfactory/comm"
|
|
||||||
"go_dreamfactory/lego/core"
|
|
||||||
"go_dreamfactory/lego/sys/mgo"
|
|
||||||
"go_dreamfactory/modules"
|
|
||||||
"go_dreamfactory/pb"
|
|
||||||
|
|
||||||
"go.mongodb.org/mongo-driver/bson/primitive"
|
|
||||||
"go.mongodb.org/mongo-driver/mongo"
|
|
||||||
"go.mongodb.org/mongo-driver/x/bsonx"
|
|
||||||
)
|
|
||||||
|
|
||||||
// /熊猫武馆数据表
|
|
||||||
type modelQiecuo struct {
|
|
||||||
modules.MCompModel
|
|
||||||
module *Practice
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *modelQiecuo) Init(service core.IService, module core.IModule, comp core.IModuleComp, opt core.IModuleOptions) (err error) {
|
|
||||||
this.TableName = comm.TablePandataQiecuo
|
|
||||||
this.MCompModel.Init(service, module, comp, opt)
|
|
||||||
this.module = module.(*Practice)
|
|
||||||
//创建uid索引
|
|
||||||
this.DB.CreateIndex(core.SqlTable(this.TableName), mongo.IndexModel{
|
|
||||||
Keys: bsonx.Doc{{Key: "uid", Value: bsonx.Int32(1)}},
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
// 切磋请求处理
|
|
||||||
func (this *modelQiecuo) queryQiecuo(uid string) (result *pb.DBPracticeQiecuoRecord, err error) {
|
|
||||||
result = &pb.DBPracticeQiecuoRecord{}
|
|
||||||
if err = this.Get(uid, result); err != nil && err != mgo.MongodbNil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
}
|
|
||||||
if err == mgo.MongodbNil {
|
|
||||||
result = &pb.DBPracticeQiecuoRecord{
|
|
||||||
Id: primitive.NewObjectID().Hex(),
|
|
||||||
Uid: uid,
|
|
||||||
Targets: make([]*pb.DBPracticeQiecuoInvite, 0),
|
|
||||||
}
|
|
||||||
if err = this.Add(uid, result); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
err = nil
|
|
||||||
return
|
|
||||||
}
|
|
||||||
func (this *modelQiecuo) endQiecuo(uid string) (result *pb.DBPracticeQiecuoRecord, err error) {
|
|
||||||
result = &pb.DBPracticeQiecuoRecord{}
|
|
||||||
if err = this.Get(uid, result); err != nil {
|
|
||||||
this.module.Errorln(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
this.Change(uid, map[string]interface{}{
|
|
||||||
"status": 0,
|
|
||||||
"battid": "",
|
|
||||||
"targets": []*pb.DBPracticeQiecuoInvite{},
|
|
||||||
"member": []string{},
|
|
||||||
})
|
|
||||||
for _, v := range result.Member {
|
|
||||||
if v != uid {
|
|
||||||
this.Change(v, map[string]interface{}{
|
|
||||||
"status": 0,
|
|
||||||
"battid": "",
|
|
||||||
"targets": []*pb.DBPracticeQiecuoInvite{},
|
|
||||||
"member": []string{},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return
|
|
||||||
}
|
|
@ -42,7 +42,6 @@ type Practice struct {
|
|||||||
api *apiComp
|
api *apiComp
|
||||||
configure *configureComp
|
configure *configureComp
|
||||||
modelPandata *modelPandata
|
modelPandata *modelPandata
|
||||||
modelQiecuo *modelQiecuo
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 模块名
|
// 模块名
|
||||||
@ -100,7 +99,6 @@ func (this *Practice) OnInstallComp() {
|
|||||||
this.api = this.RegisterComp(new(apiComp)).(*apiComp)
|
this.api = this.RegisterComp(new(apiComp)).(*apiComp)
|
||||||
this.configure = this.RegisterComp(new(configureComp)).(*configureComp)
|
this.configure = this.RegisterComp(new(configureComp)).(*configureComp)
|
||||||
this.modelPandata = this.RegisterComp(new(modelPandata)).(*modelPandata)
|
this.modelPandata = this.RegisterComp(new(modelPandata)).(*modelPandata)
|
||||||
this.modelQiecuo = this.RegisterComp(new(modelQiecuo)).(*modelQiecuo)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 添加武馆资源
|
// 添加武馆资源
|
||||||
@ -255,10 +253,6 @@ func (this *Practice) ChallengeResults(bid, red, bule string, winSide int32) {
|
|||||||
err error
|
err error
|
||||||
)
|
)
|
||||||
|
|
||||||
if _, err = this.modelQiecuo.endQiecuo(red); err != nil {
|
|
||||||
this.Errorln(err)
|
|
||||||
}
|
|
||||||
|
|
||||||
if winSide == 0 {
|
if winSide == 0 {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -12,11 +12,11 @@ type BattleItem struct {
|
|||||||
Id string //战斗id
|
Id string //战斗id
|
||||||
Ptype pb.PvpType //pvp类型
|
Ptype pb.PvpType //pvp类型
|
||||||
State pb.PvpState //战斗状态
|
State pb.PvpState //战斗状态
|
||||||
Red *pb.PvpUserInfo //红方id
|
Red *pb.BaseUserInfo //红方id
|
||||||
RedSession comm.IUserSession //红方连接对象
|
RedSession comm.IUserSession //红方连接对象
|
||||||
Redformation *pb.BattleFormation //红方阵型列表
|
Redformation *pb.BattleFormation //红方阵型列表
|
||||||
RedOffline bool //红方离线
|
RedOffline bool //红方离线
|
||||||
Blue *pb.PvpUserInfo //蓝方id
|
Blue *pb.BaseUserInfo //蓝方id
|
||||||
BlueSession comm.IUserSession //蓝方连接对象
|
BlueSession comm.IUserSession //蓝方连接对象
|
||||||
Blueformation *pb.BattleFormation //蓝方阵型列表
|
Blueformation *pb.BattleFormation //蓝方阵型列表
|
||||||
BlueOffline bool //蓝方离线
|
BlueOffline bool //蓝方离线
|
||||||
|
@ -1,12 +1,11 @@
|
|||||||
package pvp
|
package pvp
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
"go_dreamfactory/comm"
|
"go_dreamfactory/comm"
|
||||||
"go_dreamfactory/lego/base"
|
"go_dreamfactory/lego/base"
|
||||||
"go_dreamfactory/lego/core"
|
"go_dreamfactory/lego/core"
|
||||||
"go_dreamfactory/lego/sys/event"
|
|
||||||
"go_dreamfactory/lego/sys/log"
|
"go_dreamfactory/lego/sys/log"
|
||||||
"go_dreamfactory/lego/sys/timewheel"
|
"go_dreamfactory/lego/sys/timewheel"
|
||||||
"go_dreamfactory/modules"
|
"go_dreamfactory/modules"
|
||||||
@ -32,6 +31,7 @@ type Pvp struct {
|
|||||||
modules.ModuleBase
|
modules.ModuleBase
|
||||||
service base.IRPCXService
|
service base.IRPCXService
|
||||||
battle comm.IBattle
|
battle comm.IBattle
|
||||||
|
gameInvite comm.IGameInvite
|
||||||
practice comm.IPractice
|
practice comm.IPractice
|
||||||
apicomp *apiComp
|
apicomp *apiComp
|
||||||
modelPvpComp *modelPvpComp
|
modelPvpComp *modelPvpComp
|
||||||
@ -63,13 +63,17 @@ func (this *Pvp) Start() (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.battle = module.(comm.IBattle)
|
this.battle = module.(comm.IBattle)
|
||||||
|
if module, err = this.service.GetModule(comm.ModuleGameInvite); err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.gameInvite = module.(comm.IGameInvite)
|
||||||
if module, err = this.service.GetModule(comm.ModulePractice); err != nil {
|
if module, err = this.service.GetModule(comm.ModulePractice); err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.practice = module.(comm.IPractice)
|
this.practice = module.(comm.IPractice)
|
||||||
// event.RegisterGO(comm.EventUserLogin, this.userlogin)
|
// event.RegisterGO(comm.EventUserLogin, this.userlogin)
|
||||||
event.RegisterGO(comm.EventUserOffline, this.useroffline)
|
// event.RegisterGO(comm.EventUserOffline, this.useroffline)
|
||||||
this.service.RegisterFunctionName(string(comm.RPC_PVPTrusteeship), this.trusteeship)
|
// this.service.RegisterFunctionName(string(comm.RPC_PVPTrusteeship), this.trusteeship)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -86,36 +90,38 @@ func (this *Pvp) QueryBattle(id string) (battle *pb.DBPvpBattle, err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 创建Pvp
|
// 创建Pvp
|
||||||
func (this *Pvp) CreatePvp(red, blue *pb.PvpUserInfo, ptype pb.PvpType) (battleId string, errdata *pb.ErrorData) {
|
func (this *Pvp) CreateRoom(sessions []comm.IUserSession, rulesStr string) (roomid string, err error) {
|
||||||
this.Debug("CreatePvp", log.Field{Key: "ptype", Value: ptype.String()}, log.Field{Key: "red", Value: red.String()}, log.Field{Key: "blue", Value: blue.String()})
|
this.Debug("CreatePvp", log.Field{Key: "rulesStr", Value: rulesStr}, log.Field{Key: "sessions", Value: sessions})
|
||||||
var (
|
var (
|
||||||
battle *BattleItem
|
rules *pb.DBPvpRules = &pb.DBPvpRules{}
|
||||||
err error
|
battle *BattleItem
|
||||||
ok bool
|
red, blue *pb.DBUser
|
||||||
)
|
)
|
||||||
battleId = primitive.NewObjectID().Hex()
|
if err = json.Unmarshal([]byte(rulesStr), rules); err != nil {
|
||||||
battle = &BattleItem{
|
this.Error("解析规则json", log.Field{Key: "err", Value: err.Error()})
|
||||||
Id: battleId,
|
|
||||||
Ptype: ptype,
|
|
||||||
State: pb.PvpState_ready,
|
|
||||||
Red: red,
|
|
||||||
Blue: blue,
|
|
||||||
readytimer: timewheel.Add(time.Second*60, this.readyTimeOut, battleId),
|
|
||||||
curroperate: &pb.ComWaitInputSkill{},
|
|
||||||
}
|
|
||||||
|
|
||||||
if battle.RedSession, ok = this.GetUserSession(red.Uid); !ok {
|
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_BattleUserOff,
|
|
||||||
Title: pb.ErrorCode_BattleUserOff.ToString(),
|
|
||||||
}
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if battle.BlueSession, ok = this.GetUserSession(blue.Uid); !ok {
|
roomid = primitive.NewObjectID().Hex()
|
||||||
errdata = &pb.ErrorData{
|
battle = &BattleItem{
|
||||||
Code: pb.ErrorCode_BattleUserOff,
|
Id: roomid,
|
||||||
Title: pb.ErrorCode_BattleUserOff.ToString(),
|
Ptype: rules.Ptype,
|
||||||
}
|
State: pb.PvpState_ready,
|
||||||
|
RedSession: sessions[0],
|
||||||
|
BlueSession: sessions[1],
|
||||||
|
Red: comm.GetUserBaseInfo(red),
|
||||||
|
Blue: comm.GetUserBaseInfo(blue),
|
||||||
|
readytimer: timewheel.Add(time.Second*60, this.readyTimeOut, roomid),
|
||||||
|
curroperate: &pb.ComWaitInputSkill{},
|
||||||
|
}
|
||||||
|
//发起者 red
|
||||||
|
red, err = this.ModuleUser.GetUser(sessions[0].GetUserId())
|
||||||
|
if err != nil {
|
||||||
|
this.Error("未找到红方信息", log.Field{Key: "uid", Value: sessions[0].GetUserId()})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
blue, err = this.ModuleUser.GetUser(sessions[1].GetUserId())
|
||||||
|
if err != nil {
|
||||||
|
this.Error("未找到蓝方信息", log.Field{Key: "uid", Value: sessions[1].GetUserId()})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.lock.Lock()
|
this.lock.Lock()
|
||||||
@ -129,10 +135,6 @@ func (this *Pvp) CreatePvp(red, blue *pb.PvpUserInfo, ptype pb.PvpType) (battleI
|
|||||||
Countdown: 60,
|
Countdown: 60,
|
||||||
}, battle.RedSession, battle.BlueSession); err != nil {
|
}, battle.RedSession, battle.BlueSession); err != nil {
|
||||||
this.Errorln(err)
|
this.Errorln(err)
|
||||||
errdata = &pb.ErrorData{
|
|
||||||
Code: pb.ErrorCode_RpcFuncExecutionError,
|
|
||||||
Title: pb.ErrorCode_RpcFuncExecutionError.ToString(),
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -216,7 +218,10 @@ func (this *Pvp) PvpFinishPush(out *pb.BattleFinishPush) {
|
|||||||
this.lock.RUnlock()
|
this.lock.RUnlock()
|
||||||
switch battle.Ptype {
|
switch battle.Ptype {
|
||||||
case pb.PvpType_friends:
|
case pb.PvpType_friends:
|
||||||
go this.practice.ChallengeResults(out.Battleid, battle.Red.Uid, battle.Blue.Uid, out.WinSide)
|
go func() {
|
||||||
|
this.gameInvite.GameInviteEnd(3, battle.Red.Uid)
|
||||||
|
this.practice.ChallengeResults(out.Battleid, battle.Red.Uid, battle.Blue.Uid, out.WinSide)
|
||||||
|
}()
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
this.modelPvpComp.delpvp(out.Battleid)
|
this.modelPvpComp.delpvp(out.Battleid)
|
||||||
@ -266,7 +271,10 @@ func (this *Pvp) readyTimeOut(task *timewheel.Task, args ...interface{}) {
|
|||||||
if battle.Blueformation != nil {
|
if battle.Blueformation != nil {
|
||||||
winside = 2
|
winside = 2
|
||||||
}
|
}
|
||||||
go this.practice.ChallengeResults(battle.Id, battle.Red.Uid, battle.Blue.Uid, winside)
|
go func() {
|
||||||
|
this.gameInvite.GameInviteEnd(3, battle.Red.Uid)
|
||||||
|
this.practice.ChallengeResults(battle.Id, battle.Red.Uid, battle.Blue.Uid, winside)
|
||||||
|
}()
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -374,88 +382,48 @@ func (this *Pvp) startBattle(battle *BattleItem) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 用户离线处理 弃用
|
// // 用户离线处理
|
||||||
func (this *Pvp) userlogin(session comm.IUserSession) {
|
// func (this *Pvp) useroffline(uid, sessionid string) {
|
||||||
// var (
|
// var (
|
||||||
// result []*pb.DBPvpBattle
|
// result []*pb.DBPvpBattle
|
||||||
// userpvp []*pb.DBPvpBattle
|
// lockpath string = fmt.Sprintf("%s/%s", this.service.GetType(), this.service.GetId())
|
||||||
// push *pb.PvpListPush
|
// service map[string][]string = make(map[string][]string)
|
||||||
// err error
|
// err error
|
||||||
// )
|
// )
|
||||||
// if result, err = this.modelPvpComp.querypvps(); err != nil {
|
// if result, err = this.modelPvpComp.querypvps(); err != nil {
|
||||||
// this.Errorln(err)
|
// this.Errorln(err)
|
||||||
// return
|
// return
|
||||||
// }
|
// }
|
||||||
|
// for _, v := range result {
|
||||||
|
// if v.Red.Uid == uid || v.Blue.Uid == uid {
|
||||||
|
// if service[v.ServicePath] == nil {
|
||||||
|
// service[v.ServicePath] = make([]string, 0)
|
||||||
|
// }
|
||||||
|
// service[v.ServicePath] = append(service[v.ServicePath], v.Id)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
// userpvp = make([]*pb.DBPvpBattle, 0, len(userpvp))
|
// for k, v := range service {
|
||||||
// for _, v := range result {
|
// if k == lockpath { //在当前服务器上
|
||||||
// if v.Red.Uid == session.GetUserId() || v.Blue.Uid == session.GetUserId() {
|
// this.trusteeship(context.Background(), &pb.RPC_PVPTrusteeshipReq{Battleid: v, Uid: uid}, nil)
|
||||||
// userpvp = append(userpvp, v)
|
// } else { //在别的服务器上
|
||||||
// }
|
// ctx, _ := context.WithTimeout(context.Background(), time.Second*5)
|
||||||
// }
|
// _, err = this.service.RpcGo(
|
||||||
// if len(userpvp) <= 0 {
|
// ctx,
|
||||||
// return
|
// k,
|
||||||
// }
|
// string(comm.RPC_PVPTrusteeship),
|
||||||
// push = &pb.PvpListPush{}
|
// &pb.RPC_PVPTrusteeshipReq{Battleid: v, Uid: uid},
|
||||||
// for _, v := range result {
|
// nil)
|
||||||
// push.List = append(push.List, &pb.DBPvpBattle{
|
// if err != nil {
|
||||||
// Id: v.Id,
|
// this.Errorln(err)
|
||||||
// ServicePath: v.ServicePath,
|
// return
|
||||||
// Ptype: v.Ptype,
|
// }
|
||||||
// State: v.State,
|
// }
|
||||||
// Red: v.Red,
|
// }
|
||||||
// Blue: v.Blue,
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
|
|
||||||
// session.SendMsg(string(comm.ModulePvp), "list", push)
|
// }
|
||||||
// session.Push()
|
|
||||||
// this.Debug("GetPvpInfo", log.Field{Key: "uid", Value: session.GetSessionId()}, log.Field{Key: "list", Value: push.String()})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 用户离线处理
|
func (this *Pvp) UserOffline(roomid string, uid string) (err error) {
|
||||||
func (this *Pvp) useroffline(uid, sessionid string) {
|
|
||||||
var (
|
|
||||||
result []*pb.DBPvpBattle
|
|
||||||
lockpath string = fmt.Sprintf("%s/%s", this.service.GetType(), this.service.GetId())
|
|
||||||
service map[string][]string = make(map[string][]string)
|
|
||||||
err error
|
|
||||||
)
|
|
||||||
if result, err = this.modelPvpComp.querypvps(); err != nil {
|
|
||||||
this.Errorln(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
for _, v := range result {
|
|
||||||
if v.Red.Uid == uid || v.Blue.Uid == uid {
|
|
||||||
if service[v.ServicePath] == nil {
|
|
||||||
service[v.ServicePath] = make([]string, 0)
|
|
||||||
}
|
|
||||||
service[v.ServicePath] = append(service[v.ServicePath], v.Id)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
for k, v := range service {
|
|
||||||
if k == lockpath { //在当前服务器上
|
|
||||||
this.trusteeship(context.Background(), &pb.RPC_PVPTrusteeshipReq{Battleid: v, Uid: uid}, nil)
|
|
||||||
} else { //在别的服务器上
|
|
||||||
ctx, _ := context.WithTimeout(context.Background(), time.Second*5)
|
|
||||||
_, err = this.service.RpcGo(
|
|
||||||
ctx,
|
|
||||||
k,
|
|
||||||
string(comm.RPC_PVPTrusteeship),
|
|
||||||
&pb.RPC_PVPTrusteeshipReq{Battleid: v, Uid: uid},
|
|
||||||
nil)
|
|
||||||
if err != nil {
|
|
||||||
this.Errorln(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
// 托管
|
|
||||||
func (this *Pvp) trusteeship(ctx context.Context, req *pb.RPC_PVPTrusteeshipReq, resp *pb.RPC_PVPTrusteeshipResp) (err error) {
|
|
||||||
var (
|
var (
|
||||||
battle *BattleItem
|
battle *BattleItem
|
||||||
ok bool
|
ok bool
|
||||||
@ -463,39 +431,83 @@ func (this *Pvp) trusteeship(ctx context.Context, req *pb.RPC_PVPTrusteeshipReq,
|
|||||||
data []byte
|
data []byte
|
||||||
errdata *pb.ErrorData
|
errdata *pb.ErrorData
|
||||||
)
|
)
|
||||||
for _, bid := range req.Battleid {
|
this.lock.RLock()
|
||||||
this.lock.RLock()
|
battle, ok = this.battles[roomid]
|
||||||
battle, ok = this.battles[bid]
|
this.lock.RUnlock()
|
||||||
this.lock.RUnlock()
|
if ok {
|
||||||
if ok {
|
if battle.Red.Uid == uid || battle.Blue.Uid == uid {
|
||||||
if battle.Red.Uid == req.Uid || battle.Blue.Uid == req.Uid {
|
if uid == battle.Red.Uid {
|
||||||
if req.Uid == battle.Red.Uid {
|
side = 1
|
||||||
side = 1
|
battle.RedOffline = true
|
||||||
battle.RedOffline = true
|
} else {
|
||||||
} else {
|
side = 2
|
||||||
side = 2
|
battle.BlueOffline = true
|
||||||
battle.BlueOffline = true
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if battle.curroperate.Side == side {
|
if battle.curroperate.Side == side {
|
||||||
if battle.operatetimer != nil {
|
if battle.operatetimer != nil {
|
||||||
timewheel.Remove(battle.operatetimer)
|
timewheel.Remove(battle.operatetimer)
|
||||||
}
|
}
|
||||||
battle.curroperate.Auto = true
|
battle.curroperate.Auto = true
|
||||||
data, _ = proto.Marshal(battle.curroperate)
|
data, _ = proto.Marshal(battle.curroperate)
|
||||||
if errdata = this.battle.InCmdBattle(&pb.BattleInCmdReq{
|
if errdata = this.battle.InCmdBattle(&pb.BattleInCmdReq{
|
||||||
Battleid: battle.Id,
|
Battleid: battle.Id,
|
||||||
Side: battle.curroperate.Side,
|
Side: battle.curroperate.Side,
|
||||||
In: &pb.BattleCmd{
|
In: &pb.BattleCmd{
|
||||||
Cmdtype: "ComWaitInputSkill",
|
Cmdtype: "ComWaitInputSkill",
|
||||||
Value: data,
|
Value: data,
|
||||||
},
|
},
|
||||||
}); errdata != nil {
|
}); errdata != nil {
|
||||||
return
|
return
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// // 托管
|
||||||
|
// func (this *Pvp) trusteeship(ctx context.Context, req *pb.RPC_PVPTrusteeshipReq, resp *pb.RPC_PVPTrusteeshipResp) (err error) {
|
||||||
|
// var (
|
||||||
|
// battle *BattleItem
|
||||||
|
// ok bool
|
||||||
|
// side int32
|
||||||
|
// data []byte
|
||||||
|
// errdata *pb.ErrorData
|
||||||
|
// )
|
||||||
|
// for _, bid := range req.Battleid {
|
||||||
|
// this.lock.RLock()
|
||||||
|
// battle, ok = this.battles[bid]
|
||||||
|
// this.lock.RUnlock()
|
||||||
|
// if ok {
|
||||||
|
// if battle.Red.Uid == req.Uid || battle.Blue.Uid == req.Uid {
|
||||||
|
// if req.Uid == battle.Red.Uid {
|
||||||
|
// side = 1
|
||||||
|
// battle.RedOffline = true
|
||||||
|
// } else {
|
||||||
|
// side = 2
|
||||||
|
// battle.BlueOffline = true
|
||||||
|
// }
|
||||||
|
|
||||||
|
// if battle.curroperate.Side == side {
|
||||||
|
// if battle.operatetimer != nil {
|
||||||
|
// timewheel.Remove(battle.operatetimer)
|
||||||
|
// }
|
||||||
|
// battle.curroperate.Auto = true
|
||||||
|
// data, _ = proto.Marshal(battle.curroperate)
|
||||||
|
// if errdata = this.battle.InCmdBattle(&pb.BattleInCmdReq{
|
||||||
|
// Battleid: battle.Id,
|
||||||
|
// Side: battle.curroperate.Side,
|
||||||
|
// In: &pb.BattleCmd{
|
||||||
|
// Cmdtype: "ComWaitInputSkill",
|
||||||
|
// Value: data,
|
||||||
|
// },
|
||||||
|
// }); errdata != nil {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
@ -148,8 +148,9 @@ type GameInviteQiecuoRecord struct {
|
|||||||
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"` //发起人id
|
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"` //发起人id
|
||||||
Status int32 `protobuf:"varint,3,opt,name=status,proto3" json:"status"` //0邀请中 1战斗中
|
Status int32 `protobuf:"varint,3,opt,name=status,proto3" json:"status"` //0邀请中 1战斗中
|
||||||
Gtype int32 `protobuf:"varint,4,opt,name=gtype,proto3" json:"gtype"` //当前游戏类型 0 武馆切磋 3 猜颜色
|
Gtype int32 `protobuf:"varint,4,opt,name=gtype,proto3" json:"gtype"` //当前游戏类型 0 武馆切磋 3 猜颜色
|
||||||
Battid string `protobuf:"bytes,5,opt,name=battid,proto3" json:"battid"` //战斗id
|
Roomid string `protobuf:"bytes,5,opt,name=roomid,proto3" json:"roomid"` //房间id
|
||||||
Invite map[int32]*GameInviteData `protobuf:"bytes,6,rep,name=Invite,proto3" json:"Invite" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` //邀请数据
|
Spath string `protobuf:"bytes,6,opt,name=spath,proto3" json:"spath"` //服务地址
|
||||||
|
Invite map[int32]*GameInviteData `protobuf:"bytes,7,rep,name=Invite,proto3" json:"Invite" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` //邀请数据
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GameInviteQiecuoRecord) Reset() {
|
func (x *GameInviteQiecuoRecord) Reset() {
|
||||||
@ -212,9 +213,16 @@ func (x *GameInviteQiecuoRecord) GetGtype() int32 {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GameInviteQiecuoRecord) GetBattid() string {
|
func (x *GameInviteQiecuoRecord) GetRoomid() string {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Battid
|
return x.Roomid
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *GameInviteQiecuoRecord) GetSpath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Spath
|
||||||
}
|
}
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
@ -242,25 +250,26 @@ var file_gameinvite_gameinvite_db_proto_rawDesc = []byte{
|
|||||||
0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x52, 0x07, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x73, 0x12,
|
0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x52, 0x07, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x73, 0x12,
|
||||||
0x16, 0x0a, 0x06, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52,
|
0x16, 0x0a, 0x06, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52,
|
||||||
0x06, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73,
|
0x06, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73,
|
||||||
0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x22, 0x89, 0x02,
|
0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x22, 0x9f, 0x02,
|
||||||
0x0a, 0x16, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x51, 0x69, 0x65, 0x63,
|
0x0a, 0x16, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x51, 0x69, 0x65, 0x63,
|
||||||
0x75, 0x6f, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01,
|
0x75, 0x6f, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18,
|
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18,
|
||||||
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74,
|
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74,
|
||||||
0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74,
|
0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74,
|
||||||
0x75, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28,
|
0x75, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28,
|
||||||
0x05, 0x52, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x62, 0x61, 0x74, 0x74,
|
0x05, 0x52, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x6f, 0x6f, 0x6d,
|
||||||
0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x62, 0x61, 0x74, 0x74, 0x69, 0x64,
|
0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64,
|
||||||
0x12, 0x3b, 0x0a, 0x06, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b,
|
0x12, 0x14, 0x0a, 0x05, 0x73, 0x70, 0x61, 0x74, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||||
0x32, 0x23, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x51, 0x69, 0x65,
|
0x05, 0x73, 0x70, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x06, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65,
|
||||||
0x63, 0x75, 0x6f, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65,
|
0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76,
|
||||||
0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x1a, 0x4a, 0x0a,
|
0x69, 0x74, 0x65, 0x51, 0x69, 0x65, 0x63, 0x75, 0x6f, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e,
|
||||||
0x0b, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
|
0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x49, 0x6e, 0x76,
|
||||||
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x25,
|
0x69, 0x74, 0x65, 0x1a, 0x4a, 0x0a, 0x0b, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x45, 0x6e, 0x74,
|
||||||
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e,
|
0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52,
|
||||||
0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x05,
|
0x03, 0x6b, 0x65, 0x79, 0x12, 0x25, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20,
|
||||||
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70,
|
0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65,
|
||||||
0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42,
|
||||||
|
0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
@ -417,6 +417,109 @@ func (x *GameInviteQiecuonotifyPush) GetRules() string {
|
|||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//游戏邀请离线请求
|
||||||
|
type RPC_GameInviteOfflineReq struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
|
Gtype int32 `protobuf:"varint,1,opt,name=gtype,proto3" json:"gtype"` //游戏类型
|
||||||
|
Roomid string `protobuf:"bytes,2,opt,name=roomid,proto3" json:"roomid"`
|
||||||
|
Offuid string `protobuf:"bytes,3,opt,name=offuid,proto3" json:"offuid"`
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) Reset() {
|
||||||
|
*x = RPC_GameInviteOfflineReq{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_gameinvite_gameinvite_msg_proto_msgTypes[7]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RPC_GameInviteOfflineReq) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_gameinvite_gameinvite_msg_proto_msgTypes[7]
|
||||||
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use RPC_GameInviteOfflineReq.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RPC_GameInviteOfflineReq) Descriptor() ([]byte, []int) {
|
||||||
|
return file_gameinvite_gameinvite_msg_proto_rawDescGZIP(), []int{7}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) GetGtype() int32 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Gtype
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) GetRoomid() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Roomid
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineReq) GetOffuid() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.Offuid
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
//游戏邀请离线请求
|
||||||
|
type RPC_GameInviteOfflineResp struct {
|
||||||
|
state protoimpl.MessageState
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineResp) Reset() {
|
||||||
|
*x = RPC_GameInviteOfflineResp{}
|
||||||
|
if protoimpl.UnsafeEnabled {
|
||||||
|
mi := &file_gameinvite_gameinvite_msg_proto_msgTypes[8]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineResp) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*RPC_GameInviteOfflineResp) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *RPC_GameInviteOfflineResp) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_gameinvite_gameinvite_msg_proto_msgTypes[8]
|
||||||
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use RPC_GameInviteOfflineResp.ProtoReflect.Descriptor instead.
|
||||||
|
func (*RPC_GameInviteOfflineResp) Descriptor() ([]byte, []int) {
|
||||||
|
return file_gameinvite_gameinvite_msg_proto_rawDescGZIP(), []int{8}
|
||||||
|
}
|
||||||
|
|
||||||
var File_gameinvite_gameinvite_msg_proto protoreflect.FileDescriptor
|
var File_gameinvite_gameinvite_msg_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
var file_gameinvite_gameinvite_msg_proto_rawDesc = []byte{
|
var file_gameinvite_gameinvite_msg_proto_rawDesc = []byte{
|
||||||
@ -455,8 +558,16 @@ var file_gameinvite_gameinvite_msg_proto_rawDesc = []byte{
|
|||||||
0x74, 0x69, 0x66, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x74, 0x79, 0x70,
|
0x74, 0x69, 0x66, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x74, 0x79, 0x70,
|
||||||
0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x12, 0x14,
|
0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x12, 0x14,
|
||||||
0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72,
|
0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72,
|
||||||
0x75, 0x6c, 0x65, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72,
|
0x75, 0x6c, 0x65, 0x73, 0x22, 0x60, 0x0a, 0x18, 0x52, 0x50, 0x43, 0x5f, 0x47, 0x61, 0x6d, 0x65,
|
||||||
0x6f, 0x74, 0x6f, 0x33,
|
0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x4f, 0x66, 0x66, 0x6c, 0x69, 0x6e, 0x65, 0x52, 0x65, 0x71,
|
||||||
|
0x12, 0x14, 0x0a, 0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52,
|
||||||
|
0x05, 0x67, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64,
|
||||||
|
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x12, 0x16,
|
||||||
|
0x0a, 0x06, 0x6f, 0x66, 0x66, 0x75, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06,
|
||||||
|
0x6f, 0x66, 0x66, 0x75, 0x69, 0x64, 0x22, 0x1b, 0x0a, 0x19, 0x52, 0x50, 0x43, 0x5f, 0x47, 0x61,
|
||||||
|
0x6d, 0x65, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x65, 0x4f, 0x66, 0x66, 0x6c, 0x69, 0x6e, 0x65, 0x52,
|
||||||
|
0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
||||||
|
0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -471,7 +582,7 @@ func file_gameinvite_gameinvite_msg_proto_rawDescGZIP() []byte {
|
|||||||
return file_gameinvite_gameinvite_msg_proto_rawDescData
|
return file_gameinvite_gameinvite_msg_proto_rawDescData
|
||||||
}
|
}
|
||||||
|
|
||||||
var file_gameinvite_gameinvite_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
|
var file_gameinvite_gameinvite_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
|
||||||
var file_gameinvite_gameinvite_msg_proto_goTypes = []interface{}{
|
var file_gameinvite_gameinvite_msg_proto_goTypes = []interface{}{
|
||||||
(*GameInviteQiecuoReq)(nil), // 0: GameInviteQiecuoReq
|
(*GameInviteQiecuoReq)(nil), // 0: GameInviteQiecuoReq
|
||||||
(*GameInviteQiecuoResp)(nil), // 1: GameInviteQiecuoResp
|
(*GameInviteQiecuoResp)(nil), // 1: GameInviteQiecuoResp
|
||||||
@ -480,10 +591,12 @@ var file_gameinvite_gameinvite_msg_proto_goTypes = []interface{}{
|
|||||||
(*GameInviteRefuseReq)(nil), // 4: GameInviteRefuseReq
|
(*GameInviteRefuseReq)(nil), // 4: GameInviteRefuseReq
|
||||||
(*GameInviteRefuseResp)(nil), // 5: GameInviteRefuseResp
|
(*GameInviteRefuseResp)(nil), // 5: GameInviteRefuseResp
|
||||||
(*GameInviteQiecuonotifyPush)(nil), // 6: GameInviteQiecuonotifyPush
|
(*GameInviteQiecuonotifyPush)(nil), // 6: GameInviteQiecuonotifyPush
|
||||||
(*BaseUserInfo)(nil), // 7: BaseUserInfo
|
(*RPC_GameInviteOfflineReq)(nil), // 7: RPC_GameInviteOfflineReq
|
||||||
|
(*RPC_GameInviteOfflineResp)(nil), // 8: RPC_GameInviteOfflineResp
|
||||||
|
(*BaseUserInfo)(nil), // 9: BaseUserInfo
|
||||||
}
|
}
|
||||||
var file_gameinvite_gameinvite_msg_proto_depIdxs = []int32{
|
var file_gameinvite_gameinvite_msg_proto_depIdxs = []int32{
|
||||||
7, // 0: GameInviteQiecuonotifyPush.user:type_name -> BaseUserInfo
|
9, // 0: GameInviteQiecuonotifyPush.user:type_name -> BaseUserInfo
|
||||||
1, // [1:1] is the sub-list for method output_type
|
1, // [1:1] is the sub-list for method output_type
|
||||||
1, // [1:1] is the sub-list for method input_type
|
1, // [1:1] is the sub-list for method input_type
|
||||||
1, // [1:1] is the sub-list for extension type_name
|
1, // [1:1] is the sub-list for extension type_name
|
||||||
@ -582,6 +695,30 @@ func file_gameinvite_gameinvite_msg_proto_init() {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
file_gameinvite_gameinvite_msg_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RPC_GameInviteOfflineReq); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
file_gameinvite_gameinvite_msg_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||||
|
switch v := v.(*RPC_GameInviteOfflineResp); i {
|
||||||
|
case 0:
|
||||||
|
return &v.state
|
||||||
|
case 1:
|
||||||
|
return &v.sizeCache
|
||||||
|
case 2:
|
||||||
|
return &v.unknownFields
|
||||||
|
default:
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
type x struct{}
|
type x struct{}
|
||||||
out := protoimpl.TypeBuilder{
|
out := protoimpl.TypeBuilder{
|
||||||
@ -589,7 +726,7 @@ func file_gameinvite_gameinvite_msg_proto_init() {
|
|||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: file_gameinvite_gameinvite_msg_proto_rawDesc,
|
RawDescriptor: file_gameinvite_gameinvite_msg_proto_rawDesc,
|
||||||
NumEnums: 0,
|
NumEnums: 0,
|
||||||
NumMessages: 7,
|
NumMessages: 9,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 0,
|
NumServices: 0,
|
||||||
},
|
},
|
||||||
|
@ -131,6 +131,7 @@ type DBIslandItem struct {
|
|||||||
|
|
||||||
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
|
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
|
||||||
Level map[int32]int32 `protobuf:"bytes,2,rep,name=level,proto3" json:"level" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //key 关卡id value 0或者不存在 表示未通关 不等于 0表示通关 不等于 1 表示 选择的剧情id
|
Level map[int32]int32 `protobuf:"bytes,2,rep,name=level,proto3" json:"level" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //key 关卡id value 0或者不存在 表示未通关 不等于 0表示通关 不等于 1 表示 选择的剧情id
|
||||||
|
Pos *DBVector3 `protobuf:"bytes,3,opt,name=pos,proto3" json:"pos"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBIslandItem) Reset() {
|
func (x *DBIslandItem) Reset() {
|
||||||
@ -179,45 +180,55 @@ func (x *DBIslandItem) GetLevel() map[int32]int32 {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x *DBIslandItem) GetPos() *DBVector3 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Pos
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
var File_island_island_db_proto protoreflect.FileDescriptor
|
var File_island_island_db_proto protoreflect.FileDescriptor
|
||||||
|
|
||||||
var file_island_island_db_proto_rawDesc = []byte{
|
var file_island_island_db_proto_rawDesc = []byte{
|
||||||
0x0a, 0x16, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2f, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x5f,
|
0x0a, 0x16, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2f, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x5f,
|
||||||
0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x83, 0x03, 0x0a, 0x08, 0x44, 0x42, 0x49,
|
0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70,
|
||||||
0x73, 0x6c, 0x61, 0x6e, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
0x72, 0x6f, 0x74, 0x6f, 0x22, 0x83, 0x03, 0x0a, 0x08, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e,
|
||||||
0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01,
|
0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69,
|
||||||
0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x65, 0x72, 0x6f, 0x73,
|
0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
||||||
0x68, 0x6f, 0x70, 0x18, 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x68, 0x65, 0x72, 0x6f, 0x73,
|
0x75, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x65, 0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x18,
|
||||||
0x68, 0x6f, 0x70, 0x12, 0x30, 0x0a, 0x07, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x18, 0x04,
|
0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x68, 0x65, 0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x12,
|
||||||
0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2e,
|
0x30, 0x0a, 0x07, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b,
|
||||||
0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x69, 0x73,
|
0x32, 0x16, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2e, 0x49, 0x73, 0x6c, 0x61,
|
||||||
0x6c, 0x61, 0x6e, 0x64, 0x73, 0x12, 0x2a, 0x0a, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x18, 0x05,
|
0x6e, 0x64, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x69, 0x73, 0x6c, 0x61, 0x6e, 0x64,
|
||||||
0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2e,
|
0x73, 0x12, 0x2a, 0x0a, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b,
|
||||||
0x4e, 0x6f, 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65,
|
0x32, 0x14, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x2e, 0x4e, 0x6f, 0x64, 0x65,
|
||||||
0x73, 0x12, 0x22, 0x0a, 0x0c, 0x66, 0x72, 0x65, 0x65, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x65, 0x73,
|
0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x12, 0x22, 0x0a,
|
||||||
0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x66, 0x72, 0x65, 0x65, 0x70, 0x72, 0x6f,
|
0x0c, 0x66, 0x72, 0x65, 0x65, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73, 0x18, 0x06, 0x20,
|
||||||
0x67, 0x72, 0x65, 0x73, 0x73, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x61, 0x79, 0x70, 0x72, 0x6f, 0x67,
|
0x01, 0x28, 0x05, 0x52, 0x0c, 0x66, 0x72, 0x65, 0x65, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x65, 0x73,
|
||||||
0x72, 0x65, 0x73, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x70, 0x61, 0x79, 0x70,
|
0x73, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x61, 0x79, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73,
|
||||||
0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x76, 0x69, 0x70, 0x18, 0x08,
|
0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x70, 0x61, 0x79, 0x70, 0x72, 0x6f, 0x67, 0x72,
|
||||||
0x20, 0x01, 0x28, 0x08, 0x52, 0x03, 0x76, 0x69, 0x70, 0x1a, 0x49, 0x0a, 0x0c, 0x49, 0x73, 0x6c,
|
0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x76, 0x69, 0x70, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08,
|
||||||
0x61, 0x6e, 0x64, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
|
0x52, 0x03, 0x76, 0x69, 0x70, 0x1a, 0x49, 0x0a, 0x0c, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73,
|
||||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x23, 0x0a, 0x05, 0x76,
|
0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01,
|
||||||
0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x49,
|
0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x23, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
|
||||||
0x73, 0x6c, 0x61, 0x6e, 0x64, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
|
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e,
|
||||||
0x3a, 0x02, 0x38, 0x01, 0x1a, 0x38, 0x0a, 0x0a, 0x4e, 0x6f, 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74,
|
0x64, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01,
|
||||||
0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52,
|
0x1a, 0x38, 0x0a, 0x0a, 0x4e, 0x6f, 0x64, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10,
|
||||||
0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20,
|
0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79,
|
||||||
0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x88,
|
0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52,
|
||||||
0x01, 0x0a, 0x0c, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x49, 0x74, 0x65, 0x6d, 0x12,
|
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xa6, 0x01, 0x0a, 0x0c, 0x44,
|
||||||
0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x69, 0x64, 0x12,
|
0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69,
|
||||||
0x2e, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18,
|
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x69, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x6c,
|
||||||
0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x49, 0x74, 0x65, 0x6d, 0x2e, 0x4c, 0x65,
|
0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x44, 0x42, 0x49,
|
||||||
0x76, 0x65, 0x6c, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x1a,
|
0x73, 0x6c, 0x61, 0x6e, 0x64, 0x49, 0x74, 0x65, 0x6d, 0x2e, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x45,
|
||||||
0x38, 0x0a, 0x0a, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
|
0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x1c, 0x0a, 0x03, 0x70,
|
||||||
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
|
0x6f, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x44, 0x42, 0x56, 0x65, 0x63,
|
||||||
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
|
0x74, 0x6f, 0x72, 0x33, 0x52, 0x03, 0x70, 0x6f, 0x73, 0x1a, 0x38, 0x0a, 0x0a, 0x4c, 0x65, 0x76,
|
||||||
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70,
|
0x65, 0x6c, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01,
|
||||||
0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
|
||||||
|
0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a,
|
||||||
|
0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
||||||
|
0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -239,17 +250,19 @@ var file_island_island_db_proto_goTypes = []interface{}{
|
|||||||
nil, // 2: DBIsland.IslandsEntry
|
nil, // 2: DBIsland.IslandsEntry
|
||||||
nil, // 3: DBIsland.NodesEntry
|
nil, // 3: DBIsland.NodesEntry
|
||||||
nil, // 4: DBIslandItem.LevelEntry
|
nil, // 4: DBIslandItem.LevelEntry
|
||||||
|
(*DBVector3)(nil), // 5: DBVector3
|
||||||
}
|
}
|
||||||
var file_island_island_db_proto_depIdxs = []int32{
|
var file_island_island_db_proto_depIdxs = []int32{
|
||||||
2, // 0: DBIsland.islands:type_name -> DBIsland.IslandsEntry
|
2, // 0: DBIsland.islands:type_name -> DBIsland.IslandsEntry
|
||||||
3, // 1: DBIsland.nodes:type_name -> DBIsland.NodesEntry
|
3, // 1: DBIsland.nodes:type_name -> DBIsland.NodesEntry
|
||||||
4, // 2: DBIslandItem.level:type_name -> DBIslandItem.LevelEntry
|
4, // 2: DBIslandItem.level:type_name -> DBIslandItem.LevelEntry
|
||||||
1, // 3: DBIsland.IslandsEntry.value:type_name -> DBIslandItem
|
5, // 3: DBIslandItem.pos:type_name -> DBVector3
|
||||||
4, // [4:4] is the sub-list for method output_type
|
1, // 4: DBIsland.IslandsEntry.value:type_name -> DBIslandItem
|
||||||
4, // [4:4] is the sub-list for method input_type
|
5, // [5:5] is the sub-list for method output_type
|
||||||
4, // [4:4] is the sub-list for extension type_name
|
5, // [5:5] is the sub-list for method input_type
|
||||||
4, // [4:4] is the sub-list for extension extendee
|
5, // [5:5] is the sub-list for extension type_name
|
||||||
0, // [0:4] is the sub-list for field type_name
|
5, // [5:5] is the sub-list for extension extendee
|
||||||
|
0, // [0:5] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_island_island_db_proto_init() }
|
func init() { file_island_island_db_proto_init() }
|
||||||
@ -257,6 +270,7 @@ func file_island_island_db_proto_init() {
|
|||||||
if File_island_island_db_proto != nil {
|
if File_island_island_db_proto != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
file_comm_proto_init()
|
||||||
if !protoimpl.UnsafeEnabled {
|
if !protoimpl.UnsafeEnabled {
|
||||||
file_island_island_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
file_island_island_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*DBIsland); i {
|
switch v := v.(*DBIsland); i {
|
||||||
|
@ -235,6 +235,7 @@ type IsLandCompleteReq struct {
|
|||||||
Level int32 `protobuf:"varint,1,opt,name=level,proto3" json:"level"`
|
Level int32 `protobuf:"varint,1,opt,name=level,proto3" json:"level"`
|
||||||
Story int32 `protobuf:"varint,2,opt,name=story,proto3" json:"story"`
|
Story int32 `protobuf:"varint,2,opt,name=story,proto3" json:"story"`
|
||||||
Report *BattleReport `protobuf:"bytes,3,opt,name=report,proto3" json:"report"` //战报 打怪事件完成需要提交战报
|
Report *BattleReport `protobuf:"bytes,3,opt,name=report,proto3" json:"report"` //战报 打怪事件完成需要提交战报
|
||||||
|
Pos *DBVector3 `protobuf:"bytes,4,opt,name=pos,proto3" json:"pos"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *IsLandCompleteReq) Reset() {
|
func (x *IsLandCompleteReq) Reset() {
|
||||||
@ -290,6 +291,13 @@ func (x *IsLandCompleteReq) GetReport() *BattleReport {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x *IsLandCompleteReq) GetPos() *DBVector3 {
|
||||||
|
if x != nil {
|
||||||
|
return x.Pos
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
//海岛探险 关卡完成 回应
|
//海岛探险 关卡完成 回应
|
||||||
type IsLandCompleteResp struct {
|
type IsLandCompleteResp struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
@ -759,44 +767,46 @@ var file_island_island_msg_proto_rawDesc = []byte{
|
|||||||
0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28,
|
0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||||
0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x1f, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f,
|
0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x1f, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f,
|
||||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49,
|
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x49,
|
||||||
0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x66, 0x0a, 0x11, 0x49, 0x73, 0x4c,
|
0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x84, 0x01, 0x0a, 0x11, 0x49, 0x73,
|
||||||
0x61, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x14,
|
0x4c, 0x61, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12,
|
||||||
0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c,
|
0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
|
||||||
0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x18, 0x02, 0x20,
|
0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x18, 0x02,
|
||||||
0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x25, 0x0a, 0x06, 0x72, 0x65,
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x25, 0x0a, 0x06, 0x72,
|
||||||
0x70, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x74,
|
0x65, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61,
|
||||||
0x74, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x06, 0x72, 0x65, 0x70, 0x6f, 0x72,
|
0x74, 0x74, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x06, 0x72, 0x65, 0x70, 0x6f,
|
||||||
0x74, 0x22, 0x61, 0x0a, 0x12, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c,
|
0x72, 0x74, 0x12, 0x1c, 0x0a, 0x03, 0x70, 0x6f, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||||
0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c,
|
0x0a, 0x2e, 0x44, 0x42, 0x56, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x33, 0x52, 0x03, 0x70, 0x6f, 0x73,
|
||||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a,
|
0x22, 0x61, 0x0a, 0x12, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65,
|
||||||
0x05, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74,
|
0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18,
|
||||||
0x6f, 0x72, 0x79, 0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x03, 0x20, 0x03,
|
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05,
|
||||||
0x28, 0x0b, 0x32, 0x09, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61,
|
0x73, 0x74, 0x6f, 0x72, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x6f,
|
||||||
0x77, 0x61, 0x72, 0x64, 0x22, 0x19, 0x0a, 0x17, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65,
|
0x72, 0x79, 0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x03, 0x20, 0x03, 0x28,
|
||||||
0x66, 0x72, 0x65, 0x73, 0x48, 0x65, 0x72, 0x6f, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x22,
|
|
||||||
0x36, 0x0a, 0x18, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x48,
|
|
||||||
0x65, 0x72, 0x6f, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x68,
|
|
||||||
0x65, 0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x68,
|
|
||||||
0x65, 0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x22, 0x22, 0x0a, 0x0c, 0x49, 0x73, 0x4c, 0x61, 0x6e,
|
|
||||||
0x64, 0x42, 0x75, 0x79, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x69, 0x64, 0x73, 0x18,
|
|
||||||
0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x04, 0x63, 0x69, 0x64, 0x73, 0x22, 0x30, 0x0a, 0x0d, 0x49,
|
|
||||||
0x73, 0x4c, 0x61, 0x6e, 0x64, 0x42, 0x75, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x05,
|
|
||||||
0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x55, 0x73,
|
|
||||||
0x65, 0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x22, 0x24, 0x0a,
|
|
||||||
0x10, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x52, 0x65,
|
|
||||||
0x71, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03,
|
|
||||||
0x6e, 0x69, 0x64, 0x22, 0x35, 0x0a, 0x11, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x55, 0x70, 0x67,
|
|
||||||
0x72, 0x61, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x6c, 0x76,
|
|
||||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x6c, 0x76, 0x22, 0x12, 0x0a, 0x10, 0x49, 0x73,
|
|
||||||
0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, 0x22, 0x53,
|
|
||||||
0x0a, 0x11, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52,
|
|
||||||
0x65, 0x73, 0x70, 0x12, 0x1d, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
||||||
0x0b, 0x32, 0x09, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x52, 0x04, 0x69, 0x6e,
|
|
||||||
0x66, 0x6f, 0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x04, 0x20, 0x03, 0x28,
|
|
||||||
0x0b, 0x32, 0x09, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61, 0x77,
|
0x0b, 0x32, 0x09, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61, 0x77,
|
||||||
0x61, 0x72, 0x64, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
0x61, 0x72, 0x64, 0x22, 0x19, 0x0a, 0x17, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x66,
|
||||||
0x74, 0x6f, 0x33,
|
0x72, 0x65, 0x73, 0x48, 0x65, 0x72, 0x6f, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x22, 0x36,
|
||||||
|
0x0a, 0x18, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x66, 0x72, 0x65, 0x73, 0x48, 0x65,
|
||||||
|
0x72, 0x6f, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x65,
|
||||||
|
0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x08, 0x68, 0x65,
|
||||||
|
0x72, 0x6f, 0x73, 0x68, 0x6f, 0x70, 0x22, 0x22, 0x0a, 0x0c, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64,
|
||||||
|
0x42, 0x75, 0x79, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x69, 0x64, 0x73, 0x18, 0x01,
|
||||||
|
0x20, 0x03, 0x28, 0x05, 0x52, 0x04, 0x63, 0x69, 0x64, 0x73, 0x22, 0x30, 0x0a, 0x0d, 0x49, 0x73,
|
||||||
|
0x4c, 0x61, 0x6e, 0x64, 0x42, 0x75, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x05, 0x61,
|
||||||
|
0x77, 0x61, 0x72, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x55, 0x73, 0x65,
|
||||||
|
0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x22, 0x24, 0x0a, 0x10,
|
||||||
|
0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x52, 0x65, 0x71,
|
||||||
|
0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e,
|
||||||
|
0x69, 0x64, 0x22, 0x35, 0x0a, 0x11, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x55, 0x70, 0x67, 0x72,
|
||||||
|
0x61, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x69, 0x64, 0x18, 0x01,
|
||||||
|
0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x6c, 0x76, 0x18,
|
||||||
|
0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x6c, 0x76, 0x22, 0x12, 0x0a, 0x10, 0x49, 0x73, 0x4c,
|
||||||
|
0x61, 0x6e, 0x64, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, 0x22, 0x53, 0x0a,
|
||||||
|
0x11, 0x49, 0x73, 0x4c, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52, 0x65,
|
||||||
|
0x73, 0x70, 0x12, 0x1d, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b,
|
||||||
|
0x32, 0x09, 0x2e, 0x44, 0x42, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x52, 0x04, 0x69, 0x6e, 0x66,
|
||||||
|
0x6f, 0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b,
|
||||||
|
0x32, 0x09, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x74, 0x6e, 0x6f, 0x52, 0x05, 0x61, 0x77, 0x61,
|
||||||
|
0x72, 0x64, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
|
||||||
|
0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -832,7 +842,8 @@ var file_island_island_msg_proto_goTypes = []interface{}{
|
|||||||
(*BattleFormation)(nil), // 16: BattleFormation
|
(*BattleFormation)(nil), // 16: BattleFormation
|
||||||
(*BattleInfo)(nil), // 17: BattleInfo
|
(*BattleInfo)(nil), // 17: BattleInfo
|
||||||
(*BattleReport)(nil), // 18: BattleReport
|
(*BattleReport)(nil), // 18: BattleReport
|
||||||
(*UserAtno)(nil), // 19: UserAtno
|
(*DBVector3)(nil), // 19: DBVector3
|
||||||
|
(*UserAtno)(nil), // 20: UserAtno
|
||||||
}
|
}
|
||||||
var file_island_island_msg_proto_depIdxs = []int32{
|
var file_island_island_msg_proto_depIdxs = []int32{
|
||||||
14, // 0: IsLandInfoResp.info:type_name -> DBIsland
|
14, // 0: IsLandInfoResp.info:type_name -> DBIsland
|
||||||
@ -840,15 +851,16 @@ var file_island_island_msg_proto_depIdxs = []int32{
|
|||||||
16, // 2: IsLandBattleReq.battle:type_name -> BattleFormation
|
16, // 2: IsLandBattleReq.battle:type_name -> BattleFormation
|
||||||
17, // 3: IsLandBattleResp.info:type_name -> BattleInfo
|
17, // 3: IsLandBattleResp.info:type_name -> BattleInfo
|
||||||
18, // 4: IsLandCompleteReq.report:type_name -> BattleReport
|
18, // 4: IsLandCompleteReq.report:type_name -> BattleReport
|
||||||
19, // 5: IsLandCompleteResp.award:type_name -> UserAtno
|
19, // 5: IsLandCompleteReq.pos:type_name -> DBVector3
|
||||||
19, // 6: IsLandBuyResp.award:type_name -> UserAtno
|
20, // 6: IsLandCompleteResp.award:type_name -> UserAtno
|
||||||
14, // 7: IsLandReceiveResp.info:type_name -> DBIsland
|
20, // 7: IsLandBuyResp.award:type_name -> UserAtno
|
||||||
19, // 8: IsLandReceiveResp.award:type_name -> UserAtno
|
14, // 8: IsLandReceiveResp.info:type_name -> DBIsland
|
||||||
9, // [9:9] is the sub-list for method output_type
|
20, // 9: IsLandReceiveResp.award:type_name -> UserAtno
|
||||||
9, // [9:9] is the sub-list for method input_type
|
10, // [10:10] is the sub-list for method output_type
|
||||||
9, // [9:9] is the sub-list for extension type_name
|
10, // [10:10] is the sub-list for method input_type
|
||||||
9, // [9:9] is the sub-list for extension extendee
|
10, // [10:10] is the sub-list for extension type_name
|
||||||
0, // [0:9] is the sub-list for field type_name
|
10, // [10:10] is the sub-list for extension extendee
|
||||||
|
0, // [0:10] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_island_island_msg_proto_init() }
|
func init() { file_island_island_msg_proto_init() }
|
||||||
|
145
pb/pvp_db.pb.go
145
pb/pvp_db.pb.go
@ -119,19 +119,17 @@ func (PvpState) EnumDescriptor() ([]byte, []int) {
|
|||||||
return file_pvp_pvp_db_proto_rawDescGZIP(), []int{1}
|
return file_pvp_pvp_db_proto_rawDescGZIP(), []int{1}
|
||||||
}
|
}
|
||||||
|
|
||||||
type PvpUserInfo struct {
|
//游戏规则
|
||||||
|
type DBPvpRules struct {
|
||||||
state protoimpl.MessageState
|
state protoimpl.MessageState
|
||||||
sizeCache protoimpl.SizeCache
|
sizeCache protoimpl.SizeCache
|
||||||
unknownFields protoimpl.UnknownFields
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid"`
|
Ptype PvpType `protobuf:"varint,1,opt,name=ptype,proto3,enum=PvpType" json:"ptype"`
|
||||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name"`
|
|
||||||
Avatar string `protobuf:"bytes,3,opt,name=avatar,proto3" json:"avatar"`
|
|
||||||
Lv int32 `protobuf:"varint,4,opt,name=lv,proto3" json:"lv"`
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpUserInfo) Reset() {
|
func (x *DBPvpRules) Reset() {
|
||||||
*x = PvpUserInfo{}
|
*x = DBPvpRules{}
|
||||||
if protoimpl.UnsafeEnabled {
|
if protoimpl.UnsafeEnabled {
|
||||||
mi := &file_pvp_pvp_db_proto_msgTypes[0]
|
mi := &file_pvp_pvp_db_proto_msgTypes[0]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
@ -139,13 +137,13 @@ func (x *PvpUserInfo) Reset() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpUserInfo) String() string {
|
func (x *DBPvpRules) String() string {
|
||||||
return protoimpl.X.MessageStringOf(x)
|
return protoimpl.X.MessageStringOf(x)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*PvpUserInfo) ProtoMessage() {}
|
func (*DBPvpRules) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *PvpUserInfo) ProtoReflect() protoreflect.Message {
|
func (x *DBPvpRules) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_pvp_pvp_db_proto_msgTypes[0]
|
mi := &file_pvp_pvp_db_proto_msgTypes[0]
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
if protoimpl.UnsafeEnabled && x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
@ -157,37 +155,16 @@ func (x *PvpUserInfo) ProtoReflect() protoreflect.Message {
|
|||||||
return mi.MessageOf(x)
|
return mi.MessageOf(x)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Deprecated: Use PvpUserInfo.ProtoReflect.Descriptor instead.
|
// Deprecated: Use DBPvpRules.ProtoReflect.Descriptor instead.
|
||||||
func (*PvpUserInfo) Descriptor() ([]byte, []int) {
|
func (*DBPvpRules) Descriptor() ([]byte, []int) {
|
||||||
return file_pvp_pvp_db_proto_rawDescGZIP(), []int{0}
|
return file_pvp_pvp_db_proto_rawDescGZIP(), []int{0}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpUserInfo) GetUid() string {
|
func (x *DBPvpRules) GetPtype() PvpType {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Uid
|
return x.Ptype
|
||||||
}
|
}
|
||||||
return ""
|
return PvpType_friends
|
||||||
}
|
|
||||||
|
|
||||||
func (x *PvpUserInfo) GetName() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Name
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *PvpUserInfo) GetAvatar() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Avatar
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *PvpUserInfo) GetLv() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Lv
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type DBPvpBattle struct {
|
type DBPvpBattle struct {
|
||||||
@ -195,12 +172,12 @@ type DBPvpBattle struct {
|
|||||||
sizeCache protoimpl.SizeCache
|
sizeCache protoimpl.SizeCache
|
||||||
unknownFields protoimpl.UnknownFields
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"` //战斗id
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"` //战斗id
|
||||||
ServicePath string `protobuf:"bytes,2,opt,name=servicePath,proto3" json:"servicePath"` //战斗区服地址
|
ServicePath string `protobuf:"bytes,2,opt,name=servicePath,proto3" json:"servicePath"` //战斗区服地址
|
||||||
Ptype PvpType `protobuf:"varint,3,opt,name=ptype,proto3,enum=PvpType" json:"ptype"` //pvp类型
|
Ptype PvpType `protobuf:"varint,3,opt,name=ptype,proto3,enum=PvpType" json:"ptype"` //pvp类型
|
||||||
State PvpState `protobuf:"varint,4,opt,name=state,proto3,enum=PvpState" json:"state"` //战斗状态
|
State PvpState `protobuf:"varint,4,opt,name=state,proto3,enum=PvpState" json:"state"` //战斗状态
|
||||||
Red *PvpUserInfo `protobuf:"bytes,5,opt,name=red,proto3" json:"red"` //红方id
|
Red *BaseUserInfo `protobuf:"bytes,5,opt,name=red,proto3" json:"red"` //红方id
|
||||||
Blue *PvpUserInfo `protobuf:"bytes,6,opt,name=blue,proto3" json:"blue"` //红方id
|
Blue *BaseUserInfo `protobuf:"bytes,6,opt,name=blue,proto3" json:"blue"` //红方id
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBPvpBattle) Reset() {
|
func (x *DBPvpBattle) Reset() {
|
||||||
@ -263,14 +240,14 @@ func (x *DBPvpBattle) GetState() PvpState {
|
|||||||
return PvpState_void
|
return PvpState_void
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBPvpBattle) GetRed() *PvpUserInfo {
|
func (x *DBPvpBattle) GetRed() *BaseUserInfo {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Red
|
return x.Red
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DBPvpBattle) GetBlue() *PvpUserInfo {
|
func (x *DBPvpBattle) GetBlue() *BaseUserInfo {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Blue
|
return x.Blue
|
||||||
}
|
}
|
||||||
@ -281,32 +258,29 @@ var File_pvp_pvp_db_proto protoreflect.FileDescriptor
|
|||||||
|
|
||||||
var file_pvp_pvp_db_proto_rawDesc = []byte{
|
var file_pvp_pvp_db_proto_rawDesc = []byte{
|
||||||
0x0a, 0x10, 0x70, 0x76, 0x70, 0x2f, 0x70, 0x76, 0x70, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f,
|
0x0a, 0x10, 0x70, 0x76, 0x70, 0x2f, 0x70, 0x76, 0x70, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f,
|
||||||
0x74, 0x6f, 0x22, 0x5b, 0x0a, 0x0b, 0x50, 0x76, 0x70, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66,
|
0x74, 0x6f, 0x1a, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x2c,
|
||||||
0x6f, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
0x0a, 0x0a, 0x44, 0x42, 0x50, 0x76, 0x70, 0x52, 0x75, 0x6c, 0x65, 0x73, 0x12, 0x1e, 0x0a, 0x05,
|
||||||
0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
|
0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x08, 0x2e, 0x50, 0x76,
|
||||||
0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61,
|
0x70, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x22, 0xc4, 0x01, 0x0a,
|
||||||
0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x12,
|
0x0b, 0x44, 0x42, 0x50, 0x76, 0x70, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x12, 0x0e, 0x0a, 0x02,
|
||||||
0x0e, 0x0a, 0x02, 0x6c, 0x76, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x6c, 0x76, 0x22,
|
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x20, 0x0a, 0x0b,
|
||||||
0xc2, 0x01, 0x0a, 0x0b, 0x44, 0x42, 0x50, 0x76, 0x70, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x12,
|
0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||||
0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12,
|
0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e,
|
||||||
0x20, 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02,
|
0x0a, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x08, 0x2e,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74,
|
0x50, 0x76, 0x70, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1f,
|
||||||
0x68, 0x12, 0x1e, 0x0a, 0x05, 0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e,
|
0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x09, 0x2e,
|
||||||
0x32, 0x08, 0x2e, 0x50, 0x76, 0x70, 0x54, 0x79, 0x70, 0x65, 0x52, 0x05, 0x70, 0x74, 0x79, 0x70,
|
0x50, 0x76, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12,
|
||||||
0x65, 0x12, 0x1f, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e,
|
0x1f, 0x0a, 0x03, 0x72, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42,
|
||||||
0x32, 0x09, 0x2e, 0x50, 0x76, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61,
|
0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x03, 0x72, 0x65, 0x64,
|
||||||
0x74, 0x65, 0x12, 0x1e, 0x0a, 0x03, 0x72, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
0x12, 0x21, 0x0a, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d,
|
||||||
0x0c, 0x2e, 0x50, 0x76, 0x70, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x03, 0x72,
|
0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x62,
|
||||||
0x65, 0x64, 0x12, 0x20, 0x0a, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b,
|
0x6c, 0x75, 0x65, 0x2a, 0x16, 0x0a, 0x07, 0x50, 0x76, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b,
|
||||||
0x32, 0x0c, 0x2e, 0x50, 0x76, 0x70, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04,
|
0x0a, 0x07, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x73, 0x10, 0x00, 0x2a, 0x43, 0x0a, 0x08, 0x50,
|
||||||
0x62, 0x6c, 0x75, 0x65, 0x2a, 0x16, 0x0a, 0x07, 0x50, 0x76, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12,
|
0x76, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x76, 0x6f, 0x69, 0x64, 0x10,
|
||||||
0x0b, 0x0a, 0x07, 0x66, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x73, 0x10, 0x00, 0x2a, 0x43, 0x0a, 0x08,
|
0x00, 0x12, 0x09, 0x0a, 0x05, 0x72, 0x65, 0x61, 0x64, 0x79, 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06,
|
||||||
0x50, 0x76, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x76, 0x6f, 0x69, 0x64,
|
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x10, 0x02, 0x12, 0x0a, 0x0a, 0x06, 0x63, 0x61, 0x6e, 0x63,
|
||||||
0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x72, 0x65, 0x61, 0x64, 0x79, 0x10, 0x01, 0x12, 0x0a, 0x0a,
|
0x65, 0x6c, 0x10, 0x03, 0x12, 0x0a, 0x0a, 0x06, 0x66, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x10, 0x04,
|
||||||
0x06, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x10, 0x02, 0x12, 0x0a, 0x0a, 0x06, 0x63, 0x61, 0x6e,
|
0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
0x63, 0x65, 0x6c, 0x10, 0x03, 0x12, 0x0a, 0x0a, 0x06, 0x66, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x10,
|
|
||||||
0x04, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
|
||||||
0x33,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -324,21 +298,23 @@ func file_pvp_pvp_db_proto_rawDescGZIP() []byte {
|
|||||||
var file_pvp_pvp_db_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
var file_pvp_pvp_db_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
||||||
var file_pvp_pvp_db_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
var file_pvp_pvp_db_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
|
||||||
var file_pvp_pvp_db_proto_goTypes = []interface{}{
|
var file_pvp_pvp_db_proto_goTypes = []interface{}{
|
||||||
(PvpType)(0), // 0: PvpType
|
(PvpType)(0), // 0: PvpType
|
||||||
(PvpState)(0), // 1: PvpState
|
(PvpState)(0), // 1: PvpState
|
||||||
(*PvpUserInfo)(nil), // 2: PvpUserInfo
|
(*DBPvpRules)(nil), // 2: DBPvpRules
|
||||||
(*DBPvpBattle)(nil), // 3: DBPvpBattle
|
(*DBPvpBattle)(nil), // 3: DBPvpBattle
|
||||||
|
(*BaseUserInfo)(nil), // 4: BaseUserInfo
|
||||||
}
|
}
|
||||||
var file_pvp_pvp_db_proto_depIdxs = []int32{
|
var file_pvp_pvp_db_proto_depIdxs = []int32{
|
||||||
0, // 0: DBPvpBattle.ptype:type_name -> PvpType
|
0, // 0: DBPvpRules.ptype:type_name -> PvpType
|
||||||
1, // 1: DBPvpBattle.state:type_name -> PvpState
|
0, // 1: DBPvpBattle.ptype:type_name -> PvpType
|
||||||
2, // 2: DBPvpBattle.red:type_name -> PvpUserInfo
|
1, // 2: DBPvpBattle.state:type_name -> PvpState
|
||||||
2, // 3: DBPvpBattle.blue:type_name -> PvpUserInfo
|
4, // 3: DBPvpBattle.red:type_name -> BaseUserInfo
|
||||||
4, // [4:4] is the sub-list for method output_type
|
4, // 4: DBPvpBattle.blue:type_name -> BaseUserInfo
|
||||||
4, // [4:4] is the sub-list for method input_type
|
5, // [5:5] is the sub-list for method output_type
|
||||||
4, // [4:4] is the sub-list for extension type_name
|
5, // [5:5] is the sub-list for method input_type
|
||||||
4, // [4:4] is the sub-list for extension extendee
|
5, // [5:5] is the sub-list for extension type_name
|
||||||
0, // [0:4] is the sub-list for field type_name
|
5, // [5:5] is the sub-list for extension extendee
|
||||||
|
0, // [0:5] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_pvp_pvp_db_proto_init() }
|
func init() { file_pvp_pvp_db_proto_init() }
|
||||||
@ -346,9 +322,10 @@ func file_pvp_pvp_db_proto_init() {
|
|||||||
if File_pvp_pvp_db_proto != nil {
|
if File_pvp_pvp_db_proto != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
file_comm_proto_init()
|
||||||
if !protoimpl.UnsafeEnabled {
|
if !protoimpl.UnsafeEnabled {
|
||||||
file_pvp_pvp_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
file_pvp_pvp_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*PvpUserInfo); i {
|
switch v := v.(*DBPvpRules); i {
|
||||||
case 0:
|
case 0:
|
||||||
return &v.state
|
return &v.state
|
||||||
case 1:
|
case 1:
|
||||||
|
196
pb/pvp_msg.pb.go
196
pb/pvp_msg.pb.go
@ -225,11 +225,11 @@ type PvpReadyPush struct {
|
|||||||
sizeCache protoimpl.SizeCache
|
sizeCache protoimpl.SizeCache
|
||||||
unknownFields protoimpl.UnknownFields
|
unknownFields protoimpl.UnknownFields
|
||||||
|
|
||||||
ServicePath string `protobuf:"bytes,1,opt,name=servicePath,proto3" json:"servicePath"` //战斗区服地址
|
ServicePath string `protobuf:"bytes,1,opt,name=servicePath,proto3" json:"servicePath"` //战斗区服地址
|
||||||
Battleid string `protobuf:"bytes,2,opt,name=battleid,proto3" json:"battleid"` //战斗id
|
Battleid string `protobuf:"bytes,2,opt,name=battleid,proto3" json:"battleid"` //战斗id
|
||||||
Red *PvpUserInfo `protobuf:"bytes,3,opt,name=red,proto3" json:"red"` //红方用户信息
|
Red *BaseUserInfo `protobuf:"bytes,3,opt,name=red,proto3" json:"red"` //红方用户信息
|
||||||
Blue *PvpUserInfo `protobuf:"bytes,4,opt,name=blue,proto3" json:"blue"` //蓝方用户信息
|
Blue *BaseUserInfo `protobuf:"bytes,4,opt,name=blue,proto3" json:"blue"` //蓝方用户信息
|
||||||
Countdown int32 `protobuf:"varint,5,opt,name=countdown,proto3" json:"countdown"` //布阵倒计时
|
Countdown int32 `protobuf:"varint,5,opt,name=countdown,proto3" json:"countdown"` //布阵倒计时
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpReadyPush) Reset() {
|
func (x *PvpReadyPush) Reset() {
|
||||||
@ -278,14 +278,14 @@ func (x *PvpReadyPush) GetBattleid() string {
|
|||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpReadyPush) GetRed() *PvpUserInfo {
|
func (x *PvpReadyPush) GetRed() *BaseUserInfo {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Red
|
return x.Red
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *PvpReadyPush) GetBlue() *PvpUserInfo {
|
func (x *PvpReadyPush) GetBlue() *BaseUserInfo {
|
||||||
if x != nil {
|
if x != nil {
|
||||||
return x.Blue
|
return x.Blue
|
||||||
}
|
}
|
||||||
@ -1093,95 +1093,96 @@ var file_pvp_pvp_msg_proto_rawDesc = []byte{
|
|||||||
0x6f, 0x74, 0x6f, 0x1a, 0x10, 0x70, 0x76, 0x70, 0x2f, 0x70, 0x76, 0x70, 0x5f, 0x64, 0x62, 0x2e,
|
0x6f, 0x74, 0x6f, 0x1a, 0x10, 0x70, 0x76, 0x70, 0x2f, 0x70, 0x76, 0x70, 0x5f, 0x64, 0x62, 0x2e,
|
||||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x2f, 0x62, 0x61,
|
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x2f, 0x62, 0x61,
|
||||||
0x74, 0x74, 0x6c, 0x65, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0f,
|
0x74, 0x74, 0x6c, 0x65, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0f,
|
||||||
0x65, 0x72, 0x72, 0x6f, 0x72, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22,
|
0x65, 0x72, 0x72, 0x6f, 0x72, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a,
|
||||||
0x0c, 0x0a, 0x0a, 0x50, 0x76, 0x70, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x22, 0x2f, 0x0a,
|
0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x0c, 0x0a, 0x0a, 0x50,
|
||||||
0x0b, 0x50, 0x76, 0x70, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x20, 0x0a, 0x04,
|
0x76, 0x70, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x22, 0x2f, 0x0a, 0x0b, 0x50, 0x76, 0x70,
|
||||||
0x6c, 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x44, 0x42, 0x50,
|
0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x20, 0x0a, 0x04, 0x6c, 0x69, 0x73, 0x74,
|
||||||
0x76, 0x70, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0x28,
|
0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x44, 0x42, 0x50, 0x76, 0x70, 0x42, 0x61,
|
||||||
0x0a, 0x0a, 0x50, 0x76, 0x70, 0x49, 0x6e, 0x74, 0x6f, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08,
|
0x74, 0x74, 0x6c, 0x65, 0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0x28, 0x0a, 0x0a, 0x50, 0x76,
|
||||||
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
|
0x70, 0x49, 0x6e, 0x74, 0x6f, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74,
|
||||||
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22, 0x6f, 0x0a, 0x0b, 0x50, 0x76, 0x70, 0x49,
|
|
||||||
0x6e, 0x74, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1e, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0a, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64,
|
|
||||||
0x65, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c,
|
|
||||||
0x65, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c,
|
|
||||||
0x65, 0x69, 0x64, 0x12, 0x24, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28,
|
|
||||||
0x0b, 0x32, 0x10, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x49,
|
|
||||||
0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0xac, 0x01, 0x0a, 0x0c, 0x50, 0x76,
|
|
||||||
0x70, 0x52, 0x65, 0x61, 0x64, 0x79, 0x50, 0x75, 0x73, 0x68, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x65,
|
|
||||||
0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
|
||||||
0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08,
|
|
||||||
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
|
|
||||||
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x03, 0x72, 0x65, 0x64, 0x18,
|
|
||||||
0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x50, 0x76, 0x70, 0x55, 0x73, 0x65, 0x72, 0x49,
|
|
||||||
0x6e, 0x66, 0x6f, 0x52, 0x03, 0x72, 0x65, 0x64, 0x12, 0x20, 0x0a, 0x04, 0x62, 0x6c, 0x75, 0x65,
|
|
||||||
0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x50, 0x76, 0x70, 0x55, 0x73, 0x65, 0x72,
|
|
||||||
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f,
|
|
||||||
0x75, 0x6e, 0x74, 0x64, 0x6f, 0x77, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63,
|
|
||||||
0x6f, 0x75, 0x6e, 0x74, 0x64, 0x6f, 0x77, 0x6e, 0x22, 0x30, 0x0a, 0x12, 0x50, 0x76, 0x70, 0x4c,
|
|
||||||
0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x1a,
|
|
||||||
0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
|
||||||
0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22, 0x49, 0x0a, 0x13, 0x50, 0x76,
|
|
||||||
0x70, 0x4c, 0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73,
|
|
||||||
0x70, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20,
|
|
||||||
0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x16, 0x0a,
|
|
||||||
0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69,
|
|
||||||
0x73, 0x73, 0x75, 0x63, 0x63, 0x22, 0x4b, 0x0a, 0x19, 0x50, 0x76, 0x70, 0x4c, 0x6f, 0x61, 0x64,
|
|
||||||
0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x4e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x50, 0x75,
|
|
||||||
0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01,
|
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x12,
|
|
||||||
0x0a, 0x04, 0x73, 0x69, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, 0x69,
|
|
||||||
0x64, 0x65, 0x22, 0x4d, 0x0a, 0x0d, 0x50, 0x76, 0x70, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x50,
|
|
||||||
0x75, 0x73, 0x68, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61,
|
|
||||||
0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63,
|
|
||||||
0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
|
||||||
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
|
||||||
0x64, 0x22, 0x30, 0x0a, 0x12, 0x50, 0x76, 0x70, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x43, 0x61,
|
|
||||||
0x6e, 0x63, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c,
|
|
||||||
0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c,
|
|
||||||
0x65, 0x69, 0x64, 0x22, 0x2d, 0x0a, 0x13, 0x50, 0x76, 0x70, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65,
|
|
||||||
0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73,
|
|
||||||
0x73, 0x75, 0x63, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75,
|
|
||||||
0x63, 0x63, 0x22, 0x5d, 0x0a, 0x0f, 0x50, 0x76, 0x70, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69,
|
|
||||||
0x6f, 0x6e, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
|
||||||
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
|
||||||
0x64, 0x12, 0x2e, 0x0a, 0x09, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02,
|
|
||||||
0x20, 0x01, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72,
|
|
||||||
0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x09, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f,
|
|
||||||
0x6e, 0x22, 0x2a, 0x0a, 0x10, 0x50, 0x76, 0x70, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f,
|
|
||||||
0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x22, 0x4f, 0x0a,
|
|
||||||
0x0c, 0x50, 0x76, 0x70, 0x53, 0x74, 0x61, 0x72, 0x74, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1e, 0x0a,
|
|
||||||
0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0a, 0x2e, 0x45, 0x72,
|
|
||||||
0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x0a,
|
|
||||||
0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61,
|
|
||||||
0x74, 0x74, 0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x49,
|
|
||||||
0x0a, 0x0d, 0x50, 0x76, 0x70, 0x4f, 0x75, 0x74, 0x43, 0x6d, 0x64, 0x50, 0x75, 0x73, 0x68, 0x12,
|
|
||||||
0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
||||||
0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x03, 0x63,
|
|
||||||
0x6d, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c,
|
|
||||||
0x65, 0x43, 0x6d, 0x64, 0x52, 0x03, 0x63, 0x6d, 0x64, 0x22, 0x47, 0x0a, 0x0b, 0x50, 0x76, 0x70,
|
|
||||||
0x49, 0x6e, 0x43, 0x6d, 0x64, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74,
|
|
||||||
0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74,
|
0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74,
|
||||||
0x6c, 0x65, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x03, 0x63, 0x6d, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
|
0x6c, 0x65, 0x69, 0x64, 0x22, 0x6f, 0x0a, 0x0b, 0x50, 0x76, 0x70, 0x49, 0x6e, 0x74, 0x6f, 0x52,
|
||||||
0x0b, 0x32, 0x0a, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6d, 0x64, 0x52, 0x03, 0x63,
|
0x65, 0x73, 0x70, 0x12, 0x1e, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||||
0x6d, 0x64, 0x22, 0x68, 0x0a, 0x0c, 0x50, 0x76, 0x70, 0x49, 0x6e, 0x43, 0x6d, 0x64, 0x52, 0x65,
|
0x0e, 0x32, 0x0a, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x63,
|
||||||
0x73, 0x70, 0x12, 0x1e, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e,
|
0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18,
|
||||||
0x32, 0x0a, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x63, 0x6f,
|
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12,
|
||||||
0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x02,
|
0x24, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x10, 0x2e,
|
||||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x1c,
|
0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52,
|
||||||
0x0a, 0x03, 0x63, 0x6d, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x42, 0x61,
|
0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0xae, 0x01, 0x0a, 0x0c, 0x50, 0x76, 0x70, 0x52, 0x65, 0x61,
|
||||||
0x74, 0x74, 0x6c, 0x65, 0x43, 0x6d, 0x64, 0x52, 0x03, 0x63, 0x6d, 0x64, 0x22, 0x2b, 0x0a, 0x0d,
|
0x64, 0x79, 0x50, 0x75, 0x73, 0x68, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63,
|
||||||
0x50, 0x76, 0x70, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1a, 0x0a,
|
0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72,
|
||||||
|
0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74,
|
||||||
|
0x6c, 0x65, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74,
|
||||||
|
0x6c, 0x65, 0x69, 0x64, 0x12, 0x1f, 0x0a, 0x03, 0x72, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||||
|
0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f,
|
||||||
|
0x52, 0x03, 0x72, 0x65, 0x64, 0x12, 0x21, 0x0a, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20,
|
||||||
|
0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e,
|
||||||
|
0x66, 0x6f, 0x52, 0x04, 0x62, 0x6c, 0x75, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x6f, 0x75, 0x6e,
|
||||||
|
0x74, 0x64, 0x6f, 0x77, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63, 0x6f, 0x75,
|
||||||
|
0x6e, 0x74, 0x64, 0x6f, 0x77, 0x6e, 0x22, 0x30, 0x0a, 0x12, 0x50, 0x76, 0x70, 0x4c, 0x6f, 0x61,
|
||||||
|
0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08,
|
||||||
|
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
|
||||||
|
0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22, 0x49, 0x0a, 0x13, 0x50, 0x76, 0x70, 0x4c,
|
||||||
|
0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12,
|
||||||
|
0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||||
|
0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x69,
|
||||||
|
0x73, 0x73, 0x75, 0x63, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73,
|
||||||
|
0x75, 0x63, 0x63, 0x22, 0x4b, 0x0a, 0x19, 0x50, 0x76, 0x70, 0x4c, 0x6f, 0x61, 0x64, 0x43, 0x6f,
|
||||||
|
0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x4e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x50, 0x75, 0x73, 0x68,
|
||||||
|
0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
|
||||||
|
0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04,
|
||||||
|
0x73, 0x69, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, 0x69, 0x64, 0x65,
|
||||||
|
0x22, 0x4d, 0x0a, 0x0d, 0x50, 0x76, 0x70, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x50, 0x75, 0x73,
|
||||||
|
0x68, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68,
|
||||||
|
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50,
|
||||||
|
0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18,
|
||||||
|
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22,
|
||||||
|
0x30, 0x0a, 0x12, 0x50, 0x76, 0x70, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x43, 0x61, 0x6e, 0x63,
|
||||||
|
0x65, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
||||||
|
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69,
|
||||||
|
0x64, 0x22, 0x2d, 0x0a, 0x13, 0x50, 0x76, 0x70, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x43, 0x61,
|
||||||
|
0x6e, 0x63, 0x65, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75,
|
||||||
|
0x63, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63,
|
||||||
|
0x22, 0x5d, 0x0a, 0x0f, 0x50, 0x76, 0x70, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e,
|
||||||
|
0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18,
|
||||||
|
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12,
|
||||||
|
0x2e, 0x0a, 0x09, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01,
|
||||||
|
0x28, 0x0b, 0x32, 0x10, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x6f, 0x72, 0x6d, 0x61,
|
||||||
|
0x74, 0x69, 0x6f, 0x6e, 0x52, 0x09, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22,
|
||||||
|
0x2a, 0x0a, 0x10, 0x50, 0x76, 0x70, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52,
|
||||||
|
0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x18, 0x01, 0x20,
|
||||||
|
0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x63, 0x63, 0x22, 0x4f, 0x0a, 0x0c, 0x50,
|
||||||
|
0x76, 0x70, 0x53, 0x74, 0x61, 0x72, 0x74, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x04, 0x63,
|
||||||
|
0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0a, 0x2e, 0x45, 0x72, 0x72, 0x6f,
|
||||||
|
0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x0a, 0x04, 0x69,
|
||||||
|
0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74,
|
||||||
|
0x6c, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x49, 0x0a, 0x0d,
|
||||||
|
0x50, 0x76, 0x70, 0x4f, 0x75, 0x74, 0x43, 0x6d, 0x64, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1a, 0x0a,
|
||||||
0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||||
0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22, 0x45, 0x0a, 0x15, 0x52, 0x50, 0x43,
|
0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x03, 0x63, 0x6d, 0x64,
|
||||||
0x5f, 0x50, 0x56, 0x50, 0x54, 0x72, 0x75, 0x73, 0x74, 0x65, 0x65, 0x73, 0x68, 0x69, 0x70, 0x52,
|
0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43,
|
||||||
0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01,
|
0x6d, 0x64, 0x52, 0x03, 0x63, 0x6d, 0x64, 0x22, 0x47, 0x0a, 0x0b, 0x50, 0x76, 0x70, 0x49, 0x6e,
|
||||||
0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x10,
|
0x43, 0x6d, 0x64, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65,
|
||||||
0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64,
|
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65,
|
||||||
0x22, 0x18, 0x0a, 0x16, 0x52, 0x50, 0x43, 0x5f, 0x50, 0x56, 0x50, 0x54, 0x72, 0x75, 0x73, 0x74,
|
0x69, 0x64, 0x12, 0x1c, 0x0a, 0x03, 0x63, 0x6d, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||||
0x65, 0x65, 0x73, 0x68, 0x69, 0x70, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b,
|
0x0a, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x43, 0x6d, 0x64, 0x52, 0x03, 0x63, 0x6d, 0x64,
|
||||||
0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
0x22, 0x68, 0x0a, 0x0c, 0x50, 0x76, 0x70, 0x49, 0x6e, 0x43, 0x6d, 0x64, 0x52, 0x65, 0x73, 0x70,
|
||||||
|
0x12, 0x1e, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0a,
|
||||||
|
0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65,
|
||||||
|
0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01,
|
||||||
|
0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x03,
|
||||||
|
0x63, 0x6d, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x42, 0x61, 0x74, 0x74,
|
||||||
|
0x6c, 0x65, 0x43, 0x6d, 0x64, 0x52, 0x03, 0x63, 0x6d, 0x64, 0x22, 0x2b, 0x0a, 0x0d, 0x50, 0x76,
|
||||||
|
0x70, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x62,
|
||||||
|
0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62,
|
||||||
|
0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x22, 0x45, 0x0a, 0x15, 0x52, 0x50, 0x43, 0x5f, 0x50,
|
||||||
|
0x56, 0x50, 0x54, 0x72, 0x75, 0x73, 0x74, 0x65, 0x65, 0x73, 0x68, 0x69, 0x70, 0x52, 0x65, 0x71,
|
||||||
|
0x12, 0x1a, 0x0a, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x18, 0x01, 0x20, 0x03,
|
||||||
|
0x28, 0x09, 0x52, 0x08, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03,
|
||||||
|
0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x18,
|
||||||
|
0x0a, 0x16, 0x52, 0x50, 0x43, 0x5f, 0x50, 0x56, 0x50, 0x54, 0x72, 0x75, 0x73, 0x74, 0x65, 0x65,
|
||||||
|
0x73, 0x68, 0x69, 0x70, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62,
|
||||||
|
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@ -1221,7 +1222,7 @@ var file_pvp_pvp_msg_proto_goTypes = []interface{}{
|
|||||||
(*DBPvpBattle)(nil), // 20: DBPvpBattle
|
(*DBPvpBattle)(nil), // 20: DBPvpBattle
|
||||||
(ErrorCode)(0), // 21: ErrorCode
|
(ErrorCode)(0), // 21: ErrorCode
|
||||||
(*BattleStateInfo)(nil), // 22: BattleStateInfo
|
(*BattleStateInfo)(nil), // 22: BattleStateInfo
|
||||||
(*PvpUserInfo)(nil), // 23: PvpUserInfo
|
(*BaseUserInfo)(nil), // 23: BaseUserInfo
|
||||||
(*BattleFormation)(nil), // 24: BattleFormation
|
(*BattleFormation)(nil), // 24: BattleFormation
|
||||||
(*BattleInfo)(nil), // 25: BattleInfo
|
(*BattleInfo)(nil), // 25: BattleInfo
|
||||||
(*BattleCmd)(nil), // 26: BattleCmd
|
(*BattleCmd)(nil), // 26: BattleCmd
|
||||||
@ -1230,8 +1231,8 @@ var file_pvp_pvp_msg_proto_depIdxs = []int32{
|
|||||||
20, // 0: PvpListResp.list:type_name -> DBPvpBattle
|
20, // 0: PvpListResp.list:type_name -> DBPvpBattle
|
||||||
21, // 1: PvpIntoResp.code:type_name -> ErrorCode
|
21, // 1: PvpIntoResp.code:type_name -> ErrorCode
|
||||||
22, // 2: PvpIntoResp.info:type_name -> BattleStateInfo
|
22, // 2: PvpIntoResp.info:type_name -> BattleStateInfo
|
||||||
23, // 3: PvpReadyPush.red:type_name -> PvpUserInfo
|
23, // 3: PvpReadyPush.red:type_name -> BaseUserInfo
|
||||||
23, // 4: PvpReadyPush.blue:type_name -> PvpUserInfo
|
23, // 4: PvpReadyPush.blue:type_name -> BaseUserInfo
|
||||||
24, // 5: PvpFormationReq.formation:type_name -> BattleFormation
|
24, // 5: PvpFormationReq.formation:type_name -> BattleFormation
|
||||||
21, // 6: PvpStartPush.code:type_name -> ErrorCode
|
21, // 6: PvpStartPush.code:type_name -> ErrorCode
|
||||||
25, // 7: PvpStartPush.info:type_name -> BattleInfo
|
25, // 7: PvpStartPush.info:type_name -> BattleInfo
|
||||||
@ -1254,6 +1255,7 @@ func file_pvp_pvp_msg_proto_init() {
|
|||||||
file_pvp_pvp_db_proto_init()
|
file_pvp_pvp_db_proto_init()
|
||||||
file_battle_battle_msg_proto_init()
|
file_battle_battle_msg_proto_init()
|
||||||
file_errorcode_proto_init()
|
file_errorcode_proto_init()
|
||||||
|
file_comm_proto_init()
|
||||||
if !protoimpl.UnsafeEnabled {
|
if !protoimpl.UnsafeEnabled {
|
||||||
file_pvp_pvp_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
file_pvp_pvp_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||||
switch v := v.(*PvpListReq); i {
|
switch v := v.(*PvpListReq); i {
|
||||||
|
Loading…
Reference in New Issue
Block a user