章节总奖励领取
This commit is contained in:
parent
b9ad48eb9a
commit
8f8aadc2bd
98
modules/mainline/api_taskchaptereward.go
Normal file
98
modules/mainline/api_taskchaptereward.go
Normal file
@ -0,0 +1,98 @@
|
||||
package mainline
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/pb"
|
||||
cfg "go_dreamfactory/sys/configure/structs"
|
||||
)
|
||||
|
||||
// 参数校验
|
||||
func (this *apiComp) TaskChapteRewardCheck(session comm.IUserSession, req *pb.MainlineTaskChapteRewardReq) (errdata *pb.ErrorData) {
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// 章节任务奖励领取
|
||||
func (this *apiComp) TaskChapteReward(session comm.IUserSession, req *pb.MainlineTaskChapteRewardReq) (errdata *pb.ErrorData) {
|
||||
var (
|
||||
dtask *pb.DBMainTask
|
||||
conf *cfg.GameMainChapterData
|
||||
|
||||
award []*pb.UserAtno
|
||||
err error
|
||||
)
|
||||
if errdata = this.TaskChapteRewardCheck(session, req); errdata != nil {
|
||||
return
|
||||
}
|
||||
|
||||
if conf, err = this.module.configure.GetMainChapterConf(req.Chapteid); err != nil {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_DBError,
|
||||
Title: pb.ErrorCode_DBError.ToString(),
|
||||
Message: err.Error(),
|
||||
}
|
||||
return
|
||||
}
|
||||
if dtask, err = this.module.modelTask.getUserDTasks(session.GetUserId()); err != nil {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_DBError,
|
||||
Title: pb.ErrorCode_DBError.ToString(),
|
||||
Message: err.Error(),
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
if _, ok := dtask.Reward[req.Chapteid]; ok {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ReqParameterError,
|
||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
||||
Message: fmt.Sprintf("Chapteid %d received", req.Chapteid),
|
||||
}
|
||||
return
|
||||
}
|
||||
if taskids := this.module.configure.getgroupTasks(req.Chapteid); len(taskids) > 0 {
|
||||
for _, v := range taskids {
|
||||
if progress, err := this.module.ModuleBuried.CheckCondition(session.GetUserId(), v.Taskid); err == nil {
|
||||
for _, v := range progress {
|
||||
if v.State == pb.BuriedItemFinishState_buried_unfinish {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ReqParameterError,
|
||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
||||
Message: "task no finish",
|
||||
}
|
||||
return
|
||||
}
|
||||
}
|
||||
} else {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ExternalModule,
|
||||
Title: pb.ErrorCode_ExternalModule.ToString(),
|
||||
Message: comm.NewExternalModuleErr("Buried", "CheckCondition", v.Taskid).Error(),
|
||||
}
|
||||
return
|
||||
}
|
||||
}
|
||||
} else { // 配置出错
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_ReqParameterError,
|
||||
Title: pb.ErrorCode_ReqParameterError.ToString(),
|
||||
Message: fmt.Sprintf("getgroupTasks %d err", req.Chapteid),
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
if errdata, award = this.module.DispenseAtno(session, []*cfg.Gameatn{conf.Reward}, true); errdata != nil {
|
||||
return
|
||||
}
|
||||
|
||||
dtask.Reward[req.Chapteid] = true // 更新数据
|
||||
this.module.modelTask.Change(session.GetUserId(), map[string]interface{}{
|
||||
"reward": dtask.Reward,
|
||||
})
|
||||
session.SendMsg(string(this.module.GetType()), "taskreceive", &pb.MainlineTaskChapteRewardResp{
|
||||
Task: dtask,
|
||||
Award: award,
|
||||
})
|
||||
return
|
||||
}
|
@ -41,6 +41,6 @@ func (this *apiComp) TaskInfo(session comm.IUserSession, req *pb.MainlineTaskInf
|
||||
return
|
||||
}
|
||||
|
||||
session.SendMsg(string(this.module.GetType()), "taskinfo", &pb.MainlineTaskInfoResp{Conlds: progress, Tasks: dtask.Tasks})
|
||||
session.SendMsg(string(this.module.GetType()), "taskinfo", &pb.MainlineTaskInfoResp{Conlds: progress, Tasks: dtask})
|
||||
return
|
||||
}
|
||||
|
@ -13,7 +13,6 @@ func (this *apiComp) TaskReceiveCheck(session comm.IUserSession, req *pb.Mainlin
|
||||
return
|
||||
}
|
||||
|
||||
// /获取自己的排行榜信息
|
||||
func (this *apiComp) TaskReceive(session comm.IUserSession, req *pb.MainlineTaskReceiveReq) (errdata *pb.ErrorData) {
|
||||
var (
|
||||
dtask *pb.DBMainTask
|
||||
@ -27,7 +26,7 @@ func (this *apiComp) TaskReceive(session comm.IUserSession, req *pb.MainlineTask
|
||||
return
|
||||
}
|
||||
|
||||
if conf, err = this.module.configure.getGameVenturegiftsTask(req.Id); err != nil {
|
||||
if conf, err = this.module.configure.getMainAchievementTask(req.Id); err != nil {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_DBError,
|
||||
Title: pb.ErrorCode_DBError.ToString(),
|
||||
@ -53,7 +52,7 @@ func (this *apiComp) TaskReceive(session comm.IUserSession, req *pb.MainlineTask
|
||||
return
|
||||
}
|
||||
|
||||
if progress, err = this.module.ModuleBuried.CheckCondition(session.GetUserId(), conf.Id); err != nil {
|
||||
if progress, err = this.module.ModuleBuried.CheckCondition(session.GetUserId(), conf.Taskid); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -42,6 +42,7 @@ func (this *configureComp) Init(service core.IService, module core.IModule, comp
|
||||
configure.RegisterConfigure(game_mainstage, cfg.NewGameMainStage, this.updateMlineStage)
|
||||
configure.RegisterConfigure(game_mainstarreward, cfg.NewGameMainStarreward, this.updateMlineReward)
|
||||
configure.RegisterConfigure(game_mainachievement, cfg.NewGameMainAchievement, this.GameMainAchievement)
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
@ -220,7 +221,15 @@ func (this *configureComp) gettasks() map[int32]struct{} {
|
||||
defer this.lock.RUnlock()
|
||||
return this.tasks
|
||||
}
|
||||
func (this *configureComp) getGameVenturegiftsTask(id int32) (conf *cfg.GameMainAchievementData, err error) {
|
||||
|
||||
func (this *configureComp) getgroupTasks(gropp int32) []*cfg.GameMainAchievementData {
|
||||
this.lock.RLock()
|
||||
defer this.lock.RUnlock()
|
||||
return this.groupTasks[gropp]
|
||||
}
|
||||
|
||||
// 获取主线章节任务
|
||||
func (this *configureComp) getMainAchievementTask(id int32) (conf *cfg.GameMainAchievementData, err error) {
|
||||
var (
|
||||
v interface{}
|
||||
ok bool
|
||||
|
@ -258,6 +258,7 @@ type DBMainTask struct {
|
||||
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"`
|
||||
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid"`
|
||||
Tasks map[int32]int32 `protobuf:"bytes,3,rep,name=tasks,proto3" json:"tasks" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"`
|
||||
Reward map[int32]bool `protobuf:"bytes,4,rep,name=reward,proto3" json:"reward" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 章节奖励 key 章节
|
||||
}
|
||||
|
||||
func (x *DBMainTask) Reset() {
|
||||
@ -313,6 +314,13 @@ func (x *DBMainTask) GetTasks() map[int32]int32 {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *DBMainTask) GetReward() map[int32]bool {
|
||||
if x != nil {
|
||||
return x.Reward
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_mainline_mainline_db_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_mainline_mainline_db_proto_rawDesc = []byte{
|
||||
@ -395,17 +403,24 @@ var file_mainline_mainline_db_proto_rawDesc = []byte{
|
||||
0x63, 0x6b, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01,
|
||||
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, 0x22, 0x96, 0x01, 0x0a, 0x0a, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x61,
|
||||
0x02, 0x38, 0x01, 0x22, 0x82, 0x02, 0x0a, 0x0a, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x61,
|
||||
0x73, 0x6b, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 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, 0x2c, 0x0a, 0x05, 0x74, 0x61, 0x73, 0x6b, 0x73, 0x18, 0x03, 0x20,
|
||||
0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x61, 0x73, 0x6b,
|
||||
0x2e, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x74, 0x61, 0x73,
|
||||
0x6b, 0x73, 0x1a, 0x38, 0x0a, 0x0a, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79,
|
||||
0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 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,
|
||||
0x6b, 0x73, 0x12, 0x2f, 0x0a, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x18, 0x04, 0x20, 0x03,
|
||||
0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x2e,
|
||||
0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x72, 0x65, 0x77,
|
||||
0x61, 0x72, 0x64, 0x1a, 0x38, 0x0a, 0x0a, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x45, 0x6e, 0x74, 0x72,
|
||||
0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 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, 0x1a, 0x39, 0x0a,
|
||||
0x0b, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
|
||||
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14,
|
||||
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 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 (
|
||||
@ -420,7 +435,7 @@ func file_mainline_mainline_db_proto_rawDescGZIP() []byte {
|
||||
return file_mainline_mainline_db_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_mainline_mainline_db_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
|
||||
var file_mainline_mainline_db_proto_msgTypes = make([]protoimpl.MessageInfo, 15)
|
||||
var file_mainline_mainline_db_proto_goTypes = []interface{}{
|
||||
(*DBMainline)(nil), // 0: DBMainline
|
||||
(*DBMainlineAward)(nil), // 1: DBMainlineAward
|
||||
@ -436,6 +451,7 @@ var file_mainline_mainline_db_proto_goTypes = []interface{}{
|
||||
nil, // 11: DBMainlineShop.BuytimeEntry
|
||||
nil, // 12: DBMainlineShop.UnlockEntry
|
||||
nil, // 13: DBMainTask.TasksEntry
|
||||
nil, // 14: DBMainTask.RewardEntry
|
||||
}
|
||||
var file_mainline_mainline_db_proto_depIdxs = []int32{
|
||||
4, // 0: DBMainline.lastlevel:type_name -> DBMainline.LastlevelEntry
|
||||
@ -448,14 +464,15 @@ var file_mainline_mainline_db_proto_depIdxs = []int32{
|
||||
11, // 7: DBMainlineShop.buytime:type_name -> DBMainlineShop.BuytimeEntry
|
||||
12, // 8: DBMainlineShop.unlock:type_name -> DBMainlineShop.UnlockEntry
|
||||
13, // 9: DBMainTask.tasks:type_name -> DBMainTask.TasksEntry
|
||||
1, // 10: DBMainline.ChapterawardEntry.value:type_name -> DBMainlineAward
|
||||
1, // 11: DBMainline.ExploreawardEntry.value:type_name -> DBMainlineAward
|
||||
1, // 12: DBMainline.GroupawardEntry.value:type_name -> DBMainlineAward
|
||||
13, // [13:13] is the sub-list for method output_type
|
||||
13, // [13:13] is the sub-list for method input_type
|
||||
13, // [13:13] is the sub-list for extension type_name
|
||||
13, // [13:13] is the sub-list for extension extendee
|
||||
0, // [0:13] is the sub-list for field type_name
|
||||
14, // 10: DBMainTask.reward:type_name -> DBMainTask.RewardEntry
|
||||
1, // 11: DBMainline.ChapterawardEntry.value:type_name -> DBMainlineAward
|
||||
1, // 12: DBMainline.ExploreawardEntry.value:type_name -> DBMainlineAward
|
||||
1, // 13: DBMainline.GroupawardEntry.value:type_name -> DBMainlineAward
|
||||
14, // [14:14] is the sub-list for method output_type
|
||||
14, // [14:14] is the sub-list for method input_type
|
||||
14, // [14:14] is the sub-list for extension type_name
|
||||
14, // [14:14] is the sub-list for extension extendee
|
||||
0, // [0:14] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_mainline_mainline_db_proto_init() }
|
||||
@ -519,7 +536,7 @@ func file_mainline_mainline_db_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_mainline_mainline_db_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 14,
|
||||
NumMessages: 15,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
|
@ -912,7 +912,7 @@ type MainlineTaskInfoResp struct {
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Conlds []*ConIProgress `protobuf:"bytes,1,rep,name=conlds,proto3" json:"conlds"` //子任务进度数据
|
||||
Tasks map[int32]int32 `protobuf:"bytes,2,rep,name=tasks,proto3" json:"tasks" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"`
|
||||
Tasks *DBMainTask `protobuf:"bytes,2,opt,name=tasks,proto3" json:"tasks"`
|
||||
}
|
||||
|
||||
func (x *MainlineTaskInfoResp) Reset() {
|
||||
@ -954,7 +954,7 @@ func (x *MainlineTaskInfoResp) GetConlds() []*ConIProgress {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *MainlineTaskInfoResp) GetTasks() map[int32]int32 {
|
||||
func (x *MainlineTaskInfoResp) GetTasks() *DBMainTask {
|
||||
if x != nil {
|
||||
return x.Tasks
|
||||
}
|
||||
@ -1065,6 +1065,109 @@ func (x *MainlineTaskReceiveResp) GetAward() []*UserAtno {
|
||||
return nil
|
||||
}
|
||||
|
||||
type MainlineTaskChapteRewardReq struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Chapteid int32 `protobuf:"varint,1,opt,name=chapteid,proto3" json:"chapteid"`
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardReq) Reset() {
|
||||
*x = MainlineTaskChapteRewardReq{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_mainline_mainline_msg_proto_msgTypes[19]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardReq) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MainlineTaskChapteRewardReq) ProtoMessage() {}
|
||||
|
||||
func (x *MainlineTaskChapteRewardReq) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_mainline_mainline_msg_proto_msgTypes[19]
|
||||
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 MainlineTaskChapteRewardReq.ProtoReflect.Descriptor instead.
|
||||
func (*MainlineTaskChapteRewardReq) Descriptor() ([]byte, []int) {
|
||||
return file_mainline_mainline_msg_proto_rawDescGZIP(), []int{19}
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardReq) GetChapteid() int32 {
|
||||
if x != nil {
|
||||
return x.Chapteid
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
//领奖 请求回应
|
||||
type MainlineTaskChapteRewardResp struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Task *DBMainTask `protobuf:"bytes,1,opt,name=task,proto3" json:"task"`
|
||||
Award []*UserAtno `protobuf:"bytes,2,rep,name=award,proto3" json:"award"` //奖励
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardResp) Reset() {
|
||||
*x = MainlineTaskChapteRewardResp{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_mainline_mainline_msg_proto_msgTypes[20]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardResp) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MainlineTaskChapteRewardResp) ProtoMessage() {}
|
||||
|
||||
func (x *MainlineTaskChapteRewardResp) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_mainline_mainline_msg_proto_msgTypes[20]
|
||||
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 MainlineTaskChapteRewardResp.ProtoReflect.Descriptor instead.
|
||||
func (*MainlineTaskChapteRewardResp) Descriptor() ([]byte, []int) {
|
||||
return file_mainline_mainline_msg_proto_rawDescGZIP(), []int{20}
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardResp) GetTask() *DBMainTask {
|
||||
if x != nil {
|
||||
return x.Task
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *MainlineTaskChapteRewardResp) GetAward() []*UserAtno {
|
||||
if x != nil {
|
||||
return x.Award
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_mainline_mainline_msg_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_mainline_mainline_msg_proto_rawDesc = []byte{
|
||||
@ -1152,18 +1255,13 @@ var file_mainline_mainline_msg_proto_rawDesc = []byte{
|
||||
0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x53, 0x68, 0x6f, 0x70, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50,
|
||||
0x75, 0x73, 0x68, 0x12, 0x10, 0x0a, 0x03, 0x63, 0x69, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05,
|
||||
0x52, 0x03, 0x63, 0x69, 0x64, 0x22, 0x15, 0x0a, 0x13, 0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e,
|
||||
0x65, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x22, 0xaf, 0x01, 0x0a,
|
||||
0x14, 0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x6e, 0x66,
|
||||
0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x25, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x6c, 0x64, 0x73, 0x18,
|
||||
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x43, 0x6f, 0x6e, 0x49, 0x50, 0x72, 0x6f, 0x67,
|
||||
0x72, 0x65, 0x73, 0x73, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x6c, 0x64, 0x73, 0x12, 0x36, 0x0a, 0x05,
|
||||
0x74, 0x61, 0x73, 0x6b, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x4d, 0x61,
|
||||
0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65,
|
||||
0x73, 0x70, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x74,
|
||||
0x61, 0x73, 0x6b, 0x73, 0x1a, 0x38, 0x0a, 0x0a, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x45, 0x6e, 0x74,
|
||||
0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 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, 0x22, 0x28,
|
||||
0x65, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x22, 0x60, 0x0a, 0x14,
|
||||
0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x49, 0x6e, 0x66, 0x6f,
|
||||
0x52, 0x65, 0x73, 0x70, 0x12, 0x25, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x6c, 0x64, 0x73, 0x18, 0x01,
|
||||
0x20, 0x03, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x43, 0x6f, 0x6e, 0x49, 0x50, 0x72, 0x6f, 0x67, 0x72,
|
||||
0x65, 0x73, 0x73, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x6c, 0x64, 0x73, 0x12, 0x21, 0x0a, 0x05, 0x74,
|
||||
0x61, 0x73, 0x6b, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d,
|
||||
0x61, 0x69, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x05, 0x74, 0x61, 0x73, 0x6b, 0x73, 0x22, 0x28,
|
||||
0x0a, 0x16, 0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65,
|
||||
0x63, 0x65, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x69, 0x64, 0x22, 0x4a, 0x0a, 0x17, 0x4d, 0x61, 0x69, 0x6e,
|
||||
@ -1171,8 +1269,18 @@ var file_mainline_mainline_msg_proto_rawDesc = []byte{
|
||||
0x65, 0x73, 0x70, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52,
|
||||
0x02, 0x69, 0x64, 0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x02, 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,
|
||||
0x77, 0x61, 0x72, 0x64, 0x22, 0x39, 0x0a, 0x1b, 0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65,
|
||||
0x54, 0x61, 0x73, 0x6b, 0x43, 0x68, 0x61, 0x70, 0x74, 0x65, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64,
|
||||
0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x68, 0x61, 0x70, 0x74, 0x65, 0x69, 0x64, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x63, 0x68, 0x61, 0x70, 0x74, 0x65, 0x69, 0x64, 0x22,
|
||||
0x60, 0x0a, 0x1c, 0x4d, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x43,
|
||||
0x68, 0x61, 0x70, 0x74, 0x65, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12,
|
||||
0x1f, 0x0a, 0x04, 0x74, 0x61, 0x73, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e,
|
||||
0x44, 0x42, 0x4d, 0x61, 0x69, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x04, 0x74, 0x61, 0x73, 0x6b,
|
||||
0x12, 0x1f, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x02, 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 (
|
||||
@ -1187,7 +1295,7 @@ func file_mainline_mainline_msg_proto_rawDescGZIP() []byte {
|
||||
return file_mainline_mainline_msg_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_mainline_mainline_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 20)
|
||||
var file_mainline_mainline_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 21)
|
||||
var file_mainline_mainline_msg_proto_goTypes = []interface{}{
|
||||
(*MainlineInfoReq)(nil), // 0: MainlineInfoReq
|
||||
(*MainlineInfoResp)(nil), // 1: MainlineInfoResp
|
||||
@ -1208,34 +1316,38 @@ var file_mainline_mainline_msg_proto_goTypes = []interface{}{
|
||||
(*MainlineTaskInfoResp)(nil), // 16: MainlineTaskInfoResp
|
||||
(*MainlineTaskReceiveReq)(nil), // 17: MainlineTaskReceiveReq
|
||||
(*MainlineTaskReceiveResp)(nil), // 18: MainlineTaskReceiveResp
|
||||
nil, // 19: MainlineTaskInfoResp.TasksEntry
|
||||
(*DBMainline)(nil), // 20: DBMainline
|
||||
(*BattleFormation)(nil), // 21: BattleFormation
|
||||
(*BattleInfo)(nil), // 22: BattleInfo
|
||||
(*BattleReport)(nil), // 23: BattleReport
|
||||
(*UserAtno)(nil), // 24: UserAtno
|
||||
(*DBMainlineShop)(nil), // 25: DBMainlineShop
|
||||
(*ConIProgress)(nil), // 26: ConIProgress
|
||||
(*MainlineTaskChapteRewardReq)(nil), // 19: MainlineTaskChapteRewardReq
|
||||
(*MainlineTaskChapteRewardResp)(nil), // 20: MainlineTaskChapteRewardResp
|
||||
(*DBMainline)(nil), // 21: DBMainline
|
||||
(*BattleFormation)(nil), // 22: BattleFormation
|
||||
(*BattleInfo)(nil), // 23: BattleInfo
|
||||
(*BattleReport)(nil), // 24: BattleReport
|
||||
(*UserAtno)(nil), // 25: UserAtno
|
||||
(*DBMainlineShop)(nil), // 26: DBMainlineShop
|
||||
(*ConIProgress)(nil), // 27: ConIProgress
|
||||
(*DBMainTask)(nil), // 28: DBMainTask
|
||||
}
|
||||
var file_mainline_mainline_msg_proto_depIdxs = []int32{
|
||||
20, // 0: MainlineInfoResp.info:type_name -> DBMainline
|
||||
21, // 1: MainlineChallengeReq.battle:type_name -> BattleFormation
|
||||
22, // 2: MainlineChallengeResp.info:type_name -> BattleInfo
|
||||
23, // 3: MainlineChallengeOverReq.report:type_name -> BattleReport
|
||||
24, // 4: MainlineChallengeOverResp.reward:type_name -> UserAtno
|
||||
24, // 5: MainlineLevelPassResp.reward:type_name -> UserAtno
|
||||
24, // 6: MainlineReceiveAwardResp.reward:type_name -> UserAtno
|
||||
25, // 7: MainlineShopResp.info:type_name -> DBMainlineShop
|
||||
25, // 8: MainlineShopBuyResp.info:type_name -> DBMainlineShop
|
||||
24, // 9: MainlineShopBuyResp.item:type_name -> UserAtno
|
||||
26, // 10: MainlineTaskInfoResp.conlds:type_name -> ConIProgress
|
||||
19, // 11: MainlineTaskInfoResp.tasks:type_name -> MainlineTaskInfoResp.TasksEntry
|
||||
24, // 12: MainlineTaskReceiveResp.award:type_name -> UserAtno
|
||||
13, // [13:13] is the sub-list for method output_type
|
||||
13, // [13:13] is the sub-list for method input_type
|
||||
13, // [13:13] is the sub-list for extension type_name
|
||||
13, // [13:13] is the sub-list for extension extendee
|
||||
0, // [0:13] is the sub-list for field type_name
|
||||
21, // 0: MainlineInfoResp.info:type_name -> DBMainline
|
||||
22, // 1: MainlineChallengeReq.battle:type_name -> BattleFormation
|
||||
23, // 2: MainlineChallengeResp.info:type_name -> BattleInfo
|
||||
24, // 3: MainlineChallengeOverReq.report:type_name -> BattleReport
|
||||
25, // 4: MainlineChallengeOverResp.reward:type_name -> UserAtno
|
||||
25, // 5: MainlineLevelPassResp.reward:type_name -> UserAtno
|
||||
25, // 6: MainlineReceiveAwardResp.reward:type_name -> UserAtno
|
||||
26, // 7: MainlineShopResp.info:type_name -> DBMainlineShop
|
||||
26, // 8: MainlineShopBuyResp.info:type_name -> DBMainlineShop
|
||||
25, // 9: MainlineShopBuyResp.item:type_name -> UserAtno
|
||||
27, // 10: MainlineTaskInfoResp.conlds:type_name -> ConIProgress
|
||||
28, // 11: MainlineTaskInfoResp.tasks:type_name -> DBMainTask
|
||||
25, // 12: MainlineTaskReceiveResp.award:type_name -> UserAtno
|
||||
28, // 13: MainlineTaskChapteRewardResp.task:type_name -> DBMainTask
|
||||
25, // 14: MainlineTaskChapteRewardResp.award:type_name -> UserAtno
|
||||
15, // [15:15] is the sub-list for method output_type
|
||||
15, // [15:15] is the sub-list for method input_type
|
||||
15, // [15:15] is the sub-list for extension type_name
|
||||
15, // [15:15] is the sub-list for extension extendee
|
||||
0, // [0:15] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_mainline_mainline_msg_proto_init() }
|
||||
@ -1476,6 +1588,30 @@ func file_mainline_mainline_msg_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_mainline_mainline_msg_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*MainlineTaskChapteRewardReq); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_mainline_mainline_msg_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*MainlineTaskChapteRewardResp); 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{
|
||||
@ -1483,7 +1619,7 @@ func file_mainline_mainline_msg_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_mainline_mainline_msg_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 20,
|
||||
NumMessages: 21,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user