diff --git a/cmd/v2/ui/tool_pb.go b/cmd/v2/ui/tool_pb.go index 5ebdfd2be..9076b3379 100644 --- a/cmd/v2/ui/tool_pb.go +++ b/cmd/v2/ui/tool_pb.go @@ -148,6 +148,13 @@ func (this *appPbGen) LazyInit(ptService service.PttService, obs observer.Observ }, toolWin.w) } + refreshBtn := widget.NewButtonWithIcon("", theme.ViewRefreshIcon(), func() { + this.folderList.cachedList = common.NewList("") + this.folderList.selItemIds = []string{} + this.folderList.initItem(protoDir.Text) + countLabel.SetText(fmt.Sprintf("总数:%v", this.folderList.fileTotal)) + }) + confBtn := &widget.Button{Text: "保存配置", Icon: theme.DocumentSaveIcon()} confBtn.OnTapped = func() { if err := service.GetDbService().SavePbConf(&model.PbConfModel{ @@ -164,7 +171,7 @@ func (this *appPbGen) LazyInit(ptService service.PttService, obs observer.Observ // layout c := container.NewBorder( form, - container.NewHBox(confBtn, explorBtn, genBtn, layout.NewSpacer(), countLabel), nil, nil, + container.NewHBox(confBtn, explorBtn, genBtn, refreshBtn, layout.NewSpacer(), countLabel), nil, nil, container.NewMax( container.NewVScroll(this.folderList.itemList), ), diff --git a/modules/rtask/module.go b/modules/rtask/module.go index 06d8f0a2c..07d94b775 100644 --- a/modules/rtask/module.go +++ b/modules/rtask/module.go @@ -215,6 +215,7 @@ func (this *ModuleRtask) initRtaskVerifyHandle() { } func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.TaskType, params ...int32) (code pb.ErrorCode) { + uid := session.GetUserId() if this.IsCross() { //随机任务 if _, err := this.service.AcrossClusterRpcGo( @@ -222,14 +223,14 @@ func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.T session.GetServiecTag(), comm.Service_Worker, string(comm.Rpc_ModuleRtaskSendTask), - pb.RPCRTaskReq{Uid: session.GetUserId(), TaskType: int32(rtaskType), Param: params}, + pb.RPCRTaskReq{Uid: uid, TaskType: int32(rtaskType), Param: params}, nil); err != nil { this.Errorln(err) } return } - this.Debug("任务事件触发", log.Field{"uid", session.GetUserId()}, log.Field{"taskType", rtaskType}, log.Field{"params", params}) + this.Debug("任务事件触发", log.Field{"uid", uid}, log.Field{"taskType", rtaskType}, log.Field{"params", params}) var ( err error condiId int32 @@ -239,7 +240,7 @@ func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.T for _, codi := range this.configure.getRtaskCondis(int32(rtaskType)) { v, ok := this.handleMap[codi.Id] if !ok { - this.Warn("未注册事件处理器", log.Field{"uid", session.GetUserId()}, log.Field{"condiId", codi.Id}) + this.Warn("未注册事件处理器", log.Field{"uid", uid}, log.Field{"condiId", codi.Id}) code = pb.ErrorCode_RtaskCondiNoFound return } @@ -249,7 +250,7 @@ func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.T } if condiId, err = v.find(v.cfg, params...); condiId == 0 { if err != nil { - this.Warn(errors.WithMessage(err, session.GetUserId()).Error()) + this.Warn(errors.WithMessage(err, uid).Error()) } } else { condis = append(condis, v) @@ -260,13 +261,20 @@ func (this *ModuleRtask) SendToRtask(session comm.IUserSession, rtaskType comm.T // update for _, v := range condis { if v.update != nil { - //条件未达成才更新数据 - // if code = this.CheckCondi(user.Id, v.cfg.Id); code != pb.ErrorCode_Success { - if err := v.update(session.GetUserId(), v.cfg, params...); err != nil { + if err := v.update(uid, v.cfg, params...); err != nil { code = pb.ErrorCode_DBError } - // } } + + //任务完成则推送 + if code := this.CheckCondi(uid, v.cfg.Id); code == pb.ErrorCode_Success { + if err := this.SendMsgToUser("taskcond", "finished", &pb.TaskcondFinishedPush{ + CondId: v.cfg.Id, + }, uid); err != nil { + log.Errorf("任务条件达成推送失败 err:%v", err) + } + } + } return diff --git a/modules/sociaty/api_cross_dismiss.go b/modules/sociaty/api_cross_dismiss.go index c6b5bb993..4dd9ead8a 100644 --- a/modules/sociaty/api_cross_dismiss.go +++ b/modules/sociaty/api_cross_dismiss.go @@ -15,6 +15,12 @@ func (this *apiComp) DismissCheck(session comm.IUserSession, req *pb.SociatyDism } func (this *apiComp) Dismiss(session comm.IUserSession, req *pb.SociatyDismissReq) (code pb.ErrorCode, data proto.Message) { + // 全局配置 + ggd := this.module.configure.GetGlobalConf() + if ggd == nil { + code = pb.ErrorCode_ConfigNoFound + return + } uid := session.GetUserId() sociaty := this.module.modelSociaty.getUserSociaty(uid) if sociaty.Id == "" { @@ -37,7 +43,7 @@ func (this *apiComp) Dismiss(session comm.IUserSession, req *pb.SociatyDismissRe if sociaty.DismissTime == 0 { //更新解散倒计时 - update["dismissTime"] = utils.AddHour(24).Unix() + update["dismissTime"] = utils.AddHour(int(ggd.GuildDissolutionCountDownCd)).Unix() } else { if req.Dismiss == 1 { //取消解散 if utils.IsInCDHour(int64(sociaty.DismissCD)) { @@ -45,7 +51,7 @@ func (this *apiComp) Dismiss(session comm.IUserSession, req *pb.SociatyDismissRe return } else { // 设置冷区时间 - update["dismissCD"] = utils.AddHour(72).Unix() + update["dismissCD"] = utils.AddHour(int(ggd.GuildDissolutionCd)).Unix() } //取消倒计时 update["dismissTime"] = 0 diff --git a/modules/sociaty/model_sociaty.go b/modules/sociaty/model_sociaty.go index dd3b31af9..97d8167d7 100644 --- a/modules/sociaty/model_sociaty.go +++ b/modules/sociaty/model_sociaty.go @@ -19,6 +19,7 @@ import ( "go.mongodb.org/mongo-driver/bson" "go.mongodb.org/mongo-driver/bson/primitive" "go.mongodb.org/mongo-driver/mongo" + "go.mongodb.org/mongo-driver/x/bsonx" ) type Tag string @@ -44,8 +45,11 @@ type SociatyListen struct { } func (this *ModelSociaty) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) { - this.TableName = comm.TableSociaty err = this.MCompModel.Init(service, module, comp, options) + this.TableName = comm.TableSociaty + this.DB.CreateIndex(core.SqlTable(this.TableName), mongo.IndexModel{ + Keys: bsonx.Doc{{Key: "_id", Value: bsonx.Int32(1)}}, + }) this.moduleSociaty = module.(*Sociaty) this.service = service this.EventApp = event_v2.NewApp() @@ -559,7 +563,7 @@ func (this *ModelSociaty) accuse(sociaty *pb.DBSociaty) error { } else { //更新会长的弹劾倒计时时间 update := map[string]interface{}{ - "accuseTime": utils.AddHour(int(ggd.GuildImpeachmentCountDown)), + "accuseTime": utils.AddHour(int(ggd.GuildImpeachmentCountDown)).Unix(), } return this.updateSociaty(sociaty.Id, update) } diff --git a/modules/worldtask/api.go b/modules/worldtask/api.go index 81927be14..5863aa405 100644 --- a/modules/worldtask/api.go +++ b/modules/worldtask/api.go @@ -6,6 +6,11 @@ import ( "go_dreamfactory/modules" ) +const ( + WorldtaskSubtypeStory = "story" + WorldtaskSubtypeVerifycondPush = "verifycond" +) + type apiComp struct { modules.MCompGate service base.IRPCXService diff --git a/modules/worldtask/api_battlefinish.go b/modules/worldtask/api_battlefinish.go new file mode 100644 index 000000000..4fc1467a8 --- /dev/null +++ b/modules/worldtask/api_battlefinish.go @@ -0,0 +1,17 @@ +package worldtask + +import ( + "go_dreamfactory/comm" + "go_dreamfactory/pb" + + "google.golang.org/protobuf/proto" +) + +// 战斗结束的请求 +func (this *apiComp) BattlefinishCheck(session comm.IUserSession, req *pb.WorldtaskBattleFinishReq) (code pb.ErrorCode) { + return +} + +func (this *apiComp) Battlefinish(session comm.IUserSession, req *pb.WorldtaskBattleFinishReq) (code pb.ErrorCode, data proto.Message) { + return +} diff --git a/modules/worldtask/api_story.go b/modules/worldtask/api_story.go new file mode 100644 index 000000000..483902996 --- /dev/null +++ b/modules/worldtask/api_story.go @@ -0,0 +1,79 @@ +package worldtask + +import ( + "go_dreamfactory/comm" + "go_dreamfactory/pb" + + "google.golang.org/protobuf/proto" +) + +// 剧情对话 + +func (this *apiComp) StoryCheck(session comm.IUserSession, req *pb.WorldtaskStoryReq) (code pb.ErrorCode) { + if req.TaskId == 0 { + code = pb.ErrorCode_ReqParameterError + } + return +} + +func (this *apiComp) Story(session comm.IUserSession, req *pb.WorldtaskStoryReq) (code pb.ErrorCode, data proto.Message) { + if code = this.StoryCheck(session, req); code != pb.ErrorCode_Success { + return + } + + uid := session.GetUserId() + gwtConf, err := this.module.configure.getWorldtaskCfg() + if err != nil || gwtConf == nil { + code = pb.ErrorCode_ConfigNoFound + return + } + + // 获取用户信息 + user := this.module.ModuleUser.GetUser(uid) + if user == nil { + code = pb.ErrorCode_UserSessionNobeing + return + } + + // 当前任务配置 + curTaskConf, ok := gwtConf.GetDataMap()[req.TaskId] + if !ok { + code = pb.ErrorCode_ConfigNoFound + return + } + rsp := &pb.WorldtaskStoryResp{} + + // 判断玩家等级要求 + if user.Lv < curTaskConf.Lock { + code = pb.ErrorCode_WorldtaskLvNotEnough + return + } + + // 下一个任务 + if curTaskConf.Ontxe == 0 && curTaskConf.AutoAccept == 0 { + rsp.NextTaskId = 0 + } else if curTaskConf.Ontxe != 0 && curTaskConf.AutoAccept == 1 { + rsp.NextTaskId = curTaskConf.IdAfter + } + + // 当前玩家世界任务 + userTask, err := this.module.modelWorldtask.getWorldtask(uid) + if err != nil { + code = pb.ErrorCode_DBError + return + } + if userTask.Uid == "" { + userTask.Uid = uid + } + + // 完成任务 + if err := this.module.modelWorldtask.finishTask(req.TaskId, userTask); err != nil { + code = pb.ErrorCode_WorldtaskStory + return + } + + if err := session.SendMsg(string(this.module.GetType()), WorldtaskSubtypeStory, rsp); err != nil { + code = pb.ErrorCode_SystemError + } + return +} diff --git a/modules/worldtask/model_worldtask.go b/modules/worldtask/model_worldtask.go index 15456ec1b..9e4db5c3b 100644 --- a/modules/worldtask/model_worldtask.go +++ b/modules/worldtask/model_worldtask.go @@ -4,6 +4,9 @@ import ( "go_dreamfactory/comm" "go_dreamfactory/lego/core" "go_dreamfactory/modules" + "go_dreamfactory/pb" + + "go.mongodb.org/mongo-driver/mongo" ) type ModelWorldtask struct { @@ -17,3 +20,34 @@ func (this *ModelWorldtask) Init(service core.IService, module core.IModule, com this.moduleWorldtask = module.(*Worldtask) return } + +func (this *ModelWorldtask) getWorldtask(uid string) (*pb.DBWorldtask, error) { + d := &pb.DBWorldtask{} + if err := this.Get(uid, d); err != nil { + if err != mongo.ErrNoDocuments { + return d, err + } + } + return d, nil +} + +// 完成任务 +func (this *ModelWorldtask) finishTask(taskId int32, task *pb.DBWorldtask) error { + if len(task.TaskList) == 0 { + task.TaskList = append(task.TaskList, &pb.Worldtask{ + TaskId: taskId, + Status: 1, //完成 + }) + } else { + for _, v := range task.TaskList { + if v.TaskId == taskId { + v.Status = 1 //完成 + } + } + } + + update := map[string]interface{}{ + "taskList": task.TaskList, + } + return this.Change(task.Uid, update) +} diff --git a/modules/worldtask/module.go b/modules/worldtask/module.go index 0fc23e088..f7389dc17 100644 --- a/modules/worldtask/module.go +++ b/modules/worldtask/module.go @@ -9,9 +9,10 @@ import ( type Worldtask struct { modules.ModuleBase - api *apiComp - service base.IRPCXService - configure *configureComp + api *apiComp + service base.IRPCXService + configure *configureComp + modelWorldtask *ModelWorldtask } func NewModule() core.IModule { @@ -21,6 +22,14 @@ func (this *Worldtask) Init(service core.IService, module core.IModule, options err = this.ModuleBase.Init(service, module, options) return } + +func (this *Worldtask) OnInstallComp() { + this.ModuleBase.OnInstallComp() + this.api = this.RegisterComp(new(apiComp)).(*apiComp) + this.modelWorldtask = this.RegisterComp(new(ModelWorldtask)).(*ModelWorldtask) + this.configure = this.RegisterComp(new(configureComp)).(*configureComp) + +} func (this *Worldtask) GetType() core.M_Modules { return comm.ModuleWorldtask } diff --git a/pb/errorcode.pb.go b/pb/errorcode.pb.go index 4b5c2576e..0a5557943 100644 --- a/pb/errorcode.pb.go +++ b/pb/errorcode.pb.go @@ -259,6 +259,9 @@ const ( ErrorCode_GrowtaskAdvReceive ErrorCode = 3602 //进阶奖励领取失败 // pay ErrorCode_PayBuyNumNotEnough ErrorCode = 3701 //支付次数不足 + // worldtask + ErrorCode_WorldtaskStory ErrorCode = 3801 //剧情任务失败 + ErrorCode_WorldtaskLvNotEnough ErrorCode = 3802 //等级不满足 ) // Enum value maps for ErrorCode. @@ -474,6 +477,8 @@ var ( 3601: "GrowtaskReceive", 3602: "GrowtaskAdvReceive", 3701: "PayBuyNumNotEnough", + 3801: "WorldtaskStory", + 3802: "WorldtaskLvNotEnough", } ErrorCode_value = map[string]int32{ "Success": 0, @@ -686,6 +691,8 @@ var ( "GrowtaskReceive": 3601, "GrowtaskAdvReceive": 3602, "PayBuyNumNotEnough": 3701, + "WorldtaskStory": 3801, + "WorldtaskLvNotEnough": 3802, } ) @@ -720,7 +727,7 @@ var File_errorcode_proto protoreflect.FileDescriptor var file_errorcode_proto_rawDesc = []byte{ 0x0a, 0x0f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x2a, 0xa3, 0x25, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, + 0x6f, 0x2a, 0xd3, 0x25, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x4e, 0x6f, 0x46, 0x69, 0x6e, 0x64, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x10, 0x0a, 0x12, 0x1b, 0x0a, 0x17, 0x4e, 0x6f, 0x46, 0x69, 0x6e, 0x64, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, @@ -1018,7 +1025,10 @@ var file_errorcode_proto_rawDesc = []byte{ 0x76, 0x65, 0x10, 0x91, 0x1c, 0x12, 0x17, 0x0a, 0x12, 0x47, 0x72, 0x6f, 0x77, 0x74, 0x61, 0x73, 0x6b, 0x41, 0x64, 0x76, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x10, 0x92, 0x1c, 0x12, 0x17, 0x0a, 0x12, 0x50, 0x61, 0x79, 0x42, 0x75, 0x79, 0x4e, 0x75, 0x6d, 0x4e, 0x6f, 0x74, 0x45, 0x6e, - 0x6f, 0x75, 0x67, 0x68, 0x10, 0xf5, 0x1c, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, + 0x6f, 0x75, 0x67, 0x68, 0x10, 0xf5, 0x1c, 0x12, 0x13, 0x0a, 0x0e, 0x57, 0x6f, 0x72, 0x6c, 0x64, + 0x74, 0x61, 0x73, 0x6b, 0x53, 0x74, 0x6f, 0x72, 0x79, 0x10, 0xd9, 0x1d, 0x12, 0x19, 0x0a, 0x14, + 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x4c, 0x76, 0x4e, 0x6f, 0x74, 0x45, 0x6e, + 0x6f, 0x75, 0x67, 0x68, 0x10, 0xda, 0x1d, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } diff --git a/pb/taskcond_msg.pb.go b/pb/taskcond_msg.pb.go new file mode 100644 index 000000000..9a95d62c1 --- /dev/null +++ b/pb/taskcond_msg.pb.go @@ -0,0 +1,143 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.0 +// protoc v3.20.0 +// source: taskcond/taskcond_msg.proto + +package pb + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +//任务完成条件推送 +type TaskcondFinishedPush struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + CondId int32 `protobuf:"varint,1,opt,name=condId,proto3" json:"condId"` //任务条件ID +} + +func (x *TaskcondFinishedPush) Reset() { + *x = TaskcondFinishedPush{} + if protoimpl.UnsafeEnabled { + mi := &file_taskcond_taskcond_msg_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *TaskcondFinishedPush) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*TaskcondFinishedPush) ProtoMessage() {} + +func (x *TaskcondFinishedPush) ProtoReflect() protoreflect.Message { + mi := &file_taskcond_taskcond_msg_proto_msgTypes[0] + 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 TaskcondFinishedPush.ProtoReflect.Descriptor instead. +func (*TaskcondFinishedPush) Descriptor() ([]byte, []int) { + return file_taskcond_taskcond_msg_proto_rawDescGZIP(), []int{0} +} + +func (x *TaskcondFinishedPush) GetCondId() int32 { + if x != nil { + return x.CondId + } + return 0 +} + +var File_taskcond_taskcond_msg_proto protoreflect.FileDescriptor + +var file_taskcond_taskcond_msg_proto_rawDesc = []byte{ + 0x0a, 0x1b, 0x74, 0x61, 0x73, 0x6b, 0x63, 0x6f, 0x6e, 0x64, 0x2f, 0x74, 0x61, 0x73, 0x6b, 0x63, + 0x6f, 0x6e, 0x64, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x2e, 0x0a, + 0x14, 0x54, 0x61, 0x73, 0x6b, 0x63, 0x6f, 0x6e, 0x64, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x65, + 0x64, 0x50, 0x75, 0x73, 0x68, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x64, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x64, 0x49, 0x64, 0x42, 0x06, 0x5a, + 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_taskcond_taskcond_msg_proto_rawDescOnce sync.Once + file_taskcond_taskcond_msg_proto_rawDescData = file_taskcond_taskcond_msg_proto_rawDesc +) + +func file_taskcond_taskcond_msg_proto_rawDescGZIP() []byte { + file_taskcond_taskcond_msg_proto_rawDescOnce.Do(func() { + file_taskcond_taskcond_msg_proto_rawDescData = protoimpl.X.CompressGZIP(file_taskcond_taskcond_msg_proto_rawDescData) + }) + return file_taskcond_taskcond_msg_proto_rawDescData +} + +var file_taskcond_taskcond_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_taskcond_taskcond_msg_proto_goTypes = []interface{}{ + (*TaskcondFinishedPush)(nil), // 0: TaskcondFinishedPush +} +var file_taskcond_taskcond_msg_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_taskcond_taskcond_msg_proto_init() } +func file_taskcond_taskcond_msg_proto_init() { + if File_taskcond_taskcond_msg_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_taskcond_taskcond_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*TaskcondFinishedPush); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_taskcond_taskcond_msg_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_taskcond_taskcond_msg_proto_goTypes, + DependencyIndexes: file_taskcond_taskcond_msg_proto_depIdxs, + MessageInfos: file_taskcond_taskcond_msg_proto_msgTypes, + }.Build() + File_taskcond_taskcond_msg_proto = out.File + file_taskcond_taskcond_msg_proto_rawDesc = nil + file_taskcond_taskcond_msg_proto_goTypes = nil + file_taskcond_taskcond_msg_proto_depIdxs = nil +} diff --git a/pb/worldtask_db.pb.go b/pb/worldtask_db.pb.go new file mode 100644 index 000000000..13fa6ba5b --- /dev/null +++ b/pb/worldtask_db.pb.go @@ -0,0 +1,225 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.0 +// protoc v3.20.0 +// source: worldtask/worldtask_db.proto + +package pb + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type DBWorldtask struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid" bson:"uid"` //玩家ID + TaskList []*Worldtask `protobuf:"bytes,2,rep,name=taskList,proto3" json:"taskList" bson:"taskList"` // 任务列表 +} + +func (x *DBWorldtask) Reset() { + *x = DBWorldtask{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_db_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DBWorldtask) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DBWorldtask) ProtoMessage() {} + +func (x *DBWorldtask) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_db_proto_msgTypes[0] + 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 DBWorldtask.ProtoReflect.Descriptor instead. +func (*DBWorldtask) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_db_proto_rawDescGZIP(), []int{0} +} + +func (x *DBWorldtask) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *DBWorldtask) GetTaskList() []*Worldtask { + if x != nil { + return x.TaskList + } + return nil +} + +type Worldtask struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + TaskId int32 `protobuf:"varint,1,opt,name=taskId,proto3" json:"taskId" bson:"taskIds"` //任务ID + Status int32 `protobuf:"varint,2,opt,name=status,proto3" json:"status" bson:"status"` //任务状态 0 未完成 1已完成 +} + +func (x *Worldtask) Reset() { + *x = Worldtask{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_db_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Worldtask) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Worldtask) ProtoMessage() {} + +func (x *Worldtask) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_db_proto_msgTypes[1] + 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 Worldtask.ProtoReflect.Descriptor instead. +func (*Worldtask) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_db_proto_rawDescGZIP(), []int{1} +} + +func (x *Worldtask) GetTaskId() int32 { + if x != nil { + return x.TaskId + } + return 0 +} + +func (x *Worldtask) GetStatus() int32 { + if x != nil { + return x.Status + } + return 0 +} + +var File_worldtask_worldtask_db_proto protoreflect.FileDescriptor + +var file_worldtask_worldtask_db_proto_rawDesc = []byte{ + 0x0a, 0x1c, 0x77, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x2f, 0x77, 0x6f, 0x72, 0x6c, + 0x64, 0x74, 0x61, 0x73, 0x6b, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x47, + 0x0a, 0x0b, 0x44, 0x42, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x12, 0x10, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x26, 0x0a, 0x08, 0x74, 0x61, 0x73, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x0a, 0x2e, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x52, 0x08, 0x74, + 0x61, 0x73, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x3b, 0x0a, 0x09, 0x57, 0x6f, 0x72, 0x6c, 0x64, + 0x74, 0x61, 0x73, 0x6b, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x74, + 0x61, 0x74, 0x75, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_worldtask_worldtask_db_proto_rawDescOnce sync.Once + file_worldtask_worldtask_db_proto_rawDescData = file_worldtask_worldtask_db_proto_rawDesc +) + +func file_worldtask_worldtask_db_proto_rawDescGZIP() []byte { + file_worldtask_worldtask_db_proto_rawDescOnce.Do(func() { + file_worldtask_worldtask_db_proto_rawDescData = protoimpl.X.CompressGZIP(file_worldtask_worldtask_db_proto_rawDescData) + }) + return file_worldtask_worldtask_db_proto_rawDescData +} + +var file_worldtask_worldtask_db_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_worldtask_worldtask_db_proto_goTypes = []interface{}{ + (*DBWorldtask)(nil), // 0: DBWorldtask + (*Worldtask)(nil), // 1: Worldtask +} +var file_worldtask_worldtask_db_proto_depIdxs = []int32{ + 1, // 0: DBWorldtask.taskList:type_name -> Worldtask + 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 extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_worldtask_worldtask_db_proto_init() } +func file_worldtask_worldtask_db_proto_init() { + if File_worldtask_worldtask_db_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_worldtask_worldtask_db_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DBWorldtask); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_worldtask_worldtask_db_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Worldtask); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_worldtask_worldtask_db_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_worldtask_worldtask_db_proto_goTypes, + DependencyIndexes: file_worldtask_worldtask_db_proto_depIdxs, + MessageInfos: file_worldtask_worldtask_db_proto_msgTypes, + }.Build() + File_worldtask_worldtask_db_proto = out.File + file_worldtask_worldtask_db_proto_rawDesc = nil + file_worldtask_worldtask_db_proto_goTypes = nil + file_worldtask_worldtask_db_proto_depIdxs = nil +} diff --git a/pb/worldtask_msg.pb.go b/pb/worldtask_msg.pb.go new file mode 100644 index 000000000..5f2830dc3 --- /dev/null +++ b/pb/worldtask_msg.pb.go @@ -0,0 +1,367 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.0 +// protoc v3.20.0 +// source: worldtask/worldtask_msg.proto + +package pb + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// 剧情对话结束请求 +type WorldtaskStoryReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + TaskId int32 `protobuf:"varint,1,opt,name=taskId,proto3" json:"taskId"` //任务ID +} + +func (x *WorldtaskStoryReq) Reset() { + *x = WorldtaskStoryReq{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WorldtaskStoryReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WorldtaskStoryReq) ProtoMessage() {} + +func (x *WorldtaskStoryReq) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[0] + 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 WorldtaskStoryReq.ProtoReflect.Descriptor instead. +func (*WorldtaskStoryReq) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_msg_proto_rawDescGZIP(), []int{0} +} + +func (x *WorldtaskStoryReq) GetTaskId() int32 { + if x != nil { + return x.TaskId + } + return 0 +} + +type WorldtaskStoryResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + NextTaskId int32 `protobuf:"varint,1,opt,name=nextTaskId,proto3" json:"nextTaskId"` //任务ID +} + +func (x *WorldtaskStoryResp) Reset() { + *x = WorldtaskStoryResp{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WorldtaskStoryResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WorldtaskStoryResp) ProtoMessage() {} + +func (x *WorldtaskStoryResp) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[1] + 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 WorldtaskStoryResp.ProtoReflect.Descriptor instead. +func (*WorldtaskStoryResp) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_msg_proto_rawDescGZIP(), []int{1} +} + +func (x *WorldtaskStoryResp) GetNextTaskId() int32 { + if x != nil { + return x.NextTaskId + } + return 0 +} + +// 战斗完成 +type WorldtaskBattleFinishReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID + RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID + ChooseId int32 `protobuf:"varint,3,opt,name=chooseId,proto3" json:"chooseId"` //选项配置ID +} + +func (x *WorldtaskBattleFinishReq) Reset() { + *x = WorldtaskBattleFinishReq{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WorldtaskBattleFinishReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WorldtaskBattleFinishReq) ProtoMessage() {} + +func (x *WorldtaskBattleFinishReq) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[2] + 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 WorldtaskBattleFinishReq.ProtoReflect.Descriptor instead. +func (*WorldtaskBattleFinishReq) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_msg_proto_rawDescGZIP(), []int{2} +} + +func (x *WorldtaskBattleFinishReq) GetRtaskId() int32 { + if x != nil { + return x.RtaskId + } + return 0 +} + +func (x *WorldtaskBattleFinishReq) GetRtaskSubId() int32 { + if x != nil { + return x.RtaskSubId + } + return 0 +} + +func (x *WorldtaskBattleFinishReq) GetChooseId() int32 { + if x != nil { + return x.ChooseId + } + return 0 +} + +type WorldtaskBattleFinishResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + RtaskId int32 `protobuf:"varint,1,opt,name=rtaskId,proto3" json:"rtaskId"` //任务ID + RtaskSubId int32 `protobuf:"varint,2,opt,name=rtaskSubId,proto3" json:"rtaskSubId"` //支线任务ID +} + +func (x *WorldtaskBattleFinishResp) Reset() { + *x = WorldtaskBattleFinishResp{} + if protoimpl.UnsafeEnabled { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WorldtaskBattleFinishResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WorldtaskBattleFinishResp) ProtoMessage() {} + +func (x *WorldtaskBattleFinishResp) ProtoReflect() protoreflect.Message { + mi := &file_worldtask_worldtask_msg_proto_msgTypes[3] + 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 WorldtaskBattleFinishResp.ProtoReflect.Descriptor instead. +func (*WorldtaskBattleFinishResp) Descriptor() ([]byte, []int) { + return file_worldtask_worldtask_msg_proto_rawDescGZIP(), []int{3} +} + +func (x *WorldtaskBattleFinishResp) GetRtaskId() int32 { + if x != nil { + return x.RtaskId + } + return 0 +} + +func (x *WorldtaskBattleFinishResp) GetRtaskSubId() int32 { + if x != nil { + return x.RtaskSubId + } + return 0 +} + +var File_worldtask_worldtask_msg_proto protoreflect.FileDescriptor + +var file_worldtask_worldtask_msg_proto_rawDesc = []byte{ + 0x0a, 0x1d, 0x77, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x2f, 0x77, 0x6f, 0x72, 0x6c, + 0x64, 0x74, 0x61, 0x73, 0x6b, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 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, 0x22, 0x2b, 0x0a, 0x11, 0x57, 0x6f, 0x72, 0x6c, + 0x64, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, + 0x06, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x22, 0x34, 0x0a, 0x12, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, + 0x73, 0x6b, 0x53, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x6e, + 0x65, 0x78, 0x74, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, + 0x0a, 0x6e, 0x65, 0x78, 0x74, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x22, 0x70, 0x0a, 0x18, 0x57, + 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x46, 0x69, + 0x6e, 0x69, 0x73, 0x68, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x49, + 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, 0x49, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x08, 0x63, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x49, 0x64, 0x22, 0x55, 0x0a, + 0x19, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x74, 0x61, 0x73, 0x6b, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, + 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x74, + 0x61, 0x73, 0x6b, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x72, 0x74, 0x61, + 0x73, 0x6b, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, 0x75, 0x62, + 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x74, 0x61, 0x73, 0x6b, 0x53, + 0x75, 0x62, 0x49, 0x64, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_worldtask_worldtask_msg_proto_rawDescOnce sync.Once + file_worldtask_worldtask_msg_proto_rawDescData = file_worldtask_worldtask_msg_proto_rawDesc +) + +func file_worldtask_worldtask_msg_proto_rawDescGZIP() []byte { + file_worldtask_worldtask_msg_proto_rawDescOnce.Do(func() { + file_worldtask_worldtask_msg_proto_rawDescData = protoimpl.X.CompressGZIP(file_worldtask_worldtask_msg_proto_rawDescData) + }) + return file_worldtask_worldtask_msg_proto_rawDescData +} + +var file_worldtask_worldtask_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_worldtask_worldtask_msg_proto_goTypes = []interface{}{ + (*WorldtaskStoryReq)(nil), // 0: WorldtaskStoryReq + (*WorldtaskStoryResp)(nil), // 1: WorldtaskStoryResp + (*WorldtaskBattleFinishReq)(nil), // 2: WorldtaskBattleFinishReq + (*WorldtaskBattleFinishResp)(nil), // 3: WorldtaskBattleFinishResp +} +var file_worldtask_worldtask_msg_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_worldtask_worldtask_msg_proto_init() } +func file_worldtask_worldtask_msg_proto_init() { + if File_worldtask_worldtask_msg_proto != nil { + return + } + file_battle_battle_msg_proto_init() + if !protoimpl.UnsafeEnabled { + file_worldtask_worldtask_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WorldtaskStoryReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_worldtask_worldtask_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WorldtaskStoryResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_worldtask_worldtask_msg_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WorldtaskBattleFinishReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_worldtask_worldtask_msg_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WorldtaskBattleFinishResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_worldtask_worldtask_msg_proto_rawDesc, + NumEnums: 0, + NumMessages: 4, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_worldtask_worldtask_msg_proto_goTypes, + DependencyIndexes: file_worldtask_worldtask_msg_proto_depIdxs, + MessageInfos: file_worldtask_worldtask_msg_proto_msgTypes, + }.Build() + File_worldtask_worldtask_msg_proto = out.File + file_worldtask_worldtask_msg_proto_rawDesc = nil + file_worldtask_worldtask_msg_proto_goTypes = nil + file_worldtask_worldtask_msg_proto_depIdxs = nil +}