This commit is contained in:
Fang 2023-09-13 15:31:13 +08:00
parent 2d1349eae0
commit b74a41ed00
4 changed files with 12 additions and 9 deletions

View File

@ -7,6 +7,7 @@ function RunesInfoComp:init()
local uiMap = self:getUIMap() local uiMap = self:getUIMap()
self.btnHelp = uiMap["runes_info.btn_help"] self.btnHelp = uiMap["runes_info.btn_help"]
self.imgProg = uiMap["runes_info.prog.img_prog"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_SLIDER) self.imgProg = uiMap["runes_info.prog.img_prog"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_SLIDER)
self.txProg = uiMap["runes_info.prog.tx_prog"]
self.txLevel = uiMap["runes_info.level.tx_level"] self.txLevel = uiMap["runes_info.level.tx_level"]
self.btnSuit = uiMap["runes_info.btn_suit"] self.btnSuit = uiMap["runes_info.btn_suit"]
self.txSuit = uiMap["runes_info.btn_suit.tx_suit"] self.txSuit = uiMap["runes_info.btn_suit.tx_suit"]
@ -86,10 +87,10 @@ function RunesInfoComp:refresh()
local maxExp = DataManager.RunesData:getNextLevelTotalExp() local maxExp = DataManager.RunesData:getNextLevelTotalExp()
if maxExp then if maxExp then
self.imgProg.value = curExp / maxExp self.imgProg.value = curExp / maxExp
-- self.txProg:setText(curExp .. "/" .. maxExp) self.txProg:setText(curExp .. "/" .. maxExp)
else else
self.imgProg.value = 1 self.imgProg.value = 1
-- self.txProg:setText(I18N:getGlobalText(I18N.GlobalConst.STR_MAX)) self.txProg:setText(I18N:getGlobalText(I18N.GlobalConst.STR_MAX))
end end
if DataManager.RunesData:canAutoMake() then if DataManager.RunesData:canAutoMake() then

View File

@ -567,9 +567,11 @@ function HeroEntity:getTotalBaseAtk()
result = result + equipEntity:getBaseAttack() result = result + equipEntity:getBaseAttack()
end end
end end
-- Logger.logHighlight(logStr) -- logStr = logStr .. "\nSKIN" .. DataManager.SkinData:getBaseAttack(self)
result = result + DataManager.SkinData:getBaseAttack(self) result = result + DataManager.SkinData:getBaseAttack(self)
-- logStr = logStr .. "\nRUNES" .. self:getRunes():getAttrValue(GConst.MATCH_ATTACK_NAME, true)
result = result + self:getRunes():getAttrValue(GConst.MATCH_ATTACK_NAME, true) result = result + self:getRunes():getAttrValue(GConst.MATCH_ATTACK_NAME, true)
-- Logger.logHighlight(logStr)
return result return result
end end

View File

@ -200,11 +200,11 @@ function RunesData:getSuitName(index)
elseif index == 2 then elseif index == 2 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_11) return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_11)
elseif index == 3 then elseif index == 3 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_12)
elseif index == 4 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_13)
elseif index == 5 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_14) return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_14)
elseif index == 4 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_12)
elseif index == 5 then
return I18N:getGlobalText(I18N.GlobalConst.RUNES_DESC_13)
end end
return nil return nil

View File

@ -125,7 +125,7 @@ end
-- 获取已有的套装id map -- 获取已有的套装id map
function RunesEntity:getSuitIds() function RunesEntity:getSuitIds()
local typeCount = {} local typeCount = {}
for i = 1, GConst.RunesConst.MAX_SUITS_COUNT do for i = 1, GConst.RunesConst.MAX_ATTR_GRID_COUNT do
local t = self:getGridSuit(i) local t = self:getGridSuit(i)
if t then if t then
local temp = table.find(typeCount, function(value) return value.id == t end) local temp = table.find(typeCount, function(value) return value.id == t end)
@ -195,7 +195,7 @@ function RunesEntity:getAttrValue(attrType, isBase)
return result return result
elseif not isBase and attrType == GConst.MATCH_ATTACK_NAME[self:getHeroEntity():getMatchType()] then elseif not isBase and attrType == GConst.MATCH_ATTACK_NAME[self:getHeroEntity():getMatchType()] then
result = self:getAttrValue(GConst.MATCH_ATTACK_NAME[self:getHeroEntity():getMatchType()], true) result = self:getAttrValue(GConst.MATCH_ATTACK_NAME[self:getHeroEntity():getMatchType()], true)
result = result + self:getHeroEntity():getTotalBaseAtk() * self:getAttrValue(GConst.MATCH_ATTACK_ADD_NAME) // DEFAULT_FACTOR result = result + self:getHeroEntity():getTotalBaseAtk() * self:getAttrValue(GConst.MATCH_ATTACK_ADD_NAME[self:getHeroEntity():getMatchType()]) // DEFAULT_FACTOR
return result return result
elseif not isBase and (attrType == GConst.MATCH_NORMAL_HURTP_NAME[self:getHeroEntity():getMatchType()] or attrType == GConst.MATCH_SKILL_HURTP_NAME[self:getHeroEntity():getMatchType()]) then elseif not isBase and (attrType == GConst.MATCH_NORMAL_HURTP_NAME[self:getHeroEntity():getMatchType()] or attrType == GConst.MATCH_SKILL_HURTP_NAME[self:getHeroEntity():getMatchType()]) then
result = self:getAttrValue(attrType, true) result = self:getAttrValue(attrType, true)