require("Util") require("LuaUtil") GangXiulian = {} local UIImgText function GangXiulian.Awake( ... ) UIImgText = _UIImgText:GetComponent('UIImgText') UIImgText.text = 0 end function GangXiulian.Update() local combineValue = 0 for k,v in pairs(CS.GameManager.gameManager.PlayerDataPool.GuildInfo.m_AttrInfos) do if v.attrLevel > 0 then print(v.attrTab:GetCombatValuebyIndex(v.attrLevel - 1)) combineValue = combineValue + v.attrTab:GetCombatValuebyIndex(v.attrLevel - 1) if combineValue ~= 0 then UIImgText.text = combineValue end end end end