#43483 任务 【梦工场系统】 <-后端-> StonehengeTaskReceiveReq 回应中 只带 请求的任务id和奖励

This commit is contained in:
meixiongfeng 2024-01-10 11:16:51 +08:00
parent cfbc02c43e
commit 31aecab408
2 changed files with 62 additions and 69 deletions

View File

@ -92,7 +92,7 @@ func (this *apiComp) TaskReceive(session comm.IUserSession, req *pb.StonehengeTa
return
}
session.SendMsg(string(this.module.GetType()), "taskreceive", &pb.StonehengeTaskReceiveResp{Task: info.Task, Award: award})
session.SendMsg(string(this.module.GetType()), "taskreceive", &pb.StonehengeTaskReceiveResp{Taskid: req.Taskid, Award: award})
if len(award) > 0 {
go this.module.AsynHandleSession(session.Clone(), func(session comm.IUserSession) {
this.module.WriteUserLog(session.GetUserId(), req, comm.GMResAddType, "StonehengeTaskReceiveReq", award)

View File

@ -1644,7 +1644,7 @@ type StonehengeTaskReceiveResp struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Task map[int32]bool `protobuf:"bytes,1,rep,name=task,proto3" json:"task" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //已领取的任务
Taskid int32 `protobuf:"varint,1,opt,name=taskid,proto3" json:"taskid"`
Award []*UserAssets `protobuf:"bytes,2,rep,name=award,proto3" json:"award"` //奖励
}
@ -1680,11 +1680,11 @@ func (*StonehengeTaskReceiveResp) Descriptor() ([]byte, []int) {
return file_stonehenge_stonehenge_msg_proto_rawDescGZIP(), []int{29}
}
func (x *StonehengeTaskReceiveResp) GetTask() map[int32]bool {
func (x *StonehengeTaskReceiveResp) GetTaskid() int32 {
if x != nil {
return x.Task
return x.Taskid
}
return nil
return 0
}
func (x *StonehengeTaskReceiveResp) GetAward() []*UserAssets {
@ -2001,26 +2001,21 @@ var file_stonehenge_stonehenge_msg_proto_rawDesc = []byte{
0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x32, 0x0a, 0x18, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68,
0x65, 0x6e, 0x67, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52,
0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
0x28, 0x05, 0x52, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x69, 0x64, 0x22, 0xb1, 0x01, 0x0a, 0x19, 0x53,
0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x63,
0x65, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x38, 0x0a, 0x04, 0x74, 0x61, 0x73, 0x6b,
0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65,
0x6e, 0x67, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x52, 0x65,
0x73, 0x70, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x74, 0x61,
0x73, 0x6b, 0x12, 0x21, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28,
0x0b, 0x32, 0x0b, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x52, 0x05,
0x61, 0x77, 0x61, 0x72, 0x64, 0x1a, 0x37, 0x0a, 0x09, 0x54, 0x61, 0x73, 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, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x32,
0x0a, 0x16, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x65,
0x74, 0x42, 0x75, 0x66, 0x66, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x76, 0x65, 0x6e,
0x74, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x76, 0x65, 0x6e, 0x74,
0x69, 0x64, 0x22, 0x39, 0x0a, 0x17, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65,
0x52, 0x65, 0x73, 0x65, 0x74, 0x42, 0x75, 0x66, 0x66, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1e, 0x0a,
0x0a, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x62, 0x75, 0x66, 0x66, 0x18, 0x01, 0x20, 0x03, 0x28,
0x05, 0x52, 0x0a, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x62, 0x75, 0x66, 0x66, 0x42, 0x06, 0x5a,
0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x28, 0x05, 0x52, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x69, 0x64, 0x22, 0x56, 0x0a, 0x19, 0x53, 0x74,
0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x54, 0x61, 0x73, 0x6b, 0x52, 0x65, 0x63, 0x65,
0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x69,
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x69, 0x64, 0x12,
0x21, 0x0a, 0x05, 0x61, 0x77, 0x61, 0x72, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b,
0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x73, 0x73, 0x65, 0x74, 0x73, 0x52, 0x05, 0x61, 0x77, 0x61,
0x72, 0x64, 0x22, 0x32, 0x0a, 0x16, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65,
0x52, 0x65, 0x73, 0x65, 0x74, 0x42, 0x75, 0x66, 0x66, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07,
0x65, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65,
0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x22, 0x39, 0x0a, 0x17, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68,
0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x65, 0x74, 0x42, 0x75, 0x66, 0x66, 0x52, 0x65, 0x73,
0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x62, 0x75, 0x66, 0x66, 0x18,
0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x0a, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x62, 0x75, 0x66,
0x66, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x33,
}
var (
@ -2035,7 +2030,7 @@ func file_stonehenge_stonehenge_msg_proto_rawDescGZIP() []byte {
return file_stonehenge_stonehenge_msg_proto_rawDescData
}
var file_stonehenge_stonehenge_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 41)
var file_stonehenge_stonehenge_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 40)
var file_stonehenge_stonehenge_msg_proto_goTypes = []interface{}{
(*StonehengeGetListReq)(nil), // 0: StonehengeGetListReq
(*StonehengeGetListResp)(nil), // 1: StonehengeGetListResp
@ -2077,57 +2072,55 @@ var file_stonehenge_stonehenge_msg_proto_goTypes = []interface{}{
nil, // 37: StonehengeActivateTalentResp.TalentpropertyEntry
nil, // 38: StonehengeWeekAwardResp.WeeklyrewardEntry
nil, // 39: StonehengeTaskInfoResp.TaskEntry
nil, // 40: StonehengeTaskReceiveResp.TaskEntry
(*DBStonehenge)(nil), // 41: DBStonehenge
(*DBStoneBoss)(nil), // 42: DBStoneBoss
(*RoomData)(nil), // 43: RoomData
(*BattleReport)(nil), // 44: BattleReport
(*UserAtno)(nil), // 45: UserAtno
(*BattleFormation)(nil), // 46: BattleFormation
(*BattleInfo)(nil), // 47: BattleInfo
(StonehengePrivilege)(0), // 48: StonehengePrivilege
(*DBStonehengeBook)(nil), // 49: DBStonehengeBook
(*UserAssets)(nil), // 50: UserAssets
(*ConIProgress)(nil), // 51: ConIProgress
(*BattleRole)(nil), // 52: BattleRole
(*DBStonehenge)(nil), // 40: DBStonehenge
(*DBStoneBoss)(nil), // 41: DBStoneBoss
(*RoomData)(nil), // 42: RoomData
(*BattleReport)(nil), // 43: BattleReport
(*UserAtno)(nil), // 44: UserAtno
(*BattleFormation)(nil), // 45: BattleFormation
(*BattleInfo)(nil), // 46: BattleInfo
(StonehengePrivilege)(0), // 47: StonehengePrivilege
(*DBStonehengeBook)(nil), // 48: DBStonehengeBook
(*UserAssets)(nil), // 49: UserAssets
(*ConIProgress)(nil), // 50: ConIProgress
(*BattleRole)(nil), // 51: BattleRole
}
var file_stonehenge_stonehenge_msg_proto_depIdxs = []int32{
41, // 0: StonehengeGetListResp.data:type_name -> DBStonehenge
42, // 1: StonehengeGetListResp.boss:type_name -> DBStoneBoss
40, // 0: StonehengeGetListResp.data:type_name -> DBStonehenge
41, // 1: StonehengeGetListResp.boss:type_name -> DBStoneBoss
32, // 2: StonehengeEnterLevelResp.hero:type_name -> StonehengeEnterLevelResp.HeroEntry
43, // 3: StonehengeEnterLevelResp.room:type_name -> RoomData
43, // 4: StonehengeGotoRoomResp.room:type_name -> RoomData
44, // 5: StonehengeEventReq.report:type_name -> BattleReport
43, // 6: StonehengeEventResp.room:type_name -> RoomData
45, // 7: StonehengeEventResp.reward:type_name -> UserAtno
42, // 3: StonehengeEnterLevelResp.room:type_name -> RoomData
42, // 4: StonehengeGotoRoomResp.room:type_name -> RoomData
43, // 5: StonehengeEventReq.report:type_name -> BattleReport
42, // 6: StonehengeEventResp.room:type_name -> RoomData
44, // 7: StonehengeEventResp.reward:type_name -> UserAtno
33, // 8: StonehengeEventResp.hero:type_name -> StonehengeEventResp.HeroEntry
34, // 9: StonehengeEventResp.userbuff:type_name -> StonehengeEventResp.UserbuffEntry
43, // 10: StonehengeGetRoomInfoResp.room:type_name -> RoomData
41, // 11: StonehengeFinishResp.data:type_name -> DBStonehenge
45, // 12: StonehengeFinishResp.reward:type_name -> UserAtno
46, // 13: StonehengeBattleReq.battle:type_name -> BattleFormation
47, // 14: StonehengeBattleResp.info:type_name -> BattleInfo
43, // 15: StonehengeStoryResp.room:type_name -> RoomData
42, // 10: StonehengeGetRoomInfoResp.room:type_name -> RoomData
40, // 11: StonehengeFinishResp.data:type_name -> DBStonehenge
44, // 12: StonehengeFinishResp.reward:type_name -> UserAtno
45, // 13: StonehengeBattleReq.battle:type_name -> BattleFormation
46, // 14: StonehengeBattleResp.info:type_name -> BattleInfo
42, // 15: StonehengeStoryResp.room:type_name -> RoomData
35, // 16: StonehengeStoreResp.shop:type_name -> StonehengeStoreResp.ShopEntry
43, // 17: StonehengeStoreResp.room:type_name -> RoomData
42, // 17: StonehengeStoreResp.room:type_name -> RoomData
36, // 18: StonehengeActivateTalentResp.talent:type_name -> StonehengeActivateTalentResp.TalentEntry
37, // 19: StonehengeActivateTalentResp.talentproperty:type_name -> StonehengeActivateTalentResp.TalentpropertyEntry
48, // 20: StonehengeActivateTalentResp.privilege:type_name -> StonehengePrivilege
49, // 21: StonehengeBookInfoResp.info:type_name -> DBStonehengeBook
50, // 22: StonehengeBookAwardResp.award:type_name -> UserAssets
47, // 20: StonehengeActivateTalentResp.privilege:type_name -> StonehengePrivilege
48, // 21: StonehengeBookInfoResp.info:type_name -> DBStonehengeBook
49, // 22: StonehengeBookAwardResp.award:type_name -> UserAssets
38, // 23: StonehengeWeekAwardResp.weeklyreward:type_name -> StonehengeWeekAwardResp.WeeklyrewardEntry
50, // 24: StonehengeWeekAwardResp.award:type_name -> UserAssets
51, // 25: StonehengeTaskInfoResp.conlds:type_name -> ConIProgress
49, // 24: StonehengeWeekAwardResp.award:type_name -> UserAssets
50, // 25: StonehengeTaskInfoResp.conlds:type_name -> ConIProgress
39, // 26: StonehengeTaskInfoResp.task:type_name -> StonehengeTaskInfoResp.TaskEntry
40, // 27: StonehengeTaskReceiveResp.task:type_name -> StonehengeTaskReceiveResp.TaskEntry
50, // 28: StonehengeTaskReceiveResp.award:type_name -> UserAssets
52, // 29: StonehengeEnterLevelResp.HeroEntry.value:type_name -> BattleRole
52, // 30: StonehengeEventResp.HeroEntry.value:type_name -> BattleRole
31, // [31:31] is the sub-list for method output_type
31, // [31:31] is the sub-list for method input_type
31, // [31:31] is the sub-list for extension type_name
31, // [31:31] is the sub-list for extension extendee
0, // [0:31] is the sub-list for field type_name
49, // 27: StonehengeTaskReceiveResp.award:type_name -> UserAssets
51, // 28: StonehengeEnterLevelResp.HeroEntry.value:type_name -> BattleRole
51, // 29: StonehengeEventResp.HeroEntry.value:type_name -> BattleRole
30, // [30:30] is the sub-list for method output_type
30, // [30:30] is the sub-list for method input_type
30, // [30:30] is the sub-list for extension type_name
30, // [30:30] is the sub-list for extension extendee
0, // [0:30] is the sub-list for field type_name
}
func init() { file_stonehenge_stonehenge_msg_proto_init() }
@ -2532,7 +2525,7 @@ func file_stonehenge_stonehenge_msg_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_stonehenge_stonehenge_msg_proto_rawDesc,
NumEnums: 0,
NumMessages: 41,
NumMessages: 40,
NumExtensions: 0,
NumServices: 0,
},