From cd3e36d1f4306878fedff04f17aff13e1be57860 Mon Sep 17 00:00:00 2001 From: NorthLan <6995syu@163.com> Date: Thu, 5 May 2022 01:56:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=8E=92=E8=A1=8C?= =?UTF-8?q?=E6=A6=9C=E9=97=AE=E9=A2=98=EF=BC=8C=E4=B8=8D=E8=A6=81=E5=86=8D?= =?UTF-8?q?=E5=8F=91=E5=BE=97=E9=82=A3=E4=B9=88=E9=A2=91=E7=B9=81=E4=BA=86?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/user_center/pb/user_center.pb.go | 464 ++++----- app/user_center/pb/user_center.proto | 28 +- app/user_center/pb/user_center_grpc.pb.go | 72 -- app/user_center/usercenter/user_center.go | 35 +- game/logic/statistics/stat_pvp.go | 54 +- game/pb/rank/Rank.cs | 59 +- game/pb/rank/rank.pb.go | 75 +- game/pb/rank/rank.proto | 16 +- game/pb/stat/Stat.cs | 1089 ++++++++------------- game/pb/stat/stat.pb.go | 341 +++---- game/pb/stat/stat.proto | 26 +- 11 files changed, 907 insertions(+), 1352 deletions(-) diff --git a/app/user_center/pb/user_center.pb.go b/app/user_center/pb/user_center.pb.go index 224c6c7..2c38529 100644 --- a/app/user_center/pb/user_center.pb.go +++ b/app/user_center/pb/user_center.pb.go @@ -258,142 +258,6 @@ func (x *PlatformUserResp) GetUser() *User { return nil } -// 通知-PvP伤害 statistics.pvp.damage -type StatPvPDamageReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 造成伤害的用户ID - TargetUid *int64 `protobuf:"varint,2,opt,name=targetUid,proto3,oneof" json:"targetUid,omitempty"` // 目标用户ID(可能是基地,不一定有) - Damage float32 `protobuf:"fixed32,3,opt,name=damage,proto3" json:"damage,omitempty"` // 伤害量 -} - -func (x *StatPvPDamageReq) Reset() { - *x = StatPvPDamageReq{} - if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *StatPvPDamageReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*StatPvPDamageReq) ProtoMessage() {} - -func (x *StatPvPDamageReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[4] - 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 StatPvPDamageReq.ProtoReflect.Descriptor instead. -func (*StatPvPDamageReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{4} -} - -func (x *StatPvPDamageReq) GetUid() int64 { - if x != nil { - return x.Uid - } - return 0 -} - -func (x *StatPvPDamageReq) GetTargetUid() int64 { - if x != nil && x.TargetUid != nil { - return *x.TargetUid - } - return 0 -} - -func (x *StatPvPDamageReq) GetDamage() float32 { - if x != nil { - return x.Damage - } - return 0 -} - -// 通知-PvP击杀单位 statistics.pvp.killunit -type StatPvPKillUnitReq struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID - TargetUid *int64 `protobuf:"varint,2,opt,name=targetUid,proto3,oneof" json:"targetUid,omitempty"` // 目标用户 - Attacker string `protobuf:"bytes,3,opt,name=attacker,proto3" json:"attacker,omitempty"` // 造成击杀东西(building:兵营 U0001:xxx兵 S0001: 技能) - Victim string `protobuf:"bytes,4,opt,name=victim,proto3" json:"victim,omitempty"` // 被击杀的东西(U0001:xxx兵) -} - -func (x *StatPvPKillUnitReq) Reset() { - *x = StatPvPKillUnitReq{} - if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *StatPvPKillUnitReq) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*StatPvPKillUnitReq) ProtoMessage() {} - -func (x *StatPvPKillUnitReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[5] - 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 StatPvPKillUnitReq.ProtoReflect.Descriptor instead. -func (*StatPvPKillUnitReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{5} -} - -func (x *StatPvPKillUnitReq) GetUid() int64 { - if x != nil { - return x.Uid - } - return 0 -} - -func (x *StatPvPKillUnitReq) GetTargetUid() int64 { - if x != nil && x.TargetUid != nil { - return *x.TargetUid - } - return 0 -} - -func (x *StatPvPKillUnitReq) GetAttacker() string { - if x != nil { - return x.Attacker - } - return "" -} - -func (x *StatPvPKillUnitReq) GetVictim() string { - if x != nil { - return x.Victim - } - return "" -} - // 通知-PvP杀兵营(人) statistics.pvp.kill type StatPvPKillReq struct { state protoimpl.MessageState @@ -408,7 +272,7 @@ type StatPvPKillReq struct { func (x *StatPvPKillReq) Reset() { *x = StatPvPKillReq{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[6] + mi := &file_user_center_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -421,7 +285,7 @@ func (x *StatPvPKillReq) String() string { func (*StatPvPKillReq) ProtoMessage() {} func (x *StatPvPKillReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[6] + mi := &file_user_center_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -434,7 +298,7 @@ func (x *StatPvPKillReq) ProtoReflect() protoreflect.Message { // Deprecated: Use StatPvPKillReq.ProtoReflect.Descriptor instead. func (*StatPvPKillReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{6} + return file_user_center_proto_rawDescGZIP(), []int{4} } func (x *StatPvPKillReq) GetUid() int64 { @@ -471,7 +335,7 @@ type StatPvPFirstBloodReq struct { func (x *StatPvPFirstBloodReq) Reset() { *x = StatPvPFirstBloodReq{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[7] + mi := &file_user_center_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -484,7 +348,7 @@ func (x *StatPvPFirstBloodReq) String() string { func (*StatPvPFirstBloodReq) ProtoMessage() {} func (x *StatPvPFirstBloodReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[7] + mi := &file_user_center_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -497,7 +361,7 @@ func (x *StatPvPFirstBloodReq) ProtoReflect() protoreflect.Message { // Deprecated: Use StatPvPFirstBloodReq.ProtoReflect.Descriptor instead. func (*StatPvPFirstBloodReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{7} + return file_user_center_proto_rawDescGZIP(), []int{5} } func (x *StatPvPFirstBloodReq) GetUid() int64 { @@ -520,16 +384,16 @@ type StatPvPReportReq struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - WinCamp int32 `protobuf:"varint,1,opt,name=winCamp,proto3" json:"winCamp,omitempty"` // 获胜阵营 1-蓝 2-红 - GeneralUid int64 `protobuf:"varint,2,opt,name=generalUid,proto3" json:"generalUid,omitempty"` // 名将UID - WinUids []int64 `protobuf:"varint,3,rep,packed,name=winUids,proto3" json:"winUids,omitempty"` // 战胜方玩家列表 - LostUids []int64 `protobuf:"varint,4,rep,packed,name=lostUids,proto3" json:"lostUids,omitempty"` // 战败方玩家列表 + WinCamp int32 `protobuf:"varint,1,opt,name=winCamp,proto3" json:"winCamp,omitempty"` // 获胜阵营 1-蓝 2-红 + GeneralUid int64 `protobuf:"varint,2,opt,name=generalUid,proto3" json:"generalUid,omitempty"` // 名将UID + WinItems []*StatPvPReportReq_Item `protobuf:"bytes,3,rep,name=winItems,proto3" json:"winItems,omitempty"` // 获胜方数据 + LostItems []*StatPvPReportReq_Item `protobuf:"bytes,4,rep,name=lostItems,proto3" json:"lostItems,omitempty"` // 战败方数据 } func (x *StatPvPReportReq) Reset() { *x = StatPvPReportReq{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[8] + mi := &file_user_center_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -542,7 +406,7 @@ func (x *StatPvPReportReq) String() string { func (*StatPvPReportReq) ProtoMessage() {} func (x *StatPvPReportReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[8] + mi := &file_user_center_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -555,7 +419,7 @@ func (x *StatPvPReportReq) ProtoReflect() protoreflect.Message { // Deprecated: Use StatPvPReportReq.ProtoReflect.Descriptor instead. func (*StatPvPReportReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{8} + return file_user_center_proto_rawDescGZIP(), []int{6} } func (x *StatPvPReportReq) GetWinCamp() int32 { @@ -572,16 +436,16 @@ func (x *StatPvPReportReq) GetGeneralUid() int64 { return 0 } -func (x *StatPvPReportReq) GetWinUids() []int64 { +func (x *StatPvPReportReq) GetWinItems() []*StatPvPReportReq_Item { if x != nil { - return x.WinUids + return x.WinItems } return nil } -func (x *StatPvPReportReq) GetLostUids() []int64 { +func (x *StatPvPReportReq) GetLostItems() []*StatPvPReportReq_Item { if x != nil { - return x.LostUids + return x.LostItems } return nil } @@ -599,7 +463,7 @@ type RankPvpReq struct { func (x *RankPvpReq) Reset() { *x = RankPvpReq{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[9] + mi := &file_user_center_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -612,7 +476,7 @@ func (x *RankPvpReq) String() string { func (*RankPvpReq) ProtoMessage() {} func (x *RankPvpReq) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[9] + mi := &file_user_center_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -625,7 +489,7 @@ func (x *RankPvpReq) ProtoReflect() protoreflect.Message { // Deprecated: Use RankPvpReq.ProtoReflect.Descriptor instead. func (*RankPvpReq) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{9} + return file_user_center_proto_rawDescGZIP(), []int{7} } func (x *RankPvpReq) GetType() int32 { @@ -654,7 +518,7 @@ type RankPvpResp struct { func (x *RankPvpResp) Reset() { *x = RankPvpResp{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[10] + mi := &file_user_center_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -667,7 +531,7 @@ func (x *RankPvpResp) String() string { func (*RankPvpResp) ProtoMessage() {} func (x *RankPvpResp) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[10] + mi := &file_user_center_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -680,7 +544,7 @@ func (x *RankPvpResp) ProtoReflect() protoreflect.Message { // Deprecated: Use RankPvpResp.ProtoReflect.Descriptor instead. func (*RankPvpResp) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{10} + return file_user_center_proto_rawDescGZIP(), []int{8} } func (x *RankPvpResp) GetType() int32 { @@ -697,6 +561,85 @@ func (x *RankPvpResp) GetItems() []*RankPvpResp_Item { return nil } +type StatPvPReportReq_Item struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID + Damage int64 `protobuf:"varint,2,opt,name=damage,proto3" json:"damage,omitempty"` // 伤害量 + DeDamage int64 `protobuf:"varint,3,opt,name=deDamage,proto3" json:"deDamage,omitempty"` // 承受伤害 + KillUnit int64 `protobuf:"varint,4,opt,name=killUnit,proto3" json:"killUnit,omitempty"` // 击杀单位数量 + DeKillUnit int64 `protobuf:"varint,5,opt,name=deKillUnit,proto3" json:"deKillUnit,omitempty"` // 被杀单位数量 +} + +func (x *StatPvPReportReq_Item) Reset() { + *x = StatPvPReportReq_Item{} + if protoimpl.UnsafeEnabled { + mi := &file_user_center_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *StatPvPReportReq_Item) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StatPvPReportReq_Item) ProtoMessage() {} + +func (x *StatPvPReportReq_Item) ProtoReflect() protoreflect.Message { + mi := &file_user_center_proto_msgTypes[9] + 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 StatPvPReportReq_Item.ProtoReflect.Descriptor instead. +func (*StatPvPReportReq_Item) Descriptor() ([]byte, []int) { + return file_user_center_proto_rawDescGZIP(), []int{6, 0} +} + +func (x *StatPvPReportReq_Item) GetUid() int64 { + if x != nil { + return x.Uid + } + return 0 +} + +func (x *StatPvPReportReq_Item) GetDamage() int64 { + if x != nil { + return x.Damage + } + return 0 +} + +func (x *StatPvPReportReq_Item) GetDeDamage() int64 { + if x != nil { + return x.DeDamage + } + return 0 +} + +func (x *StatPvPReportReq_Item) GetKillUnit() int64 { + if x != nil { + return x.KillUnit + } + return 0 +} + +func (x *StatPvPReportReq_Item) GetDeKillUnit() int64 { + if x != nil { + return x.DeKillUnit + } + return 0 +} + type RankPvpResp_Item struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -711,7 +654,7 @@ type RankPvpResp_Item struct { func (x *RankPvpResp_Item) Reset() { *x = RankPvpResp_Item{} if protoimpl.UnsafeEnabled { - mi := &file_user_center_proto_msgTypes[11] + mi := &file_user_center_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -724,7 +667,7 @@ func (x *RankPvpResp_Item) String() string { func (*RankPvpResp_Item) ProtoMessage() {} func (x *RankPvpResp_Item) ProtoReflect() protoreflect.Message { - mi := &file_user_center_proto_msgTypes[11] + mi := &file_user_center_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -737,7 +680,7 @@ func (x *RankPvpResp_Item) ProtoReflect() protoreflect.Message { // Deprecated: Use RankPvpResp_Item.ProtoReflect.Descriptor instead. func (*RankPvpResp_Item) Descriptor() ([]byte, []int) { - return file_user_center_proto_rawDescGZIP(), []int{10, 0} + return file_user_center_proto_rawDescGZIP(), []int{8, 0} } func (x *RankPvpResp_Item) GetUid() int64 { @@ -791,66 +734,56 @@ var file_user_center_proto_rawDesc = []byte{ 0x22, 0x30, 0x0a, 0x10, 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1c, 0x0a, 0x04, 0x75, 0x73, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x08, 0x2e, 0x70, 0x62, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x52, 0x04, 0x75, 0x73, - 0x65, 0x72, 0x22, 0x6d, 0x0a, 0x10, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x44, 0x61, 0x6d, - 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, - 0x65, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, - 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x88, 0x01, 0x01, 0x12, 0x16, 0x0a, 0x06, 0x64, - 0x61, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x06, 0x64, 0x61, 0x6d, - 0x61, 0x67, 0x65, 0x42, 0x0c, 0x0a, 0x0a, 0x5f, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, - 0x64, 0x22, 0x8b, 0x01, 0x0a, 0x12, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, - 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x09, 0x74, 0x61, - 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, - 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x88, 0x01, 0x01, 0x12, 0x1a, 0x0a, - 0x08, 0x61, 0x74, 0x74, 0x61, 0x63, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x61, 0x74, 0x74, 0x61, 0x63, 0x6b, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x76, 0x69, 0x63, - 0x74, 0x69, 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x76, 0x69, 0x63, 0x74, 0x69, - 0x6d, 0x42, 0x0c, 0x0a, 0x0a, 0x5f, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x22, - 0x5e, 0x0a, 0x0e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, 0x6c, 0x52, 0x65, - 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, - 0x75, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, - 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x22, - 0x3c, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x46, 0x69, 0x72, 0x73, 0x74, 0x42, - 0x6c, 0x6f, 0x6f, 0x64, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x82, 0x01, - 0x0a, 0x10, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x52, - 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, 0x12, 0x1e, 0x0a, 0x0a, - 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0a, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x12, 0x18, 0x0a, 0x07, - 0x77, 0x69, 0x6e, 0x55, 0x69, 0x64, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x03, 0x52, 0x07, 0x77, - 0x69, 0x6e, 0x55, 0x69, 0x64, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x6f, 0x73, 0x74, 0x55, 0x69, - 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x6f, 0x73, 0x74, 0x55, 0x69, - 0x64, 0x73, 0x22, 0x34, 0x0a, 0x0a, 0x52, 0x61, 0x6e, 0x6b, 0x50, 0x76, 0x70, 0x52, 0x65, 0x71, + 0x65, 0x72, 0x22, 0x5e, 0x0a, 0x0e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, + 0x6c, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, + 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, + 0x74, 0x55, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, + 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, + 0x61, 0x6c, 0x22, 0x3c, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x46, 0x69, 0x72, + 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x6f, 0x64, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, + 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, + 0x22, 0xc7, 0x02, 0x0a, 0x10, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, 0x70, 0x6f, + 0x72, 0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, 0x12, + 0x1e, 0x0a, 0x0a, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x12, + 0x35, 0x0a, 0x08, 0x77, 0x69, 0x6e, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x19, 0x2e, 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, + 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x08, 0x77, 0x69, + 0x6e, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x37, 0x0a, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x49, 0x74, + 0x65, 0x6d, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x70, 0x62, 0x2e, 0x53, + 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x2e, + 0x49, 0x74, 0x65, 0x6d, 0x52, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x1a, + 0x88, 0x01, 0x0a, 0x04, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x61, + 0x6d, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x64, 0x61, 0x6d, 0x61, + 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x64, 0x65, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x64, 0x65, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x1a, + 0x0a, 0x08, 0x6b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x08, 0x6b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, + 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x64, 0x65, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x22, 0x34, 0x0a, 0x0a, 0x52, 0x61, + 0x6e, 0x6b, 0x50, 0x76, 0x70, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x74, 0x6f, 0x70, 0x4e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x6f, 0x70, 0x4e, + 0x22, 0xab, 0x01, 0x0a, 0x0b, 0x52, 0x61, 0x6e, 0x6b, 0x50, 0x76, 0x70, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, - 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x6f, 0x70, 0x4e, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x04, 0x74, 0x6f, 0x70, 0x4e, 0x22, 0xab, 0x01, 0x0a, 0x0b, 0x52, 0x61, 0x6e, - 0x6b, 0x50, 0x76, 0x70, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x2a, 0x0a, 0x05, - 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x70, 0x62, - 0x2e, 0x52, 0x61, 0x6e, 0x6b, 0x50, 0x76, 0x70, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x49, 0x74, 0x65, - 0x6d, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x1a, 0x5c, 0x0a, 0x04, 0x49, 0x74, 0x65, 0x6d, - 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, - 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x75, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x75, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f, 0x72, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x16, - 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, - 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x32, 0xfd, 0x02, 0x0a, 0x0a, 0x75, 0x73, 0x65, 0x72, 0x43, - 0x65, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x41, 0x0a, 0x14, 0x72, 0x65, 0x74, 0x72, 0x69, 0x65, 0x76, - 0x65, 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x55, 0x73, 0x65, 0x72, 0x12, 0x13, 0x2e, - 0x70, 0x62, 0x2e, 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x55, 0x73, 0x65, 0x72, 0x52, - 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x70, 0x62, 0x2e, 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, - 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x12, 0x30, 0x0a, 0x0d, 0x73, 0x74, 0x61, 0x74, - 0x50, 0x76, 0x70, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x14, 0x2e, 0x70, 0x62, 0x2e, 0x53, - 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x1a, - 0x09, 0x2e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x12, 0x34, 0x0a, 0x0f, 0x73, 0x74, - 0x61, 0x74, 0x50, 0x76, 0x70, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x16, 0x2e, - 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, - 0x69, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x09, 0x2e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, + 0x74, 0x79, 0x70, 0x65, 0x12, 0x2a, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x70, 0x62, 0x2e, 0x52, 0x61, 0x6e, 0x6b, 0x50, 0x76, 0x70, + 0x52, 0x65, 0x73, 0x70, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, + 0x1a, 0x5c, 0x0a, 0x04, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x75, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x75, 0x6e, 0x61, 0x6d, 0x65, + 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x32, 0x95, + 0x02, 0x0a, 0x0a, 0x75, 0x73, 0x65, 0x72, 0x43, 0x65, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x41, 0x0a, + 0x14, 0x72, 0x65, 0x74, 0x72, 0x69, 0x65, 0x76, 0x65, 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, + 0x6d, 0x55, 0x73, 0x65, 0x72, 0x12, 0x13, 0x2e, 0x70, 0x62, 0x2e, 0x50, 0x6c, 0x61, 0x74, 0x66, + 0x6f, 0x72, 0x6d, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x70, 0x62, 0x2e, + 0x50, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x12, 0x2c, 0x0a, 0x0b, 0x73, 0x74, 0x61, 0x74, 0x50, 0x76, 0x70, 0x4b, 0x69, 0x6c, 0x6c, 0x12, 0x12, 0x2e, 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x09, 0x2e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x12, 0x38, @@ -879,43 +812,40 @@ func file_user_center_proto_rawDescGZIP() []byte { return file_user_center_proto_rawDescData } -var file_user_center_proto_msgTypes = make([]protoimpl.MessageInfo, 12) +var file_user_center_proto_msgTypes = make([]protoimpl.MessageInfo, 11) var file_user_center_proto_goTypes = []interface{}{ - (*User)(nil), // 0: pb.User - (*Empty)(nil), // 1: pb.Empty - (*PlatformUserReq)(nil), // 2: pb.PlatformUserReq - (*PlatformUserResp)(nil), // 3: pb.PlatformUserResp - (*StatPvPDamageReq)(nil), // 4: pb.StatPvPDamageReq - (*StatPvPKillUnitReq)(nil), // 5: pb.StatPvPKillUnitReq - (*StatPvPKillReq)(nil), // 6: pb.StatPvPKillReq - (*StatPvPFirstBloodReq)(nil), // 7: pb.StatPvPFirstBloodReq - (*StatPvPReportReq)(nil), // 8: pb.StatPvPReportReq - (*RankPvpReq)(nil), // 9: pb.RankPvpReq - (*RankPvpResp)(nil), // 10: pb.RankPvpResp - (*RankPvpResp_Item)(nil), // 11: pb.RankPvpResp.Item + (*User)(nil), // 0: pb.User + (*Empty)(nil), // 1: pb.Empty + (*PlatformUserReq)(nil), // 2: pb.PlatformUserReq + (*PlatformUserResp)(nil), // 3: pb.PlatformUserResp + (*StatPvPKillReq)(nil), // 4: pb.StatPvPKillReq + (*StatPvPFirstBloodReq)(nil), // 5: pb.StatPvPFirstBloodReq + (*StatPvPReportReq)(nil), // 6: pb.StatPvPReportReq + (*RankPvpReq)(nil), // 7: pb.RankPvpReq + (*RankPvpResp)(nil), // 8: pb.RankPvpResp + (*StatPvPReportReq_Item)(nil), // 9: pb.StatPvPReportReq.Item + (*RankPvpResp_Item)(nil), // 10: pb.RankPvpResp.Item } var file_user_center_proto_depIdxs = []int32{ 0, // 0: pb.PlatformUserResp.user:type_name -> pb.User - 11, // 1: pb.RankPvpResp.items:type_name -> pb.RankPvpResp.Item - 2, // 2: pb.userCenter.retrievePlatformUser:input_type -> pb.PlatformUserReq - 4, // 3: pb.userCenter.statPvpDamage:input_type -> pb.StatPvPDamageReq - 5, // 4: pb.userCenter.statPvpKillUnit:input_type -> pb.StatPvPKillUnitReq - 6, // 5: pb.userCenter.statPvpKill:input_type -> pb.StatPvPKillReq - 7, // 6: pb.userCenter.statPvpFirstBlood:input_type -> pb.StatPvPFirstBloodReq - 8, // 7: pb.userCenter.statPvpReport:input_type -> pb.StatPvPReportReq - 9, // 8: pb.userCenter.rankPvp:input_type -> pb.RankPvpReq + 9, // 1: pb.StatPvPReportReq.winItems:type_name -> pb.StatPvPReportReq.Item + 9, // 2: pb.StatPvPReportReq.lostItems:type_name -> pb.StatPvPReportReq.Item + 10, // 3: pb.RankPvpResp.items:type_name -> pb.RankPvpResp.Item + 2, // 4: pb.userCenter.retrievePlatformUser:input_type -> pb.PlatformUserReq + 4, // 5: pb.userCenter.statPvpKill:input_type -> pb.StatPvPKillReq + 5, // 6: pb.userCenter.statPvpFirstBlood:input_type -> pb.StatPvPFirstBloodReq + 6, // 7: pb.userCenter.statPvpReport:input_type -> pb.StatPvPReportReq + 7, // 8: pb.userCenter.rankPvp:input_type -> pb.RankPvpReq 3, // 9: pb.userCenter.retrievePlatformUser:output_type -> pb.PlatformUserResp - 1, // 10: pb.userCenter.statPvpDamage:output_type -> pb.Empty - 1, // 11: pb.userCenter.statPvpKillUnit:output_type -> pb.Empty - 1, // 12: pb.userCenter.statPvpKill:output_type -> pb.Empty - 1, // 13: pb.userCenter.statPvpFirstBlood:output_type -> pb.Empty - 1, // 14: pb.userCenter.statPvpReport:output_type -> pb.Empty - 10, // 15: pb.userCenter.rankPvp:output_type -> pb.RankPvpResp - 9, // [9:16] is the sub-list for method output_type - 2, // [2:9] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name + 1, // 10: pb.userCenter.statPvpKill:output_type -> pb.Empty + 1, // 11: pb.userCenter.statPvpFirstBlood:output_type -> pb.Empty + 1, // 12: pb.userCenter.statPvpReport:output_type -> pb.Empty + 8, // 13: pb.userCenter.rankPvp:output_type -> pb.RankPvpResp + 9, // [9:14] is the sub-list for method output_type + 4, // [4:9] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name } func init() { file_user_center_proto_init() } @@ -973,7 +903,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPDamageReq); i { + switch v := v.(*StatPvPKillReq); i { case 0: return &v.state case 1: @@ -985,7 +915,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPKillUnitReq); i { + switch v := v.(*StatPvPFirstBloodReq); i { case 0: return &v.state case 1: @@ -997,7 +927,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPKillReq); i { + switch v := v.(*StatPvPReportReq); i { case 0: return &v.state case 1: @@ -1009,7 +939,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPFirstBloodReq); i { + switch v := v.(*RankPvpReq); i { case 0: return &v.state case 1: @@ -1021,7 +951,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPReportReq); i { + switch v := v.(*RankPvpResp); i { case 0: return &v.state case 1: @@ -1033,7 +963,7 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RankPvpReq); i { + switch v := v.(*StatPvPReportReq_Item); i { case 0: return &v.state case 1: @@ -1045,18 +975,6 @@ func file_user_center_proto_init() { } } file_user_center_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RankPvpResp); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_user_center_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RankPvpResp_Item); i { case 0: return &v.state @@ -1069,15 +987,13 @@ func file_user_center_proto_init() { } } } - file_user_center_proto_msgTypes[4].OneofWrappers = []interface{}{} - file_user_center_proto_msgTypes[5].OneofWrappers = []interface{}{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_user_center_proto_rawDesc, NumEnums: 0, - NumMessages: 12, + NumMessages: 11, NumExtensions: 0, NumServices: 1, }, diff --git a/app/user_center/pb/user_center.proto b/app/user_center/pb/user_center.proto index 465f618..2e98304 100644 --- a/app/user_center/pb/user_center.proto +++ b/app/user_center/pb/user_center.proto @@ -28,21 +28,6 @@ message PlatformUserResp { User user = 1; } -// 通知-PvP伤害 statistics.pvp.damage -message StatPvPDamageReq { - int64 uid = 1; // 造成伤害的用户ID - optional int64 targetUid = 2; // 目标用户ID(可能是基地,不一定有) - float damage = 3; // 伤害量 -} - -// 通知-PvP击杀单位 statistics.pvp.killunit -message StatPvPKillUnitReq { - int64 uid = 1; // 用户ID - optional int64 targetUid = 2; // 目标用户 - string attacker = 3; // 造成击杀东西(building:兵营 U0001:xxx兵 S0001: 技能) - string victim = 4; // 被击杀的东西(U0001:xxx兵) -} - // 通知-PvP杀兵营(人) statistics.pvp.kill message StatPvPKillReq { int64 uid = 1; // 用户ID @@ -58,10 +43,17 @@ message StatPvPFirstBloodReq { // 通知-PvP战报 statistics.pvp.report message StatPvPReportReq { + message Item { + int64 uid = 1; // 用户ID + int64 damage = 2; // 伤害量 + int64 deDamage = 3; // 承受伤害 + int64 killUnit = 4; // 击杀单位数量 + int64 deKillUnit = 5; // 被杀单位数量 + } int32 winCamp = 1; // 获胜阵营 1-蓝 2-红 int64 generalUid = 2; // 名将UID - repeated int64 winUids = 3; // 战胜方玩家列表 - repeated int64 lostUids = 4; // 战败方玩家列表 + repeated Item winItems = 3; // 获胜方数据 + repeated Item lostItems = 4; // 战败方数据 } // rank @@ -86,8 +78,6 @@ service userCenter { rpc retrievePlatformUser(PlatformUserReq) returns (PlatformUserResp); // statistics - rpc statPvpDamage(StatPvPDamageReq) returns (Empty); - rpc statPvpKillUnit(StatPvPKillUnitReq) returns (Empty); rpc statPvpKill(StatPvPKillReq) returns (Empty); rpc statPvpFirstBlood(StatPvPFirstBloodReq) returns (Empty); rpc statPvpReport(StatPvPReportReq) returns (Empty); diff --git a/app/user_center/pb/user_center_grpc.pb.go b/app/user_center/pb/user_center_grpc.pb.go index 35dd5b7..c0170e8 100644 --- a/app/user_center/pb/user_center_grpc.pb.go +++ b/app/user_center/pb/user_center_grpc.pb.go @@ -25,8 +25,6 @@ type UserCenterClient interface { // user RetrievePlatformUser(ctx context.Context, in *PlatformUserReq, opts ...grpc.CallOption) (*PlatformUserResp, error) // statistics - StatPvpDamage(ctx context.Context, in *StatPvPDamageReq, opts ...grpc.CallOption) (*Empty, error) - StatPvpKillUnit(ctx context.Context, in *StatPvPKillUnitReq, opts ...grpc.CallOption) (*Empty, error) StatPvpKill(ctx context.Context, in *StatPvPKillReq, opts ...grpc.CallOption) (*Empty, error) StatPvpFirstBlood(ctx context.Context, in *StatPvPFirstBloodReq, opts ...grpc.CallOption) (*Empty, error) StatPvpReport(ctx context.Context, in *StatPvPReportReq, opts ...grpc.CallOption) (*Empty, error) @@ -51,24 +49,6 @@ func (c *userCenterClient) RetrievePlatformUser(ctx context.Context, in *Platfor return out, nil } -func (c *userCenterClient) StatPvpDamage(ctx context.Context, in *StatPvPDamageReq, opts ...grpc.CallOption) (*Empty, error) { - out := new(Empty) - err := c.cc.Invoke(ctx, "/pb.userCenter/statPvpDamage", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *userCenterClient) StatPvpKillUnit(ctx context.Context, in *StatPvPKillUnitReq, opts ...grpc.CallOption) (*Empty, error) { - out := new(Empty) - err := c.cc.Invoke(ctx, "/pb.userCenter/statPvpKillUnit", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *userCenterClient) StatPvpKill(ctx context.Context, in *StatPvPKillReq, opts ...grpc.CallOption) (*Empty, error) { out := new(Empty) err := c.cc.Invoke(ctx, "/pb.userCenter/statPvpKill", in, out, opts...) @@ -112,8 +92,6 @@ type UserCenterServer interface { // user RetrievePlatformUser(context.Context, *PlatformUserReq) (*PlatformUserResp, error) // statistics - StatPvpDamage(context.Context, *StatPvPDamageReq) (*Empty, error) - StatPvpKillUnit(context.Context, *StatPvPKillUnitReq) (*Empty, error) StatPvpKill(context.Context, *StatPvPKillReq) (*Empty, error) StatPvpFirstBlood(context.Context, *StatPvPFirstBloodReq) (*Empty, error) StatPvpReport(context.Context, *StatPvPReportReq) (*Empty, error) @@ -129,12 +107,6 @@ type UnimplementedUserCenterServer struct { func (UnimplementedUserCenterServer) RetrievePlatformUser(context.Context, *PlatformUserReq) (*PlatformUserResp, error) { return nil, status.Errorf(codes.Unimplemented, "method RetrievePlatformUser not implemented") } -func (UnimplementedUserCenterServer) StatPvpDamage(context.Context, *StatPvPDamageReq) (*Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method StatPvpDamage not implemented") -} -func (UnimplementedUserCenterServer) StatPvpKillUnit(context.Context, *StatPvPKillUnitReq) (*Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method StatPvpKillUnit not implemented") -} func (UnimplementedUserCenterServer) StatPvpKill(context.Context, *StatPvPKillReq) (*Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method StatPvpKill not implemented") } @@ -178,42 +150,6 @@ func _UserCenter_RetrievePlatformUser_Handler(srv interface{}, ctx context.Conte return interceptor(ctx, in, info, handler) } -func _UserCenter_StatPvpDamage_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(StatPvPDamageReq) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(UserCenterServer).StatPvpDamage(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pb.userCenter/statPvpDamage", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(UserCenterServer).StatPvpDamage(ctx, req.(*StatPvPDamageReq)) - } - return interceptor(ctx, in, info, handler) -} - -func _UserCenter_StatPvpKillUnit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(StatPvPKillUnitReq) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(UserCenterServer).StatPvpKillUnit(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pb.userCenter/statPvpKillUnit", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(UserCenterServer).StatPvpKillUnit(ctx, req.(*StatPvPKillUnitReq)) - } - return interceptor(ctx, in, info, handler) -} - func _UserCenter_StatPvpKill_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(StatPvPKillReq) if err := dec(in); err != nil { @@ -297,14 +233,6 @@ var UserCenter_ServiceDesc = grpc.ServiceDesc{ MethodName: "retrievePlatformUser", Handler: _UserCenter_RetrievePlatformUser_Handler, }, - { - MethodName: "statPvpDamage", - Handler: _UserCenter_StatPvpDamage_Handler, - }, - { - MethodName: "statPvpKillUnit", - Handler: _UserCenter_StatPvpKillUnit_Handler, - }, { MethodName: "statPvpKill", Handler: _UserCenter_StatPvpKill_Handler, diff --git a/app/user_center/usercenter/user_center.go b/app/user_center/usercenter/user_center.go index 354c063..b7663d6 100644 --- a/app/user_center/usercenter/user_center.go +++ b/app/user_center/usercenter/user_center.go @@ -13,25 +13,22 @@ import ( ) type ( - Empty = pb.Empty - PlatformUserReq = pb.PlatformUserReq - PlatformUserResp = pb.PlatformUserResp - RankPvpReq = pb.RankPvpReq - RankPvpResp = pb.RankPvpResp - RankPvpResp_Item = pb.RankPvpResp_Item - StatPvPDamageReq = pb.StatPvPDamageReq - StatPvPFirstBloodReq = pb.StatPvPFirstBloodReq - StatPvPKillReq = pb.StatPvPKillReq - StatPvPKillUnitReq = pb.StatPvPKillUnitReq - StatPvPReportReq = pb.StatPvPReportReq - User = pb.User + Empty = pb.Empty + PlatformUserReq = pb.PlatformUserReq + PlatformUserResp = pb.PlatformUserResp + RankPvpReq = pb.RankPvpReq + RankPvpResp = pb.RankPvpResp + RankPvpResp_Item = pb.RankPvpResp_Item + StatPvPFirstBloodReq = pb.StatPvPFirstBloodReq + StatPvPKillReq = pb.StatPvPKillReq + StatPvPReportReq = pb.StatPvPReportReq + StatPvPReportReq_Item = pb.StatPvPReportReq_Item + User = pb.User UserCenter interface { // user RetrievePlatformUser(ctx context.Context, in *PlatformUserReq, opts ...grpc.CallOption) (*PlatformUserResp, error) // statistics - StatPvpDamage(ctx context.Context, in *StatPvPDamageReq, opts ...grpc.CallOption) (*Empty, error) - StatPvpKillUnit(ctx context.Context, in *StatPvPKillUnitReq, opts ...grpc.CallOption) (*Empty, error) StatPvpKill(ctx context.Context, in *StatPvPKillReq, opts ...grpc.CallOption) (*Empty, error) StatPvpFirstBlood(ctx context.Context, in *StatPvPFirstBloodReq, opts ...grpc.CallOption) (*Empty, error) StatPvpReport(ctx context.Context, in *StatPvPReportReq, opts ...grpc.CallOption) (*Empty, error) @@ -57,16 +54,6 @@ func (m *defaultUserCenter) RetrievePlatformUser(ctx context.Context, in *Platfo } // statistics -func (m *defaultUserCenter) StatPvpDamage(ctx context.Context, in *StatPvPDamageReq, opts ...grpc.CallOption) (*Empty, error) { - client := pb.NewUserCenterClient(m.cli.Conn()) - return client.StatPvpDamage(ctx, in, opts...) -} - -func (m *defaultUserCenter) StatPvpKillUnit(ctx context.Context, in *StatPvPKillUnitReq, opts ...grpc.CallOption) (*Empty, error) { - client := pb.NewUserCenterClient(m.cli.Conn()) - return client.StatPvpKillUnit(ctx, in, opts...) -} - func (m *defaultUserCenter) StatPvpKill(ctx context.Context, in *StatPvPKillReq, opts ...grpc.CallOption) (*Empty, error) { client := pb.NewUserCenterClient(m.cli.Conn()) return client.StatPvpKill(ctx, in, opts...) diff --git a/game/logic/statistics/stat_pvp.go b/game/logic/statistics/stat_pvp.go index 6be4667..1fc3026 100644 --- a/game/logic/statistics/stat_pvp.go +++ b/game/logic/statistics/stat_pvp.go @@ -33,33 +33,6 @@ func (p *PvP) Init() { func (p *PvP) Shutdown() { } -// Damage 伤害记录 -func (p *PvP) Damage(s *session.Session, msg *pbStat.StatPvPDamage) error { - _, err := p.svcCtx.UserCenterRpc.StatPvpDamage(p.svcCtx.Ctx, &usercenter.StatPvPDamageReq{ - Uid: msg.Uid, - TargetUid: msg.TargetUid, - Damage: msg.Damage, - }) - if err != nil { - return err - } - return nil -} - -// KillUnit 击杀单位 -func (p *PvP) KillUnit(s *session.Session, msg *pbStat.StatPvPKillUnit) error { - _, err := p.svcCtx.UserCenterRpc.StatPvpKillUnit(p.svcCtx.Ctx, &usercenter.StatPvPKillUnitReq{ - Uid: msg.Uid, - TargetUid: msg.TargetUid, - Attacker: msg.Attacker, - Victim: msg.Victim, - }) - if err != nil { - return err - } - return nil -} - // Kill 击杀玩家 func (p *PvP) Kill(s *session.Session, msg *pbStat.StatPvPKill) error { _, err := p.svcCtx.UserCenterRpc.StatPvpKill(p.svcCtx.Ctx, &usercenter.StatPvPKillReq{ @@ -87,11 +60,34 @@ func (p *PvP) First(s *session.Session, msg *pbStat.StatPvPFirstBlood) error { // Report 战报 func (p *PvP) Report(s *session.Session, msg *pbStat.StatPvPReport) error { + winItems := make([]*usercenter.StatPvPReportReq_Item, 0, len(msg.WinItems)) + lostItems := make([]*usercenter.StatPvPReportReq_Item, 0, len(msg.LostItems)) + + for _, item := range msg.WinItems { + winItems = append(winItems, &usercenter.StatPvPReportReq_Item{ + Uid: item.Uid, + Damage: item.Damage, + DeDamage: item.DeDamage, + KillUnit: item.KillUnit, + DeKillUnit: item.DeKillUnit, + }) + } + + for _, item := range msg.LostItems { + lostItems = append(lostItems, &usercenter.StatPvPReportReq_Item{ + Uid: item.Uid, + Damage: item.Damage, + DeDamage: item.DeDamage, + KillUnit: item.KillUnit, + DeKillUnit: item.DeKillUnit, + }) + } + _, err := p.svcCtx.UserCenterRpc.StatPvpReport(p.svcCtx.Ctx, &usercenter.StatPvPReportReq{ WinCamp: msg.WinCamp, GeneralUid: msg.GeneralUid, - WinUids: msg.WinUids, - LostUids: msg.LostUids, + WinItems: winItems, + LostItems: lostItems, }) if err != nil { return err diff --git a/game/pb/rank/Rank.cs b/game/pb/rank/Rank.cs index e7bcfcc..4ad252d 100644 --- a/game/pb/rank/Rank.cs +++ b/game/pb/rank/Rank.cs @@ -28,9 +28,12 @@ namespace PbClient { "ASABKAUSDAoEdG9wThgCIAEoBSKJAQoLUmFua1B2cFJlc3ASDAoEdHlwZRgB", "IAEoBRIpCgVpdGVtcxgCIAMoCzIaLnBiQ2xpZW50LlJhbmtQdnBSZXNwLkl0", "ZW0aQQoESXRlbRILCgN1aWQYASABKAMSDQoFdW5hbWUYAiABKAkSDQoFc2Nv", - "cmUYAyABKAMSDgoGYXZhdGFyGAQgASgJKk4KCFJhbmtUeXBlEgsKB1Vua25v", - "d24QABIKCgZEYW1hZ2UQARILCgdHZW5lcmFsEAISDAoIS2lsbFVuaXQQAxIO", - "CgpLaWxsUGxheWVyEARCCVoHL3BiUmFua2IGcHJvdG8z")); + "cmUYAyABKAMSDgoGYXZhdGFyGAQgASgJKsIBCghSYW5rVHlwZRILCgdVbmtu", + "b3duEAASCgoGRGFtYWdlEAESDAoIRGVEYW1hZ2UQAhILCgdHZW5lcmFsEAMS", + "DQoJRGVHZW5lcmFsEAQSDAoIS2lsbFVuaXQQBRIOCgpEZUtpbGxVbml0EAYS", + "DgoKS2lsbFBsYXllchAHEhAKDERlS2lsbFBsYXllchAIEgcKA1dpbhAJEggK", + "BExvc3QQChIOCgpGaXJzdEJsb29kEAsSEAoMRGVGaXJzdEJsb29kEAxCCVoH", + "L3BiUmFua2IGcHJvdG8z")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::PbClient.RankType), }, null, new pbr::GeneratedClrTypeInfo[] { @@ -44,10 +47,54 @@ namespace PbClient { #region Enums public enum RankType { [pbr::OriginalName("Unknown")] Unknown = 0, + /// + /// 伤害榜 + /// [pbr::OriginalName("Damage")] Damage = 1, - [pbr::OriginalName("General")] General = 2, - [pbr::OriginalName("KillUnit")] KillUnit = 3, - [pbr::OriginalName("KillPlayer")] KillPlayer = 4, + /// + /// 受伤榜 + /// + [pbr::OriginalName("DeDamage")] DeDamage = 2, + /// + /// 名将榜 + /// + [pbr::OriginalName("General")] General = 3, + /// + /// 落马榜 + /// + [pbr::OriginalName("DeGeneral")] DeGeneral = 4, + /// + /// 小兵击杀 + /// + [pbr::OriginalName("KillUnit")] KillUnit = 5, + /// + /// 小兵被杀 + /// + [pbr::OriginalName("DeKillUnit")] DeKillUnit = 6, + /// + /// 击杀玩家 + /// + [pbr::OriginalName("KillPlayer")] KillPlayer = 7, + /// + /// 被杀榜 + /// + [pbr::OriginalName("DeKillPlayer")] DeKillPlayer = 8, + /// + /// 获胜榜 + /// + [pbr::OriginalName("Win")] Win = 9, + /// + /// 战败榜 + /// + [pbr::OriginalName("Lost")] Lost = 10, + /// + /// 一血榜 + /// + [pbr::OriginalName("FirstBlood")] FirstBlood = 11, + /// + /// 被拿一血榜 + /// + [pbr::OriginalName("DeFirstBlood")] DeFirstBlood = 12, } #endregion diff --git a/game/pb/rank/rank.pb.go b/game/pb/rank/rank.pb.go index 65212a9..9d8af9b 100644 --- a/game/pb/rank/rank.pb.go +++ b/game/pb/rank/rank.pb.go @@ -23,28 +23,52 @@ const ( type RankType int32 const ( - RankType_Unknown RankType = 0 - RankType_Damage RankType = 1 - RankType_General RankType = 2 - RankType_KillUnit RankType = 3 - RankType_KillPlayer RankType = 4 + RankType_Unknown RankType = 0 + RankType_Damage RankType = 1 // 伤害榜 + RankType_DeDamage RankType = 2 // 受伤榜 + RankType_General RankType = 3 // 名将榜 + RankType_DeGeneral RankType = 4 // 落马榜 + RankType_KillUnit RankType = 5 // 小兵击杀 + RankType_DeKillUnit RankType = 6 // 小兵被杀 + RankType_KillPlayer RankType = 7 // 击杀玩家 + RankType_DeKillPlayer RankType = 8 // 被杀榜 + RankType_Win RankType = 9 // 获胜榜 + RankType_Lost RankType = 10 // 战败榜 + RankType_FirstBlood RankType = 11 // 一血榜 + RankType_DeFirstBlood RankType = 12 // 被拿一血榜 ) // Enum value maps for RankType. var ( RankType_name = map[int32]string{ - 0: "Unknown", - 1: "Damage", - 2: "General", - 3: "KillUnit", - 4: "KillPlayer", + 0: "Unknown", + 1: "Damage", + 2: "DeDamage", + 3: "General", + 4: "DeGeneral", + 5: "KillUnit", + 6: "DeKillUnit", + 7: "KillPlayer", + 8: "DeKillPlayer", + 9: "Win", + 10: "Lost", + 11: "FirstBlood", + 12: "DeFirstBlood", } RankType_value = map[string]int32{ - "Unknown": 0, - "Damage": 1, - "General": 2, - "KillUnit": 3, - "KillPlayer": 4, + "Unknown": 0, + "Damage": 1, + "DeDamage": 2, + "General": 3, + "DeGeneral": 4, + "KillUnit": 5, + "DeKillUnit": 6, + "KillPlayer": 7, + "DeKillPlayer": 8, + "Win": 9, + "Lost": 10, + "FirstBlood": 11, + "DeFirstBlood": 12, } ) @@ -277,13 +301,20 @@ var file_rank_proto_rawDesc = []byte{ 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x61, 0x76, 0x61, 0x74, 0x61, 0x72, - 0x2a, 0x4e, 0x0a, 0x08, 0x52, 0x61, 0x6e, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, - 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x61, 0x6d, - 0x61, 0x67, 0x65, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, - 0x10, 0x02, 0x12, 0x0c, 0x0a, 0x08, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x10, 0x03, - 0x12, 0x0e, 0x0a, 0x0a, 0x4b, 0x69, 0x6c, 0x6c, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x10, 0x04, - 0x42, 0x09, 0x5a, 0x07, 0x2f, 0x70, 0x62, 0x52, 0x61, 0x6e, 0x6b, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x2a, 0xc2, 0x01, 0x0a, 0x08, 0x52, 0x61, 0x6e, 0x6b, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, + 0x07, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x61, + 0x6d, 0x61, 0x67, 0x65, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x65, 0x44, 0x61, 0x6d, 0x61, + 0x67, 0x65, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x10, + 0x03, 0x12, 0x0d, 0x0a, 0x09, 0x44, 0x65, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x10, 0x04, + 0x12, 0x0c, 0x0a, 0x08, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x10, 0x05, 0x12, 0x0e, + 0x0a, 0x0a, 0x44, 0x65, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x10, 0x06, 0x12, 0x0e, + 0x0a, 0x0a, 0x4b, 0x69, 0x6c, 0x6c, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x10, 0x07, 0x12, 0x10, + 0x0a, 0x0c, 0x44, 0x65, 0x4b, 0x69, 0x6c, 0x6c, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x10, 0x08, + 0x12, 0x07, 0x0a, 0x03, 0x57, 0x69, 0x6e, 0x10, 0x09, 0x12, 0x08, 0x0a, 0x04, 0x4c, 0x6f, 0x73, + 0x74, 0x10, 0x0a, 0x12, 0x0e, 0x0a, 0x0a, 0x46, 0x69, 0x72, 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x6f, + 0x64, 0x10, 0x0b, 0x12, 0x10, 0x0a, 0x0c, 0x44, 0x65, 0x46, 0x69, 0x72, 0x73, 0x74, 0x42, 0x6c, + 0x6f, 0x6f, 0x64, 0x10, 0x0c, 0x42, 0x09, 0x5a, 0x07, 0x2f, 0x70, 0x62, 0x52, 0x61, 0x6e, 0x6b, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/game/pb/rank/rank.proto b/game/pb/rank/rank.proto index df8441c..63d40e4 100644 --- a/game/pb/rank/rank.proto +++ b/game/pb/rank/rank.proto @@ -6,10 +6,18 @@ option go_package = "/pbRank"; enum RankType { Unknown = 0; - Damage = 1; - General = 2; - KillUnit = 3; - KillPlayer = 4; + Damage = 1; // 伤害榜 + DeDamage = 2; // 受伤榜 + General = 3; // 名将榜 + DeGeneral = 4; // 落马榜 + KillUnit = 5; // 小兵击杀 + DeKillUnit = 6; // 小兵被杀 + KillPlayer = 7; // 击杀玩家 + DeKillPlayer = 8; // 被杀榜 + Win = 9; // 获胜榜 + Lost = 10; // 战败榜 + FirstBlood = 11; // 一血榜 + DeFirstBlood = 12; // 被拿一血榜 } // RankPvpReq 获取排行榜 request > rank.pvp diff --git a/game/pb/stat/Stat.cs b/game/pb/stat/Stat.cs index aa45ef7..3cf80a7 100644 --- a/game/pb/stat/Stat.cs +++ b/game/pb/stat/Stat.cs @@ -24,650 +24,27 @@ namespace PbClient { static StatReflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "CgpzdGF0LnByb3RvEghwYkNsaWVudCJSCg1TdGF0UHZQRGFtYWdlEgsKA3Vp", - "ZBgBIAEoAxIWCgl0YXJnZXRVaWQYAiABKANIAIgBARIOCgZkYW1hZ2UYAyAB", - "KAJCDAoKX3RhcmdldFVpZCJmCg9TdGF0UHZQS2lsbFVuaXQSCwoDdWlkGAEg", - "ASgDEhYKCXRhcmdldFVpZBgCIAEoA0gAiAEBEhAKCGF0dGFja2VyGAMgASgJ", - "Eg4KBnZpY3RpbRgEIAEoCUIMCgpfdGFyZ2V0VWlkIkAKC1N0YXRQdlBLaWxs", - "EgsKA3VpZBgBIAEoAxIRCgl0YXJnZXRVaWQYAiABKAMSEQoJaXNHZW5lcmFs", - "GAMgASgIIi4KEVN0YXRQdlBGaXJzdEJsb29kEgsKA3VpZBgBIAEoAxIMCgR0", - "eXBlGAIgASgFIlcKDVN0YXRQdlBSZXBvcnQSDwoHd2luQ2FtcBgBIAEoBRIS", - "CgpnZW5lcmFsVWlkGAIgASgDEg8KB3dpblVpZHMYAyADKAMSEAoIbG9zdFVp", - "ZHMYBCADKANCCVoHL3BiU3RhdGIGcHJvdG8z")); + "CgpzdGF0LnByb3RvEghwYkNsaWVudCJACgtTdGF0UHZQS2lsbBILCgN1aWQY", + "ASABKAMSEQoJdGFyZ2V0VWlkGAIgASgDEhEKCWlzR2VuZXJhbBgDIAEoCCIu", + "ChFTdGF0UHZQRmlyc3RCbG9vZBILCgN1aWQYASABKAMSDAoEdHlwZRgCIAEo", + "BSLyAQoNU3RhdFB2UFJlcG9ydBIPCgd3aW5DYW1wGAEgASgFEhIKCmdlbmVy", + "YWxVaWQYAiABKAMSLgoId2luSXRlbXMYAyADKAsyHC5wYkNsaWVudC5TdGF0", + "UHZQUmVwb3J0Lkl0ZW0SLwoJbG9zdEl0ZW1zGAQgAygLMhwucGJDbGllbnQu", + "U3RhdFB2UFJlcG9ydC5JdGVtGlsKBEl0ZW0SCwoDdWlkGAEgASgDEg4KBmRh", + "bWFnZRgCIAEoAxIQCghkZURhbWFnZRgDIAEoAxIQCghraWxsVW5pdBgEIAEo", + "AxISCgpkZUtpbGxVbml0GAUgASgDQglaBy9wYlN0YXRiBnByb3RvMw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { }, new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] { - new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPDamage), global::PbClient.StatPvPDamage.Parser, new[]{ "Uid", "TargetUid", "Damage" }, new[]{ "TargetUid" }, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPKillUnit), global::PbClient.StatPvPKillUnit.Parser, new[]{ "Uid", "TargetUid", "Attacker", "Victim" }, new[]{ "TargetUid" }, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPKill), global::PbClient.StatPvPKill.Parser, new[]{ "Uid", "TargetUid", "IsGeneral" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPFirstBlood), global::PbClient.StatPvPFirstBlood.Parser, new[]{ "Uid", "Type" }, null, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPReport), global::PbClient.StatPvPReport.Parser, new[]{ "WinCamp", "GeneralUid", "WinUids", "LostUids" }, null, null, null, null) + new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPReport), global::PbClient.StatPvPReport.Parser, new[]{ "WinCamp", "GeneralUid", "WinItems", "LostItems" }, null, null, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::PbClient.StatPvPReport.Types.Item), global::PbClient.StatPvPReport.Types.Item.Parser, new[]{ "Uid", "Damage", "DeDamage", "KillUnit", "DeKillUnit" }, null, null, null, null)}) })); } #endregion } #region Messages - /// - /// 通知-PvP伤害 statistics.pvp.damage - /// - public sealed partial class StatPvPDamage : pb::IMessage - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - , pb::IBufferMessage - #endif - { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new StatPvPDamage()); - private pb::UnknownFieldSet _unknownFields; - private int _hasBits0; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public static pbr::MessageDescriptor Descriptor { - get { return global::PbClient.StatReflection.Descriptor.MessageTypes[0]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPDamage() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPDamage(StatPvPDamage other) : this() { - _hasBits0 = other._hasBits0; - uid_ = other.uid_; - targetUid_ = other.targetUid_; - damage_ = other.damage_; - _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPDamage Clone() { - return new StatPvPDamage(this); - } - - /// Field number for the "uid" field. - public const int UidFieldNumber = 1; - private long uid_; - /// - /// 造成伤害的用户ID - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public long Uid { - get { return uid_; } - set { - uid_ = value; - } - } - - /// Field number for the "targetUid" field. - public const int TargetUidFieldNumber = 2; - private long targetUid_; - /// - /// 目标用户ID(可能是基地,不一定有) - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public long TargetUid { - get { if ((_hasBits0 & 1) != 0) { return targetUid_; } else { return 0L; } } - set { - _hasBits0 |= 1; - targetUid_ = value; - } - } - /// Gets whether the "targetUid" field is set - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public bool HasTargetUid { - get { return (_hasBits0 & 1) != 0; } - } - /// Clears the value of the "targetUid" field - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void ClearTargetUid() { - _hasBits0 &= ~1; - } - - /// Field number for the "damage" field. - public const int DamageFieldNumber = 3; - private float damage_; - /// - /// 伤害量 - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public float Damage { - get { return damage_; } - set { - damage_ = value; - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override bool Equals(object other) { - return Equals(other as StatPvPDamage); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public bool Equals(StatPvPDamage other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - if (Uid != other.Uid) return false; - if (TargetUid != other.TargetUid) return false; - if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(Damage, other.Damage)) return false; - return Equals(_unknownFields, other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override int GetHashCode() { - int hash = 1; - if (Uid != 0L) hash ^= Uid.GetHashCode(); - if (HasTargetUid) hash ^= TargetUid.GetHashCode(); - if (Damage != 0F) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(Damage); - if (_unknownFields != null) { - hash ^= _unknownFields.GetHashCode(); - } - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void WriteTo(pb::CodedOutputStream output) { - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - output.WriteRawMessage(this); - #else - if (Uid != 0L) { - output.WriteRawTag(8); - output.WriteInt64(Uid); - } - if (HasTargetUid) { - output.WriteRawTag(16); - output.WriteInt64(TargetUid); - } - if (Damage != 0F) { - output.WriteRawTag(29); - output.WriteFloat(Damage); - } - if (_unknownFields != null) { - _unknownFields.WriteTo(output); - } - #endif - } - - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { - if (Uid != 0L) { - output.WriteRawTag(8); - output.WriteInt64(Uid); - } - if (HasTargetUid) { - output.WriteRawTag(16); - output.WriteInt64(TargetUid); - } - if (Damage != 0F) { - output.WriteRawTag(29); - output.WriteFloat(Damage); - } - if (_unknownFields != null) { - _unknownFields.WriteTo(ref output); - } - } - #endif - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public int CalculateSize() { - int size = 0; - if (Uid != 0L) { - size += 1 + pb::CodedOutputStream.ComputeInt64Size(Uid); - } - if (HasTargetUid) { - size += 1 + pb::CodedOutputStream.ComputeInt64Size(TargetUid); - } - if (Damage != 0F) { - size += 1 + 4; - } - if (_unknownFields != null) { - size += _unknownFields.CalculateSize(); - } - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void MergeFrom(StatPvPDamage other) { - if (other == null) { - return; - } - if (other.Uid != 0L) { - Uid = other.Uid; - } - if (other.HasTargetUid) { - TargetUid = other.TargetUid; - } - if (other.Damage != 0F) { - Damage = other.Damage; - } - _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void MergeFrom(pb::CodedInputStream input) { - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - input.ReadRawMessage(this); - #else - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); - break; - case 8: { - Uid = input.ReadInt64(); - break; - } - case 16: { - TargetUid = input.ReadInt64(); - break; - } - case 29: { - Damage = input.ReadFloat(); - break; - } - } - } - #endif - } - - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); - break; - case 8: { - Uid = input.ReadInt64(); - break; - } - case 16: { - TargetUid = input.ReadInt64(); - break; - } - case 29: { - Damage = input.ReadFloat(); - break; - } - } - } - } - #endif - - } - - /// - /// 通知-PvP击杀单位 statistics.pvp.killunit - /// - public sealed partial class StatPvPKillUnit : pb::IMessage - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - , pb::IBufferMessage - #endif - { - private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new StatPvPKillUnit()); - private pb::UnknownFieldSet _unknownFields; - private int _hasBits0; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public static pb::MessageParser Parser { get { return _parser; } } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public static pbr::MessageDescriptor Descriptor { - get { return global::PbClient.StatReflection.Descriptor.MessageTypes[1]; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - pbr::MessageDescriptor pb::IMessage.Descriptor { - get { return Descriptor; } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPKillUnit() { - OnConstruction(); - } - - partial void OnConstruction(); - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPKillUnit(StatPvPKillUnit other) : this() { - _hasBits0 = other._hasBits0; - uid_ = other.uid_; - targetUid_ = other.targetUid_; - attacker_ = other.attacker_; - victim_ = other.victim_; - _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public StatPvPKillUnit Clone() { - return new StatPvPKillUnit(this); - } - - /// Field number for the "uid" field. - public const int UidFieldNumber = 1; - private long uid_; - /// - /// 用户ID - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public long Uid { - get { return uid_; } - set { - uid_ = value; - } - } - - /// Field number for the "targetUid" field. - public const int TargetUidFieldNumber = 2; - private long targetUid_; - /// - /// 目标用户 - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public long TargetUid { - get { if ((_hasBits0 & 1) != 0) { return targetUid_; } else { return 0L; } } - set { - _hasBits0 |= 1; - targetUid_ = value; - } - } - /// Gets whether the "targetUid" field is set - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public bool HasTargetUid { - get { return (_hasBits0 & 1) != 0; } - } - /// Clears the value of the "targetUid" field - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void ClearTargetUid() { - _hasBits0 &= ~1; - } - - /// Field number for the "attacker" field. - public const int AttackerFieldNumber = 3; - private string attacker_ = ""; - /// - /// 造成击杀东西(building:兵营 U0001:xxx兵 S0001: 技能) - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public string Attacker { - get { return attacker_; } - set { - attacker_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); - } - } - - /// Field number for the "victim" field. - public const int VictimFieldNumber = 4; - private string victim_ = ""; - /// - /// 被击杀的东西(U0001:xxx兵) - /// - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public string Victim { - get { return victim_; } - set { - victim_ = pb::ProtoPreconditions.CheckNotNull(value, "value"); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override bool Equals(object other) { - return Equals(other as StatPvPKillUnit); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public bool Equals(StatPvPKillUnit other) { - if (ReferenceEquals(other, null)) { - return false; - } - if (ReferenceEquals(other, this)) { - return true; - } - if (Uid != other.Uid) return false; - if (TargetUid != other.TargetUid) return false; - if (Attacker != other.Attacker) return false; - if (Victim != other.Victim) return false; - return Equals(_unknownFields, other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override int GetHashCode() { - int hash = 1; - if (Uid != 0L) hash ^= Uid.GetHashCode(); - if (HasTargetUid) hash ^= TargetUid.GetHashCode(); - if (Attacker.Length != 0) hash ^= Attacker.GetHashCode(); - if (Victim.Length != 0) hash ^= Victim.GetHashCode(); - if (_unknownFields != null) { - hash ^= _unknownFields.GetHashCode(); - } - return hash; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public override string ToString() { - return pb::JsonFormatter.ToDiagnosticString(this); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void WriteTo(pb::CodedOutputStream output) { - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - output.WriteRawMessage(this); - #else - if (Uid != 0L) { - output.WriteRawTag(8); - output.WriteInt64(Uid); - } - if (HasTargetUid) { - output.WriteRawTag(16); - output.WriteInt64(TargetUid); - } - if (Attacker.Length != 0) { - output.WriteRawTag(26); - output.WriteString(Attacker); - } - if (Victim.Length != 0) { - output.WriteRawTag(34); - output.WriteString(Victim); - } - if (_unknownFields != null) { - _unknownFields.WriteTo(output); - } - #endif - } - - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { - if (Uid != 0L) { - output.WriteRawTag(8); - output.WriteInt64(Uid); - } - if (HasTargetUid) { - output.WriteRawTag(16); - output.WriteInt64(TargetUid); - } - if (Attacker.Length != 0) { - output.WriteRawTag(26); - output.WriteString(Attacker); - } - if (Victim.Length != 0) { - output.WriteRawTag(34); - output.WriteString(Victim); - } - if (_unknownFields != null) { - _unknownFields.WriteTo(ref output); - } - } - #endif - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public int CalculateSize() { - int size = 0; - if (Uid != 0L) { - size += 1 + pb::CodedOutputStream.ComputeInt64Size(Uid); - } - if (HasTargetUid) { - size += 1 + pb::CodedOutputStream.ComputeInt64Size(TargetUid); - } - if (Attacker.Length != 0) { - size += 1 + pb::CodedOutputStream.ComputeStringSize(Attacker); - } - if (Victim.Length != 0) { - size += 1 + pb::CodedOutputStream.ComputeStringSize(Victim); - } - if (_unknownFields != null) { - size += _unknownFields.CalculateSize(); - } - return size; - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void MergeFrom(StatPvPKillUnit other) { - if (other == null) { - return; - } - if (other.Uid != 0L) { - Uid = other.Uid; - } - if (other.HasTargetUid) { - TargetUid = other.TargetUid; - } - if (other.Attacker.Length != 0) { - Attacker = other.Attacker; - } - if (other.Victim.Length != 0) { - Victim = other.Victim; - } - _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public void MergeFrom(pb::CodedInputStream input) { - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - input.ReadRawMessage(this); - #else - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); - break; - case 8: { - Uid = input.ReadInt64(); - break; - } - case 16: { - TargetUid = input.ReadInt64(); - break; - } - case 26: { - Attacker = input.ReadString(); - break; - } - case 34: { - Victim = input.ReadString(); - break; - } - } - } - #endif - } - - #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE - [global::System.Diagnostics.DebuggerNonUserCodeAttribute] - [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { - uint tag; - while ((tag = input.ReadTag()) != 0) { - switch(tag) { - default: - _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); - break; - case 8: { - Uid = input.ReadInt64(); - break; - } - case 16: { - TargetUid = input.ReadInt64(); - break; - } - case 26: { - Attacker = input.ReadString(); - break; - } - case 34: { - Victim = input.ReadString(); - break; - } - } - } - } - #endif - - } - /// /// 通知-PvP杀兵营(人) statistics.pvp.kill /// @@ -685,7 +62,7 @@ namespace PbClient { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { - get { return global::PbClient.StatReflection.Descriptor.MessageTypes[2]; } + get { return global::PbClient.StatReflection.Descriptor.MessageTypes[0]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -960,7 +337,7 @@ namespace PbClient { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { - get { return global::PbClient.StatReflection.Descriptor.MessageTypes[3]; } + get { return global::PbClient.StatReflection.Descriptor.MessageTypes[1]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1195,7 +572,7 @@ namespace PbClient { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public static pbr::MessageDescriptor Descriptor { - get { return global::PbClient.StatReflection.Descriptor.MessageTypes[4]; } + get { return global::PbClient.StatReflection.Descriptor.MessageTypes[2]; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1217,8 +594,8 @@ namespace PbClient { public StatPvPReport(StatPvPReport other) : this() { winCamp_ = other.winCamp_; generalUid_ = other.generalUid_; - winUids_ = other.winUids_.Clone(); - lostUids_ = other.lostUids_.Clone(); + winItems_ = other.winItems_.Clone(); + lostItems_ = other.lostItems_.Clone(); _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } @@ -1258,32 +635,32 @@ namespace PbClient { } } - /// Field number for the "winUids" field. - public const int WinUidsFieldNumber = 3; - private static readonly pb::FieldCodec _repeated_winUids_codec - = pb::FieldCodec.ForInt64(26); - private readonly pbc::RepeatedField winUids_ = new pbc::RepeatedField(); + /// Field number for the "winItems" field. + public const int WinItemsFieldNumber = 3; + private static readonly pb::FieldCodec _repeated_winItems_codec + = pb::FieldCodec.ForMessage(26, global::PbClient.StatPvPReport.Types.Item.Parser); + private readonly pbc::RepeatedField winItems_ = new pbc::RepeatedField(); /// - /// 战胜方玩家列表 + /// 获胜方数据 /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public pbc::RepeatedField WinUids { - get { return winUids_; } + public pbc::RepeatedField WinItems { + get { return winItems_; } } - /// Field number for the "lostUids" field. - public const int LostUidsFieldNumber = 4; - private static readonly pb::FieldCodec _repeated_lostUids_codec - = pb::FieldCodec.ForInt64(34); - private readonly pbc::RepeatedField lostUids_ = new pbc::RepeatedField(); + /// Field number for the "lostItems" field. + public const int LostItemsFieldNumber = 4; + private static readonly pb::FieldCodec _repeated_lostItems_codec + = pb::FieldCodec.ForMessage(34, global::PbClient.StatPvPReport.Types.Item.Parser); + private readonly pbc::RepeatedField lostItems_ = new pbc::RepeatedField(); /// - /// 战败方玩家列表 + /// 战败方数据 /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] - public pbc::RepeatedField LostUids { - get { return lostUids_; } + public pbc::RepeatedField LostItems { + get { return lostItems_; } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1303,8 +680,8 @@ namespace PbClient { } if (WinCamp != other.WinCamp) return false; if (GeneralUid != other.GeneralUid) return false; - if(!winUids_.Equals(other.winUids_)) return false; - if(!lostUids_.Equals(other.lostUids_)) return false; + if(!winItems_.Equals(other.winItems_)) return false; + if(!lostItems_.Equals(other.lostItems_)) return false; return Equals(_unknownFields, other._unknownFields); } @@ -1314,8 +691,8 @@ namespace PbClient { int hash = 1; if (WinCamp != 0) hash ^= WinCamp.GetHashCode(); if (GeneralUid != 0L) hash ^= GeneralUid.GetHashCode(); - hash ^= winUids_.GetHashCode(); - hash ^= lostUids_.GetHashCode(); + hash ^= winItems_.GetHashCode(); + hash ^= lostItems_.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } @@ -1342,8 +719,8 @@ namespace PbClient { output.WriteRawTag(16); output.WriteInt64(GeneralUid); } - winUids_.WriteTo(output, _repeated_winUids_codec); - lostUids_.WriteTo(output, _repeated_lostUids_codec); + winItems_.WriteTo(output, _repeated_winItems_codec); + lostItems_.WriteTo(output, _repeated_lostItems_codec); if (_unknownFields != null) { _unknownFields.WriteTo(output); } @@ -1362,8 +739,8 @@ namespace PbClient { output.WriteRawTag(16); output.WriteInt64(GeneralUid); } - winUids_.WriteTo(ref output, _repeated_winUids_codec); - lostUids_.WriteTo(ref output, _repeated_lostUids_codec); + winItems_.WriteTo(ref output, _repeated_winItems_codec); + lostItems_.WriteTo(ref output, _repeated_lostItems_codec); if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } @@ -1380,8 +757,8 @@ namespace PbClient { if (GeneralUid != 0L) { size += 1 + pb::CodedOutputStream.ComputeInt64Size(GeneralUid); } - size += winUids_.CalculateSize(_repeated_winUids_codec); - size += lostUids_.CalculateSize(_repeated_lostUids_codec); + size += winItems_.CalculateSize(_repeated_winItems_codec); + size += lostItems_.CalculateSize(_repeated_lostItems_codec); if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } @@ -1400,8 +777,8 @@ namespace PbClient { if (other.GeneralUid != 0L) { GeneralUid = other.GeneralUid; } - winUids_.Add(other.winUids_); - lostUids_.Add(other.lostUids_); + winItems_.Add(other.winItems_); + lostItems_.Add(other.lostItems_); _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } @@ -1425,14 +802,12 @@ namespace PbClient { GeneralUid = input.ReadInt64(); break; } - case 26: - case 24: { - winUids_.AddEntriesFrom(input, _repeated_winUids_codec); + case 26: { + winItems_.AddEntriesFrom(input, _repeated_winItems_codec); break; } - case 34: - case 32: { - lostUids_.AddEntriesFrom(input, _repeated_lostUids_codec); + case 34: { + lostItems_.AddEntriesFrom(input, _repeated_lostItems_codec); break; } } @@ -1458,14 +833,12 @@ namespace PbClient { GeneralUid = input.ReadInt64(); break; } - case 26: - case 24: { - winUids_.AddEntriesFrom(ref input, _repeated_winUids_codec); + case 26: { + winItems_.AddEntriesFrom(ref input, _repeated_winItems_codec); break; } - case 34: - case 32: { - lostUids_.AddEntriesFrom(ref input, _repeated_lostUids_codec); + case 34: { + lostItems_.AddEntriesFrom(ref input, _repeated_lostItems_codec); break; } } @@ -1473,6 +846,366 @@ namespace PbClient { } #endif + #region Nested types + /// Container for nested types declared in the StatPvPReport message type. + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public static partial class Types { + public sealed partial class Item : pb::IMessage + #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE + , pb::IBufferMessage + #endif + { + private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new Item()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public static pb::MessageParser Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public static pbr::MessageDescriptor Descriptor { + get { return global::PbClient.StatPvPReport.Descriptor.NestedTypes[0]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public Item() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public Item(Item other) : this() { + uid_ = other.uid_; + damage_ = other.damage_; + deDamage_ = other.deDamage_; + killUnit_ = other.killUnit_; + deKillUnit_ = other.deKillUnit_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public Item Clone() { + return new Item(this); + } + + /// Field number for the "uid" field. + public const int UidFieldNumber = 1; + private long uid_; + /// + /// 用户ID + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public long Uid { + get { return uid_; } + set { + uid_ = value; + } + } + + /// Field number for the "damage" field. + public const int DamageFieldNumber = 2; + private long damage_; + /// + /// 伤害量 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public long Damage { + get { return damage_; } + set { + damage_ = value; + } + } + + /// Field number for the "deDamage" field. + public const int DeDamageFieldNumber = 3; + private long deDamage_; + /// + /// 承受伤害 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public long DeDamage { + get { return deDamage_; } + set { + deDamage_ = value; + } + } + + /// Field number for the "killUnit" field. + public const int KillUnitFieldNumber = 4; + private long killUnit_; + /// + /// 击杀单位数量 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public long KillUnit { + get { return killUnit_; } + set { + killUnit_ = value; + } + } + + /// Field number for the "deKillUnit" field. + public const int DeKillUnitFieldNumber = 5; + private long deKillUnit_; + /// + /// 被杀单位数量 + /// + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public long DeKillUnit { + get { return deKillUnit_; } + set { + deKillUnit_ = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public override bool Equals(object other) { + return Equals(other as Item); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public bool Equals(Item other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + if (Uid != other.Uid) return false; + if (Damage != other.Damage) return false; + if (DeDamage != other.DeDamage) return false; + if (KillUnit != other.KillUnit) return false; + if (DeKillUnit != other.DeKillUnit) return false; + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public override int GetHashCode() { + int hash = 1; + if (Uid != 0L) hash ^= Uid.GetHashCode(); + if (Damage != 0L) hash ^= Damage.GetHashCode(); + if (DeDamage != 0L) hash ^= DeDamage.GetHashCode(); + if (KillUnit != 0L) hash ^= KillUnit.GetHashCode(); + if (DeKillUnit != 0L) hash ^= DeKillUnit.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public void WriteTo(pb::CodedOutputStream output) { + #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE + output.WriteRawMessage(this); + #else + if (Uid != 0L) { + output.WriteRawTag(8); + output.WriteInt64(Uid); + } + if (Damage != 0L) { + output.WriteRawTag(16); + output.WriteInt64(Damage); + } + if (DeDamage != 0L) { + output.WriteRawTag(24); + output.WriteInt64(DeDamage); + } + if (KillUnit != 0L) { + output.WriteRawTag(32); + output.WriteInt64(KillUnit); + } + if (DeKillUnit != 0L) { + output.WriteRawTag(40); + output.WriteInt64(DeKillUnit); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + #endif + } + + #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) { + if (Uid != 0L) { + output.WriteRawTag(8); + output.WriteInt64(Uid); + } + if (Damage != 0L) { + output.WriteRawTag(16); + output.WriteInt64(Damage); + } + if (DeDamage != 0L) { + output.WriteRawTag(24); + output.WriteInt64(DeDamage); + } + if (KillUnit != 0L) { + output.WriteRawTag(32); + output.WriteInt64(KillUnit); + } + if (DeKillUnit != 0L) { + output.WriteRawTag(40); + output.WriteInt64(DeKillUnit); + } + if (_unknownFields != null) { + _unknownFields.WriteTo(ref output); + } + } + #endif + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public int CalculateSize() { + int size = 0; + if (Uid != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(Uid); + } + if (Damage != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(Damage); + } + if (DeDamage != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(DeDamage); + } + if (KillUnit != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(KillUnit); + } + if (DeKillUnit != 0L) { + size += 1 + pb::CodedOutputStream.ComputeInt64Size(DeKillUnit); + } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public void MergeFrom(Item other) { + if (other == null) { + return; + } + if (other.Uid != 0L) { + Uid = other.Uid; + } + if (other.Damage != 0L) { + Damage = other.Damage; + } + if (other.DeDamage != 0L) { + DeDamage = other.DeDamage; + } + if (other.KillUnit != 0L) { + KillUnit = other.KillUnit; + } + if (other.DeKillUnit != 0L) { + DeKillUnit = other.DeKillUnit; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public void MergeFrom(pb::CodedInputStream input) { + #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE + input.ReadRawMessage(this); + #else + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + case 8: { + Uid = input.ReadInt64(); + break; + } + case 16: { + Damage = input.ReadInt64(); + break; + } + case 24: { + DeDamage = input.ReadInt64(); + break; + } + case 32: { + KillUnit = input.ReadInt64(); + break; + } + case 40: { + DeKillUnit = input.ReadInt64(); + break; + } + } + } + #endif + } + + #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input); + break; + case 8: { + Uid = input.ReadInt64(); + break; + } + case 16: { + Damage = input.ReadInt64(); + break; + } + case 24: { + DeDamage = input.ReadInt64(); + break; + } + case 32: { + KillUnit = input.ReadInt64(); + break; + } + case 40: { + DeKillUnit = input.ReadInt64(); + break; + } + } + } + } + #endif + + } + + } + #endregion + } #endregion diff --git a/game/pb/stat/stat.pb.go b/game/pb/stat/stat.pb.go index e5e1500..199c932 100644 --- a/game/pb/stat/stat.pb.go +++ b/game/pb/stat/stat.pb.go @@ -20,19 +20,19 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) -// 通知-PvP伤害 statistics.pvp.damage -type StatPvPDamage struct { +// 通知-PvP杀兵营(人) statistics.pvp.kill +type StatPvPKill struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 造成伤害的用户ID - TargetUid *int64 `protobuf:"varint,2,opt,name=targetUid,proto3,oneof" json:"targetUid,omitempty"` // 目标用户ID(可能是基地,不一定有) - Damage float32 `protobuf:"fixed32,3,opt,name=damage,proto3" json:"damage,omitempty"` // 伤害量 + Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID + TargetUid int64 `protobuf:"varint,2,opt,name=targetUid,proto3" json:"targetUid,omitempty"` // 目标用户 + IsGeneral bool `protobuf:"varint,3,opt,name=isGeneral,proto3" json:"isGeneral,omitempty"` // targetUid是否名将 } -func (x *StatPvPDamage) Reset() { - *x = StatPvPDamage{} +func (x *StatPvPKill) Reset() { + *x = StatPvPKill{} if protoimpl.UnsafeEnabled { mi := &file_stat_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -40,13 +40,13 @@ func (x *StatPvPDamage) Reset() { } } -func (x *StatPvPDamage) String() string { +func (x *StatPvPKill) String() string { return protoimpl.X.MessageStringOf(x) } -func (*StatPvPDamage) ProtoMessage() {} +func (*StatPvPKill) ProtoMessage() {} -func (x *StatPvPDamage) ProtoReflect() protoreflect.Message { +func (x *StatPvPKill) ProtoReflect() protoreflect.Message { mi := &file_stat_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -58,46 +58,44 @@ func (x *StatPvPDamage) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use StatPvPDamage.ProtoReflect.Descriptor instead. -func (*StatPvPDamage) Descriptor() ([]byte, []int) { +// Deprecated: Use StatPvPKill.ProtoReflect.Descriptor instead. +func (*StatPvPKill) Descriptor() ([]byte, []int) { return file_stat_proto_rawDescGZIP(), []int{0} } -func (x *StatPvPDamage) GetUid() int64 { +func (x *StatPvPKill) GetUid() int64 { if x != nil { return x.Uid } return 0 } -func (x *StatPvPDamage) GetTargetUid() int64 { - if x != nil && x.TargetUid != nil { - return *x.TargetUid +func (x *StatPvPKill) GetTargetUid() int64 { + if x != nil { + return x.TargetUid } return 0 } -func (x *StatPvPDamage) GetDamage() float32 { +func (x *StatPvPKill) GetIsGeneral() bool { if x != nil { - return x.Damage + return x.IsGeneral } - return 0 + return false } -// 通知-PvP击杀单位 statistics.pvp.killunit -type StatPvPKillUnit struct { +// 通知-PvP一血 statistics.pvp.first +type StatPvPFirstBlood struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID - TargetUid *int64 `protobuf:"varint,2,opt,name=targetUid,proto3,oneof" json:"targetUid,omitempty"` // 目标用户 - Attacker string `protobuf:"bytes,3,opt,name=attacker,proto3" json:"attacker,omitempty"` // 造成击杀东西(building:兵营 U0001:xxx兵 S0001: 技能) - Victim string `protobuf:"bytes,4,opt,name=victim,proto3" json:"victim,omitempty"` // 被击杀的东西(U0001:xxx兵) + Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID + Type int32 `protobuf:"varint,2,opt,name=type,proto3" json:"type,omitempty"` // 1-拿到一血 2-被破一血 } -func (x *StatPvPKillUnit) Reset() { - *x = StatPvPKillUnit{} +func (x *StatPvPFirstBlood) Reset() { + *x = StatPvPFirstBlood{} if protoimpl.UnsafeEnabled { mi := &file_stat_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -105,13 +103,13 @@ func (x *StatPvPKillUnit) Reset() { } } -func (x *StatPvPKillUnit) String() string { +func (x *StatPvPFirstBlood) String() string { return protoimpl.X.MessageStringOf(x) } -func (*StatPvPKillUnit) ProtoMessage() {} +func (*StatPvPFirstBlood) ProtoMessage() {} -func (x *StatPvPKillUnit) ProtoReflect() protoreflect.Message { +func (x *StatPvPFirstBlood) ProtoReflect() protoreflect.Message { mi := &file_stat_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -123,52 +121,39 @@ func (x *StatPvPKillUnit) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use StatPvPKillUnit.ProtoReflect.Descriptor instead. -func (*StatPvPKillUnit) Descriptor() ([]byte, []int) { +// Deprecated: Use StatPvPFirstBlood.ProtoReflect.Descriptor instead. +func (*StatPvPFirstBlood) Descriptor() ([]byte, []int) { return file_stat_proto_rawDescGZIP(), []int{1} } -func (x *StatPvPKillUnit) GetUid() int64 { +func (x *StatPvPFirstBlood) GetUid() int64 { if x != nil { return x.Uid } return 0 } -func (x *StatPvPKillUnit) GetTargetUid() int64 { - if x != nil && x.TargetUid != nil { - return *x.TargetUid - } - return 0 -} - -func (x *StatPvPKillUnit) GetAttacker() string { - if x != nil { - return x.Attacker - } - return "" -} - -func (x *StatPvPKillUnit) GetVictim() string { +func (x *StatPvPFirstBlood) GetType() int32 { if x != nil { - return x.Victim + return x.Type } - return "" + return 0 } -// 通知-PvP杀兵营(人) statistics.pvp.kill -type StatPvPKill struct { +// 通知-PvP战报 statistics.pvp.report +type StatPvPReport struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID - TargetUid int64 `protobuf:"varint,2,opt,name=targetUid,proto3" json:"targetUid,omitempty"` // 目标用户 - IsGeneral bool `protobuf:"varint,3,opt,name=isGeneral,proto3" json:"isGeneral,omitempty"` // targetUid是否名将 + WinCamp int32 `protobuf:"varint,1,opt,name=winCamp,proto3" json:"winCamp,omitempty"` // 获胜阵营 1-蓝 2-红 + GeneralUid int64 `protobuf:"varint,2,opt,name=generalUid,proto3" json:"generalUid,omitempty"` // 名将UID + WinItems []*StatPvPReport_Item `protobuf:"bytes,3,rep,name=winItems,proto3" json:"winItems,omitempty"` // 获胜方数据 + LostItems []*StatPvPReport_Item `protobuf:"bytes,4,rep,name=lostItems,proto3" json:"lostItems,omitempty"` // 战败方数据 } -func (x *StatPvPKill) Reset() { - *x = StatPvPKill{} +func (x *StatPvPReport) Reset() { + *x = StatPvPReport{} if protoimpl.UnsafeEnabled { mi := &file_stat_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -176,13 +161,13 @@ func (x *StatPvPKill) Reset() { } } -func (x *StatPvPKill) String() string { +func (x *StatPvPReport) String() string { return protoimpl.X.MessageStringOf(x) } -func (*StatPvPKill) ProtoMessage() {} +func (*StatPvPReport) ProtoMessage() {} -func (x *StatPvPKill) ProtoReflect() protoreflect.Message { +func (x *StatPvPReport) ProtoReflect() protoreflect.Message { mi := &file_stat_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -194,44 +179,53 @@ func (x *StatPvPKill) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use StatPvPKill.ProtoReflect.Descriptor instead. -func (*StatPvPKill) Descriptor() ([]byte, []int) { +// Deprecated: Use StatPvPReport.ProtoReflect.Descriptor instead. +func (*StatPvPReport) Descriptor() ([]byte, []int) { return file_stat_proto_rawDescGZIP(), []int{2} } -func (x *StatPvPKill) GetUid() int64 { +func (x *StatPvPReport) GetWinCamp() int32 { if x != nil { - return x.Uid + return x.WinCamp } return 0 } -func (x *StatPvPKill) GetTargetUid() int64 { +func (x *StatPvPReport) GetGeneralUid() int64 { if x != nil { - return x.TargetUid + return x.GeneralUid } return 0 } -func (x *StatPvPKill) GetIsGeneral() bool { +func (x *StatPvPReport) GetWinItems() []*StatPvPReport_Item { if x != nil { - return x.IsGeneral + return x.WinItems } - return false + return nil } -// 通知-PvP一血 statistics.pvp.first -type StatPvPFirstBlood struct { +func (x *StatPvPReport) GetLostItems() []*StatPvPReport_Item { + if x != nil { + return x.LostItems + } + return nil +} + +type StatPvPReport_Item struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID - Type int32 `protobuf:"varint,2,opt,name=type,proto3" json:"type,omitempty"` // 1-拿到一血 2-被破一血 + Uid int64 `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户ID + Damage int64 `protobuf:"varint,2,opt,name=damage,proto3" json:"damage,omitempty"` // 伤害量 + DeDamage int64 `protobuf:"varint,3,opt,name=deDamage,proto3" json:"deDamage,omitempty"` // 承受伤害 + KillUnit int64 `protobuf:"varint,4,opt,name=killUnit,proto3" json:"killUnit,omitempty"` // 击杀单位数量 + DeKillUnit int64 `protobuf:"varint,5,opt,name=deKillUnit,proto3" json:"deKillUnit,omitempty"` // 被杀单位数量 } -func (x *StatPvPFirstBlood) Reset() { - *x = StatPvPFirstBlood{} +func (x *StatPvPReport_Item) Reset() { + *x = StatPvPReport_Item{} if protoimpl.UnsafeEnabled { mi := &file_stat_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -239,13 +233,13 @@ func (x *StatPvPFirstBlood) Reset() { } } -func (x *StatPvPFirstBlood) String() string { +func (x *StatPvPReport_Item) String() string { return protoimpl.X.MessageStringOf(x) } -func (*StatPvPFirstBlood) ProtoMessage() {} +func (*StatPvPReport_Item) ProtoMessage() {} -func (x *StatPvPFirstBlood) ProtoReflect() protoreflect.Message { +func (x *StatPvPReport_Item) ProtoReflect() protoreflect.Message { mi := &file_stat_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -257,136 +251,82 @@ func (x *StatPvPFirstBlood) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use StatPvPFirstBlood.ProtoReflect.Descriptor instead. -func (*StatPvPFirstBlood) Descriptor() ([]byte, []int) { - return file_stat_proto_rawDescGZIP(), []int{3} +// Deprecated: Use StatPvPReport_Item.ProtoReflect.Descriptor instead. +func (*StatPvPReport_Item) Descriptor() ([]byte, []int) { + return file_stat_proto_rawDescGZIP(), []int{2, 0} } -func (x *StatPvPFirstBlood) GetUid() int64 { +func (x *StatPvPReport_Item) GetUid() int64 { if x != nil { return x.Uid } return 0 } -func (x *StatPvPFirstBlood) GetType() int32 { +func (x *StatPvPReport_Item) GetDamage() int64 { if x != nil { - return x.Type + return x.Damage } return 0 } -// 通知-PvP战报 statistics.pvp.report -type StatPvPReport struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - WinCamp int32 `protobuf:"varint,1,opt,name=winCamp,proto3" json:"winCamp,omitempty"` // 获胜阵营 1-蓝 2-红 - GeneralUid int64 `protobuf:"varint,2,opt,name=generalUid,proto3" json:"generalUid,omitempty"` // 名将UID - WinUids []int64 `protobuf:"varint,3,rep,packed,name=winUids,proto3" json:"winUids,omitempty"` // 战胜方玩家列表 - LostUids []int64 `protobuf:"varint,4,rep,packed,name=lostUids,proto3" json:"lostUids,omitempty"` // 战败方玩家列表 -} - -func (x *StatPvPReport) Reset() { - *x = StatPvPReport{} - if protoimpl.UnsafeEnabled { - mi := &file_stat_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *StatPvPReport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*StatPvPReport) ProtoMessage() {} - -func (x *StatPvPReport) ProtoReflect() protoreflect.Message { - mi := &file_stat_proto_msgTypes[4] - 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 StatPvPReport.ProtoReflect.Descriptor instead. -func (*StatPvPReport) Descriptor() ([]byte, []int) { - return file_stat_proto_rawDescGZIP(), []int{4} -} - -func (x *StatPvPReport) GetWinCamp() int32 { +func (x *StatPvPReport_Item) GetDeDamage() int64 { if x != nil { - return x.WinCamp + return x.DeDamage } return 0 } -func (x *StatPvPReport) GetGeneralUid() int64 { +func (x *StatPvPReport_Item) GetKillUnit() int64 { if x != nil { - return x.GeneralUid + return x.KillUnit } return 0 } -func (x *StatPvPReport) GetWinUids() []int64 { - if x != nil { - return x.WinUids - } - return nil -} - -func (x *StatPvPReport) GetLostUids() []int64 { +func (x *StatPvPReport_Item) GetDeKillUnit() int64 { if x != nil { - return x.LostUids + return x.DeKillUnit } - return nil + return 0 } var File_stat_proto protoreflect.FileDescriptor var file_stat_proto_rawDesc = []byte{ 0x0a, 0x0a, 0x73, 0x74, 0x61, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x70, 0x62, - 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x22, 0x6a, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, - 0x50, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x09, 0x74, 0x61, 0x72, - 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, - 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x88, 0x01, 0x01, 0x12, 0x16, 0x0a, 0x06, - 0x64, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x06, 0x64, 0x61, - 0x6d, 0x61, 0x67, 0x65, 0x42, 0x0c, 0x0a, 0x0a, 0x5f, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, - 0x69, 0x64, 0x22, 0x88, 0x01, 0x0a, 0x0f, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, - 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, - 0x65, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, - 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x88, 0x01, 0x01, 0x12, 0x1a, 0x0a, 0x08, 0x61, - 0x74, 0x74, 0x61, 0x63, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, - 0x74, 0x74, 0x61, 0x63, 0x6b, 0x65, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x76, 0x69, 0x63, 0x74, 0x69, - 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x76, 0x69, 0x63, 0x74, 0x69, 0x6d, 0x42, - 0x0c, 0x0a, 0x0a, 0x5f, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x22, 0x5b, 0x0a, - 0x0b, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x4b, 0x69, 0x6c, 0x6c, 0x12, 0x10, 0x0a, 0x03, - 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x55, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, - 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x22, 0x39, 0x0a, 0x11, 0x53, 0x74, - 0x61, 0x74, 0x50, 0x76, 0x50, 0x46, 0x69, 0x72, 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x6f, 0x64, 0x12, - 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, - 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x7f, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, - 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, - 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, - 0x12, 0x1e, 0x0a, 0x0a, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, - 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x6e, 0x55, 0x69, 0x64, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, - 0x03, 0x52, 0x07, 0x77, 0x69, 0x6e, 0x55, 0x69, 0x64, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x6f, - 0x73, 0x74, 0x55, 0x69, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x6f, - 0x73, 0x74, 0x55, 0x69, 0x64, 0x73, 0x42, 0x09, 0x5a, 0x07, 0x2f, 0x70, 0x62, 0x53, 0x74, 0x61, - 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x22, 0x5b, 0x0a, 0x0b, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, + 0x50, 0x4b, 0x69, 0x6c, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x61, 0x72, 0x67, 0x65, + 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x61, 0x72, 0x67, + 0x65, 0x74, 0x55, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, 0x72, + 0x61, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x47, 0x65, 0x6e, 0x65, + 0x72, 0x61, 0x6c, 0x22, 0x39, 0x0a, 0x11, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x46, 0x69, + 0x72, 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x6f, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, + 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0xca, + 0x02, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, + 0x12, 0x18, 0x0a, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x05, 0x52, 0x07, 0x77, 0x69, 0x6e, 0x43, 0x61, 0x6d, 0x70, 0x12, 0x1e, 0x0a, 0x0a, 0x67, 0x65, + 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x6c, 0x55, 0x69, 0x64, 0x12, 0x38, 0x0a, 0x08, 0x77, 0x69, + 0x6e, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x70, + 0x62, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, + 0x65, 0x70, 0x6f, 0x72, 0x74, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x08, 0x77, 0x69, 0x6e, 0x49, + 0x74, 0x65, 0x6d, 0x73, 0x12, 0x3a, 0x0a, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, + 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x70, 0x62, 0x43, 0x6c, 0x69, 0x65, + 0x6e, 0x74, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x50, 0x76, 0x50, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, + 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x09, 0x6c, 0x6f, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x73, + 0x1a, 0x88, 0x01, 0x0a, 0x04, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x64, + 0x61, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x64, 0x61, 0x6d, + 0x61, 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x64, 0x65, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x64, 0x65, 0x44, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x6b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x6b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x64, + 0x65, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x64, 0x65, 0x4b, 0x69, 0x6c, 0x6c, 0x55, 0x6e, 0x69, 0x74, 0x42, 0x09, 0x5a, 0x07, 0x2f, + 0x70, 0x62, 0x53, 0x74, 0x61, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -401,20 +341,21 @@ func file_stat_proto_rawDescGZIP() []byte { return file_stat_proto_rawDescData } -var file_stat_proto_msgTypes = make([]protoimpl.MessageInfo, 5) +var file_stat_proto_msgTypes = make([]protoimpl.MessageInfo, 4) var file_stat_proto_goTypes = []interface{}{ - (*StatPvPDamage)(nil), // 0: pbClient.StatPvPDamage - (*StatPvPKillUnit)(nil), // 1: pbClient.StatPvPKillUnit - (*StatPvPKill)(nil), // 2: pbClient.StatPvPKill - (*StatPvPFirstBlood)(nil), // 3: pbClient.StatPvPFirstBlood - (*StatPvPReport)(nil), // 4: pbClient.StatPvPReport + (*StatPvPKill)(nil), // 0: pbClient.StatPvPKill + (*StatPvPFirstBlood)(nil), // 1: pbClient.StatPvPFirstBlood + (*StatPvPReport)(nil), // 2: pbClient.StatPvPReport + (*StatPvPReport_Item)(nil), // 3: pbClient.StatPvPReport.Item } var file_stat_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 + 3, // 0: pbClient.StatPvPReport.winItems:type_name -> pbClient.StatPvPReport.Item + 3, // 1: pbClient.StatPvPReport.lostItems:type_name -> pbClient.StatPvPReport.Item + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name } func init() { file_stat_proto_init() } @@ -424,7 +365,7 @@ func file_stat_proto_init() { } if !protoimpl.UnsafeEnabled { file_stat_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPDamage); i { + switch v := v.(*StatPvPKill); i { case 0: return &v.state case 1: @@ -436,7 +377,7 @@ func file_stat_proto_init() { } } file_stat_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPKillUnit); i { + switch v := v.(*StatPvPFirstBlood); i { case 0: return &v.state case 1: @@ -448,7 +389,7 @@ func file_stat_proto_init() { } } file_stat_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPKill); i { + switch v := v.(*StatPvPReport); i { case 0: return &v.state case 1: @@ -460,19 +401,7 @@ func file_stat_proto_init() { } } file_stat_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPFirstBlood); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_stat_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StatPvPReport); i { + switch v := v.(*StatPvPReport_Item); i { case 0: return &v.state case 1: @@ -484,15 +413,13 @@ func file_stat_proto_init() { } } } - file_stat_proto_msgTypes[0].OneofWrappers = []interface{}{} - file_stat_proto_msgTypes[1].OneofWrappers = []interface{}{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_stat_proto_rawDesc, NumEnums: 0, - NumMessages: 5, + NumMessages: 4, NumExtensions: 0, NumServices: 0, }, diff --git a/game/pb/stat/stat.proto b/game/pb/stat/stat.proto index 6229ba7..2f3eab6 100644 --- a/game/pb/stat/stat.proto +++ b/game/pb/stat/stat.proto @@ -4,21 +4,6 @@ package pbClient; option go_package = "/pbStat"; -// 通知-PvP伤害 statistics.pvp.damage -message StatPvPDamage { - int64 uid = 1; // 造成伤害的用户ID - optional int64 targetUid = 2; // 目标用户ID(可能是基地,不一定有) - float damage = 3; // 伤害量 -} - -// 通知-PvP击杀单位 statistics.pvp.killunit -message StatPvPKillUnit { - int64 uid = 1; // 用户ID - optional int64 targetUid = 2; // 目标用户 - string attacker = 3; // 造成击杀东西(building:兵营 U0001:xxx兵 S0001: 技能) - string victim = 4; // 被击杀的东西(U0001:xxx兵) -} - // 通知-PvP杀兵营(人) statistics.pvp.kill message StatPvPKill { int64 uid = 1; // 用户ID @@ -34,8 +19,15 @@ message StatPvPFirstBlood { // 通知-PvP战报 statistics.pvp.report message StatPvPReport { + message Item { + int64 uid = 1; // 用户ID + int64 damage = 2; // 伤害量 + int64 deDamage = 3; // 承受伤害 + int64 killUnit = 4; // 击杀单位数量 + int64 deKillUnit = 5; // 被杀单位数量 + } int32 winCamp = 1; // 获胜阵营 1-蓝 2-红 int64 generalUid = 2; // 名将UID - repeated int64 winUids = 3; // 战胜方玩家列表 - repeated int64 lostUids = 4; // 战败方玩家列表 + repeated Item winItems = 3; // 获胜方数据 + repeated Item lostItems = 4; // 战败方数据 } \ No newline at end of file