From 78ec831ca18345144b72b888b2950d4bbb638329 Mon Sep 17 00:00:00 2001 From: zhangqiang <657634622@qq.com> Date: Fri, 30 Jul 2021 11:59:39 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E3=80=90=E8=B7=A8=E6=9C=8D=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E3=80=91=E4=BF=AE=E6=94=B9=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../~Lua/Message/PlayerInfoProto_pb.lua | 13 ++++++++++++- .../Guild/CarDelay/GuildCarDelayLootPopup.lua | 2 +- .../~Lua/Modules/Guild/GuildMemberInfoPopup.lua | 2 +- .../~Lua/Modules/Net/NetManager.lua | 3 ++- .../~Lua/Modules/Popup/PlayerInfoPopup.lua | 2 +- .../~Lua/Modules/Ranking/RankingSingleListPanel.lua | 2 +- 6 files changed, 18 insertions(+), 6 deletions(-) diff --git a/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua b/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua index 472b9432b1..aca4e48ea1 100644 --- a/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua +++ b/Assets/ManagedResources/~Lua/Message/PlayerInfoProto_pb.lua @@ -400,6 +400,7 @@ VIEWHEROINFOREQUEST = protobuf.Descriptor(); VIEWHEROINFOREQUEST_TARGETUID_FIELD = protobuf.FieldDescriptor(); VIEWHEROINFOREQUEST_HEROID_FIELD = protobuf.FieldDescriptor(); VIEWHEROINFOREQUEST_SERVERID_FIELD = protobuf.FieldDescriptor(); +VIEWHEROINFOREQUEST_TEAMID_FIELD = protobuf.FieldDescriptor(); VIEWHEROINFORESPONSE = protobuf.Descriptor(); VIEWHEROINFORESPONSE_HERO_FIELD = protobuf.FieldDescriptor(); VIEWHEROINFORESPONSE_EQUIP_FIELD = protobuf.FieldDescriptor(); @@ -4218,11 +4219,21 @@ VIEWHEROINFOREQUEST_SERVERID_FIELD.default_value = 0 VIEWHEROINFOREQUEST_SERVERID_FIELD.type = 5 VIEWHEROINFOREQUEST_SERVERID_FIELD.cpp_type = 1 +VIEWHEROINFOREQUEST_TEAMID_FIELD.name = "teamId" +VIEWHEROINFOREQUEST_TEAMID_FIELD.full_name = ".rpc.protocols.ViewHeroInfoRequest.teamId" +VIEWHEROINFOREQUEST_TEAMID_FIELD.number = 4 +VIEWHEROINFOREQUEST_TEAMID_FIELD.index = 3 +VIEWHEROINFOREQUEST_TEAMID_FIELD.label = 1 +VIEWHEROINFOREQUEST_TEAMID_FIELD.has_default_value = false +VIEWHEROINFOREQUEST_TEAMID_FIELD.default_value = 0 +VIEWHEROINFOREQUEST_TEAMID_FIELD.type = 5 +VIEWHEROINFOREQUEST_TEAMID_FIELD.cpp_type = 1 + VIEWHEROINFOREQUEST.name = "ViewHeroInfoRequest" VIEWHEROINFOREQUEST.full_name = ".rpc.protocols.ViewHeroInfoRequest" VIEWHEROINFOREQUEST.nested_types = {} VIEWHEROINFOREQUEST.enum_types = {} -VIEWHEROINFOREQUEST.fields = {VIEWHEROINFOREQUEST_TARGETUID_FIELD, VIEWHEROINFOREQUEST_HEROID_FIELD, VIEWHEROINFOREQUEST_SERVERID_FIELD} +VIEWHEROINFOREQUEST.fields = {VIEWHEROINFOREQUEST_TARGETUID_FIELD, VIEWHEROINFOREQUEST_HEROID_FIELD, VIEWHEROINFOREQUEST_SERVERID_FIELD, VIEWHEROINFOREQUEST_TEAMID_FIELD} VIEWHEROINFOREQUEST.is_extendable = false VIEWHEROINFOREQUEST.extensions = {} VIEWHEROINFORESPONSE_HERO_FIELD.name = "hero" diff --git a/Assets/ManagedResources/~Lua/Modules/Guild/CarDelay/GuildCarDelayLootPopup.lua b/Assets/ManagedResources/~Lua/Modules/Guild/CarDelay/GuildCarDelayLootPopup.lua index 32cbf19f95..39c0cdc0c0 100644 --- a/Assets/ManagedResources/~Lua/Modules/Guild/CarDelay/GuildCarDelayLootPopup.lua +++ b/Assets/ManagedResources/~Lua/Modules/Guild/CarDelay/GuildCarDelayLootPopup.lua @@ -136,7 +136,7 @@ function this.SingleInfoDataShow(go,data) Util.GetGameObject(heroGo, "lvbg/levelText"):GetComponent("Text").text=data.teamInfo[i].level local heroData = {} Util.AddOnceClick(Util.GetGameObject(Util.GetGameObject(curHeroGoList[data.teamInfo[i].position], "frame"), "frame"), function() - NetManager.ViewHeroInfoRequest(data.uid,data.teamInfo[i].heroid,nil,function(msg) + NetManager.ViewHeroInfoRequest(data.uid,data.teamInfo[i].heroid,nil,FormationTypeDef.FORMATION_NORMAL,function(msg) heroData= GoodFriendManager.GetHeroDatas(msg.hero,msg.force,msg.SpecialEffects) GoodFriendManager.InitEquipData(msg.equip,heroData) UIManager.OpenPanel(UIName.RoleInfoPopup, heroData,true) diff --git a/Assets/ManagedResources/~Lua/Modules/Guild/GuildMemberInfoPopup.lua b/Assets/ManagedResources/~Lua/Modules/Guild/GuildMemberInfoPopup.lua index 586896774c..9b295a4542 100644 --- a/Assets/ManagedResources/~Lua/Modules/Guild/GuildMemberInfoPopup.lua +++ b/Assets/ManagedResources/~Lua/Modules/Guild/GuildMemberInfoPopup.lua @@ -348,7 +348,7 @@ function this.FormationAdapter(teamInfo) local frameBtn = Util.GetGameObject(this.Demons[hero.position], "frame") local heroData = {} Util.AddOnceClick(frameBtn, function() - NetManager.ViewHeroInfoRequest(this._MemId,hero.heroid,nil,function(msg) + NetManager.ViewHeroInfoRequest(this._MemId,hero.heroid,nil,FormationTypeDef.FORMATION_NORMAL,function(msg) if not hero.heroid then return end diff --git a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua index 1d10871625..606f376b2e 100644 --- a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua @@ -3334,11 +3334,12 @@ end --好友上阵英雄预览信息 -function this.ViewHeroInfoRequest(targetUid,heroId,serverName,func) +function this.ViewHeroInfoRequest(targetUid,heroId,serverName,formationId,func) local data = PlayerInfoProto_pb.ViewHeroInfoRequest() data.targetUid = targetUid data.heroId = heroId data.serverId = serverName and 1 or 0 + data.teamId = formationId and formationId or FormationTypeDef.FORMATION_NORMAL local msg = data:SerializeToString() Network:SendMessageWithCallBack(MessageTypeProto_pb.VIEW_HERO_INFO_REQUEST, MessageTypeProto_pb.VIEW_HERO_INFO_RESPONSE, msg, function(buffer) local data = buffer:DataByte() diff --git a/Assets/ManagedResources/~Lua/Modules/Popup/PlayerInfoPopup.lua b/Assets/ManagedResources/~Lua/Modules/Popup/PlayerInfoPopup.lua index 345ac7ed7c..25f4890c82 100644 --- a/Assets/ManagedResources/~Lua/Modules/Popup/PlayerInfoPopup.lua +++ b/Assets/ManagedResources/~Lua/Modules/Popup/PlayerInfoPopup.lua @@ -340,7 +340,7 @@ function this.FormationAdapter(teamInfo) end) else Util.AddOnceClick(frameBtn, function() - NetManager.ViewHeroInfoRequest(this._PlayerId,hero.heroid,netserverName,function(msg) + NetManager.ViewHeroInfoRequest(this._PlayerId,hero.heroid,netserverName,this._Config.formationType,function(msg) if not hero.heroid then return end diff --git a/Assets/ManagedResources/~Lua/Modules/Ranking/RankingSingleListPanel.lua b/Assets/ManagedResources/~Lua/Modules/Ranking/RankingSingleListPanel.lua index c2b0a11251..442d435b9e 100644 --- a/Assets/ManagedResources/~Lua/Modules/Ranking/RankingSingleListPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/Ranking/RankingSingleListPanel.lua @@ -220,7 +220,7 @@ function this.SetRankingInfo(isTop, isAnim) return end local dt,db=RankingManager.CutDate(rankingData) - if sData.rankType == RANK_TYPE.CELEBRATION_GUILD or sData.rankType == RANK_TYPE.GUILD_FORCE_RANK then + if sData.rankType == RANK_TYPE.CELEBRATION_GUILD or sData.rankType == RANK_TYPE.GUILD_FORCE_RANK or sData.rankType == RANK_TYPE.JUMPSERVER_GUILD_FORCE_RANK then dt[1].userName = dt[1].guildName end local dtUserName = dt[1].userName From aece2194b54e1ac4f43d507c76ff3ec9accb17e6 Mon Sep 17 00:00:00 2001 From: gaoxin Date: Fri, 30 Jul 2021 13:47:03 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E3=80=90=E8=B7=A8=E6=9C=8D=E8=81=8A?= =?UTF-8?q?=E5=A4=A9=E3=80=91=E6=B7=BB=E5=8A=A0=E6=9C=8D=E5=8A=A1=E5=99=A8?= =?UTF-8?q?=E5=90=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Assets/ManagedResources/~Lua/Modules/Chat/ChatPanel.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Assets/ManagedResources/~Lua/Modules/Chat/ChatPanel.lua b/Assets/ManagedResources/~Lua/Modules/Chat/ChatPanel.lua index 052bcc0545..595c98f4be 100644 --- a/Assets/ManagedResources/~Lua/Modules/Chat/ChatPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/Chat/ChatPanel.lua @@ -538,12 +538,19 @@ function this.ChatItemAdapter(node, data, isShowTime) if data.senderId == PlayerManager.uid then lv.text = PlayerManager.level name.text = PracticeManager.SetNameColor(PlayerManager.nickName,PracticeManager.PracticeLevel) + if data.serverName and data.serverName ~= "" then + name.text = name.text.." "..data.serverName + end head.sprite = GetPlayerHeadSprite(this.spLoader, PlayerManager.head) headKuang.sprite = GetPlayerHeadFrameSprite(this.spLoader, HeadManager.GetCurFrameId()) title=PlayerManager.GetPlayerDesignation() else lv.text = data.senderlevel - name.text = data.senderName + if data.serverName and data.serverName ~= "" then + name.text = data.serverName .." "..data.senderName + else + name.text = data.senderName + end head.sprite = GetPlayerHeadSprite(this.spLoader, data.head) headKuang.sprite = GetPlayerHeadFrameSprite(this.spLoader, data.frame) title=data.userTitle