2025.10.20 uiteam 主角名称,info大小
This commit is contained in:
parent
8a3549fbe1
commit
46f2e809a4
@ -270,7 +270,7 @@ RectTransform:
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 1}
|
||||
m_AnchorMax: {x: 0.5, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 31.49, y: 0}
|
||||
m_SizeDelta: {x: 170, y: 42}
|
||||
m_Pivot: {x: 0.5, y: 0}
|
||||
--- !u!222 &4958793944002788318
|
||||
|
||||
@ -32,7 +32,6 @@ RectTransform:
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 2781021814095716438}
|
||||
- {fileID: 4977997708738661593}
|
||||
- {fileID: 3905501289418104124}
|
||||
m_Father: {fileID: 5418892521828950389}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
@ -1058,6 +1057,7 @@ RectTransform:
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 2073065677731170282}
|
||||
- {fileID: 4977997708738661593}
|
||||
m_Father: {fileID: 5418892521828950389}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
@ -3710,13 +3710,13 @@ RectTransform:
|
||||
- {fileID: 6803298590140844099}
|
||||
- {fileID: 7090909620631253042}
|
||||
- {fileID: 7538217807299259758}
|
||||
m_Father: {fileID: 4616978343254337758}
|
||||
m_Father: {fileID: 5248686921407379108}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0}
|
||||
m_AnchorMax: {x: 0.5, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 556}
|
||||
m_AnchorMin: {x: 1, y: 1}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: -20, y: -20}
|
||||
m_SizeDelta: {x: 396, y: 64}
|
||||
m_Pivot: {x: 0.5, y: 0}
|
||||
m_Pivot: {x: 1, y: 1}
|
||||
--- !u!222 &3828605310306796609
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@ -502,9 +502,9 @@ function UITeamView:GetBattleActorGo(idx)
|
||||
elseif idx == 3 then
|
||||
return self.cPos_Right3
|
||||
elseif idx == 4 then
|
||||
return self.cPos_Left3
|
||||
elseif idx == 5 then
|
||||
return self.cPos_Left1
|
||||
elseif idx == 5 then
|
||||
return self.cPos_Left3
|
||||
elseif idx == 6 then
|
||||
return self.cPos_Middle2
|
||||
end
|
||||
@ -566,8 +566,18 @@ function UITeamView:SetBattleHeroData(idx, uid, node)
|
||||
--图片对齐
|
||||
if idx==1 then imgpos.localPosition=Vector3(-30,0,0) end
|
||||
|
||||
node.heroLua.bg_info.Scale=Vector3(1,1,1)
|
||||
node.heroLua.bg_info.text_name.text.text = I18N.T(heroData.cfgData.Name)
|
||||
--info缩放
|
||||
local parentScale = node.transform.localScale
|
||||
LogWarning("parentScale "..parentScale.x..","..parentScale.y..","..parentScale.z)
|
||||
local inverseScale = Vector3(1 / parentScale.x, 1 / parentScale.y, 1 / parentScale.z)
|
||||
node.heroLua.bg_info.transform.localScale = inverseScale
|
||||
|
||||
if heroData.mainRole then
|
||||
node.heroLua.bg_info.text_name.text.text = ManagerContainer.DataMgr.UserData:GetUserNickname()
|
||||
else
|
||||
node.heroLua.bg_info.text_name.text.text = I18N.T(heroData.cfgData.Name)
|
||||
end
|
||||
|
||||
CommonUtil.LoadIcon(self, heroData.cfgData.JobIcon2, function(sprite)
|
||||
node.heroLua.bg_info.img_job.image.sprite = sprite
|
||||
end)
|
||||
|
||||
@ -10,10 +10,6 @@
|
||||
---@field public gameObject UnityEngine.GameObject
|
||||
---@field public button UnityEngine.UI.Button
|
||||
|
||||
---@class UITeam__Generate_fighterPowerText
|
||||
---@field public gameObject UnityEngine.GameObject
|
||||
---@field public text TMPro.TextMeshProUGUI
|
||||
|
||||
---@class UITeam__Generate_hero6
|
||||
---@field public gameObject UnityEngine.GameObject
|
||||
---@field public rectTransform UnityEngine.RectTransform
|
||||
@ -38,6 +34,10 @@
|
||||
---@field public gameObject UnityEngine.GameObject
|
||||
---@field public rectTransform UnityEngine.RectTransform
|
||||
|
||||
---@class UITeam__Generate_fighterPowerText
|
||||
---@field public gameObject UnityEngine.GameObject
|
||||
---@field public text TMPro.TextMeshProUGUI
|
||||
|
||||
---@class UITeam__Generate
|
||||
---@field private gameObject UnityEngine.GameObject
|
||||
---@field private transform UnityEngine.Transform
|
||||
@ -50,6 +50,7 @@
|
||||
---@field private cPos_Left1 UnityEngine.GameObject
|
||||
---@field private cPos_Middle1 UnityEngine.GameObject
|
||||
---@field private cPos_Right1 UnityEngine.GameObject
|
||||
---@field private fighterPowerText UITeam__Generate_fighterPowerText
|
||||
---@field private roleList UnityEngine.GameObject
|
||||
---@field private roleListAnim UnityEngine.GameObject
|
||||
---@field private hero1 UITeam__Generate_hero1
|
||||
@ -58,7 +59,6 @@
|
||||
---@field private hero4 UITeam__Generate_hero4
|
||||
---@field private hero5 UITeam__Generate_hero5
|
||||
---@field private hero6 UITeam__Generate_hero6
|
||||
---@field private fighterPowerText UITeam__Generate_fighterPowerText
|
||||
---@field private btnBack UITeam__Generate_btnBack
|
||||
---@field private btnEditTeam UITeam__Generate_btnEditTeam
|
||||
---@field private btnSaveTeam UITeam__Generate_btnSaveTeam
|
||||
@ -216,6 +216,20 @@ end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__10(Root, data)
|
||||
--[[
|
||||
TopView/FightPowerInfo/Val
|
||||
--]]
|
||||
local tmp = Root:Find("TopView/FightPowerInfo/Val").gameObject
|
||||
if tolua.getpeer(tmp) == nil then
|
||||
tolua.setpeer(tmp, {})
|
||||
end
|
||||
self.fighterPowerText = tmp
|
||||
|
||||
tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__11(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList
|
||||
--]]
|
||||
@ -227,7 +241,7 @@ function UITeamView:InitGenerate__10(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__11(Root, data)
|
||||
function UITeamView:InitGenerate__12(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim
|
||||
--]]
|
||||
@ -239,7 +253,7 @@ function UITeamView:InitGenerate__11(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__12(Root, data)
|
||||
function UITeamView:InitGenerate__13(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role1
|
||||
--]]
|
||||
@ -253,7 +267,7 @@ function UITeamView:InitGenerate__12(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__13(Root, data)
|
||||
function UITeamView:InitGenerate__14(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role2
|
||||
--]]
|
||||
@ -267,7 +281,7 @@ function UITeamView:InitGenerate__13(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__14(Root, data)
|
||||
function UITeamView:InitGenerate__15(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role3
|
||||
--]]
|
||||
@ -281,7 +295,7 @@ function UITeamView:InitGenerate__14(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__15(Root, data)
|
||||
function UITeamView:InitGenerate__16(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role4
|
||||
--]]
|
||||
@ -295,7 +309,7 @@ function UITeamView:InitGenerate__15(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__16(Root, data)
|
||||
function UITeamView:InitGenerate__17(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role5
|
||||
--]]
|
||||
@ -309,7 +323,7 @@ function UITeamView:InitGenerate__16(Root, data)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__17(Root, data)
|
||||
function UITeamView:InitGenerate__18(Root, data)
|
||||
--[[
|
||||
BottomView/RoleList/RoleListAnim/Role6
|
||||
--]]
|
||||
@ -322,20 +336,6 @@ function UITeamView:InitGenerate__17(Root, data)
|
||||
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__18(Root, data)
|
||||
--[[
|
||||
BottomView/FightPowerInfo/Val
|
||||
--]]
|
||||
local tmp = Root:Find("BottomView/FightPowerInfo/Val").gameObject
|
||||
if tolua.getpeer(tmp) == nil then
|
||||
tolua.setpeer(tmp, {})
|
||||
end
|
||||
self.fighterPowerText = tmp
|
||||
|
||||
tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
|
||||
end
|
||||
|
||||
---@private
|
||||
function UITeamView:InitGenerate__19(Root, data)
|
||||
--[[
|
||||
@ -416,6 +416,10 @@ function UITeamView:GenerateDestroy()
|
||||
tolua.setpeer(self.cPos_Right1, nil)
|
||||
end
|
||||
self.cPos_Right1 = nil
|
||||
if tolua.getpeer(self.fighterPowerText) ~= nil then
|
||||
tolua.setpeer(self.fighterPowerText, nil)
|
||||
end
|
||||
self.fighterPowerText = nil
|
||||
if tolua.getpeer(self.roleList) ~= nil then
|
||||
tolua.setpeer(self.roleList, nil)
|
||||
end
|
||||
@ -448,10 +452,6 @@ function UITeamView:GenerateDestroy()
|
||||
tolua.setpeer(self.hero6, nil)
|
||||
end
|
||||
self.hero6 = nil
|
||||
if tolua.getpeer(self.fighterPowerText) ~= nil then
|
||||
tolua.setpeer(self.fighterPowerText, nil)
|
||||
end
|
||||
self.fighterPowerText = nil
|
||||
if tolua.getpeer(self.btnBack) ~= nil then
|
||||
tolua.setpeer(self.btnBack, nil)
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user