【修行】名字颜色

dev_chengFeng
ZhangBiao 2021-05-17 15:48:41 +08:00
parent ffd695f3b1
commit d53415d80b
3 changed files with 12 additions and 10 deletions

View File

@ -327,7 +327,7 @@ function this.RefreshEnemyData()
local btnItem = Util.GetGameObject(node, "challenge/item"):GetComponent("Image")
local btnItemNum = Util.GetGameObject(node, "challenge/item/num"):GetComponent("Text")
lv_name:GetComponent("Text").text = JingJiShouWeiToEn(EnemyList[i].personInfo.name)
lv_name:GetComponent("Text").text = PracticeManager.SetNameColor(JingJiShouWeiToEn(EnemyList[i].personInfo.name),EnemyList[i].personInfo.practiceLevel)
integral:GetComponent("Text").text = Language[11693].. EnemyList[i].personInfo.score
power:GetComponent("Text").text = Language[12179]..EnemyList[i].personInfo.totalForce
btnText.gameObject:SetActive(leftTimes > 0)

View File

@ -125,7 +125,7 @@ function this.GetFriendInfoRequest(type, msg)
for i = 1, #msg.Friends do
local friendData = this.CreateFriendData()
friendData.id = msg.Friends[i].id
friendData.name = msg.Friends[i].name
friendData.name = PracticeManager.SetNameColor(msg.Friends[i].name,msg.Friends[i].practiceLevel)--msg.Friends[i].name
friendData.lv = msg.Friends[i].lv
friendData.offLineTime = msg.Friends[i].offLineTime
friendData.haveReward = msg.Friends[i].haveReward
@ -144,7 +144,7 @@ function this.GetFriendInfoRequest(type, msg)
for i = 1, #msg.Friends do
local friendData = this.CreateFriendData()
friendData.id = msg.Friends[i].id
friendData.name = msg.Friends[i].name
friendData.name = PracticeManager.SetNameColor(msg.Friends[i].name,msg.Friends[i].practiceLevel)--msg.Friends[i].name
friendData.lv = msg.Friends[i].lv
friendData.offLineTime = msg.Friends[i].offLineTime
friendData.haveReward = msg.Friends[i].haveReward
@ -163,7 +163,7 @@ function this.GetFriendInfoRequest(type, msg)
for i = 1, #msg.Friends do
local friendData = this.CreateFriendData()
friendData.id = msg.Friends[i].id
friendData.name = msg.Friends[i].name
friendData.name = PracticeManager.SetNameColor(msg.Friends[i].name,msg.Friends[i].practiceLevel)--msg.Friends[i].name
friendData.lv = msg.Friends[i].lv
friendData.offLineTime = msg.Friends[i].offLineTime
friendData.haveReward = msg.Friends[i].haveReward
@ -182,7 +182,7 @@ function this.GetFriendInfoRequest(type, msg)
for i = 1, #msg.Friends do
local friendData = this.CreateFriendData()
friendData.id = msg.Friends[i].id
friendData.name = msg.Friends[i].name
friendData.name = PracticeManager.SetNameColor(msg.Friends[i].name,msg.Friends[i].practiceLevel)--msg.Friends[i].name
friendData.lv = msg.Friends[i].lv
friendData.offLineTime = msg.Friends[i].offLineTime
friendData.haveReward = msg.Friends[i].haveReward
@ -319,6 +319,8 @@ function this.FriendSearchRequest(name)
NetManager.RequestFriendSearch(name, function(msg)
this.friendSearchData = {}
this.friendSearchData[msg.Friends.id] = msg.Friends
this.friendSearchData[msg.Friends.id].name = PracticeManager.SetNameColor(msg.Friends.name,msg.Friends.practiceLevel)
--.name = PracticeManager.SetNameColor(msg.Friends[i].name,msg.Friends[i].practiceLevel)--msg.Friends[i].name
Game.GlobalEvent:DispatchEvent(GameEvent.Friend.OnFriendSearch, false,false) --this.friendSearchData)
end)
end

View File

@ -1367,11 +1367,11 @@ function this.RequestBaseArenaData(func)
local msg = ArenaInfoProto_pb.GetArenaInfoResponse()
msg:ParseFromString(data)
ArenaManager.ReceiveBaseArenaData(msg)
for i = 1, #msg.arenaInfo.arenaEnemys do
local v= msg.arenaInfo.arenaEnemys[i]
LogPink("name:"..tostring(v.personInfo.name).." 等级:"..tostring(v.personInfo.practiceLevel))
v.personInfo.name = PracticeManager.SetNameColor(v.personInfo.name,v.personInfo.practiceLevel)
end
-- for i = 1, #msg.arenaInfo.arenaEnemys do
-- local v= msg.arenaInfo.arenaEnemys[i]
-- LogPink("name:"..tostring(v.personInfo.name).." 等级:"..tostring(v.personInfo.practiceLevel))
-- v.personInfo.name = PracticeManager.SetNameColor(v.personInfo.name,v.personInfo.practiceLevel)
-- end
if func then
func(msg)
end