英雄属性添加时空英雄属性

dev_chengFeng
wangzhenxing 2023-04-19 17:49:29 +08:00
parent 7da600c422
commit 7c2598c7e7
8 changed files with 29 additions and 14 deletions

View File

@ -238,6 +238,8 @@ RoleDataName = {
DaoReduce = indexAdd(), --道系伤害减免
CritDamageReduce = indexAdd(), --暴击伤害减免
InitRage = indexAdd(), --初始怒气值
KongBonus = indexAdd(), --时空系伤害加成
KongReduce = indexAdd(), --时空系伤害减免
}
-- 战斗表属性id对应战斗中属性数据
@ -266,6 +268,8 @@ BattlePropList = {
RoleDataName.FoReduce,
RoleDataName.YaoReduce,
RoleDataName.DaoReduce,
RoleDataName.KongBonus,
RoleDataName.KongReduce,
RoleDataName.CritDamageReduce,
}
@ -388,7 +392,8 @@ BattleRoleElementType = {
REN = 1,
FO = 2,
YAO = 3,
DAO = 4
DAO = 4,
Kong = 5,
}
BattleArtFontType = {
@ -406,11 +411,13 @@ BattleMieProp = {
[BattleRoleElementType.REN] = RoleDataName.RenBonus,
[BattleRoleElementType.FO] = RoleDataName.FoBonus,
[BattleRoleElementType.YAO] = RoleDataName.YaoBonus,
[BattleRoleElementType.DAO] = RoleDataName.DaoBonus
[BattleRoleElementType.DAO] = RoleDataName.DaoBonus,
[BattleRoleElementType.Kong] = RoleDataName.KongBonus
}
BattleKangProp = {
[BattleRoleElementType.REN] = RoleDataName.RenReduce,
[BattleRoleElementType.FO] = RoleDataName.FoReduce,
[BattleRoleElementType.YAO] = RoleDataName.YaoReduce,
[BattleRoleElementType.DAO] = RoleDataName.DaoReduce
[BattleRoleElementType.DAO] = RoleDataName.DaoReduce,
[BattleRoleElementType.Kong] = RoleDataName.KongReduce
}

View File

@ -7,8 +7,8 @@ local function isFactor(name)
end
function RoleData.New()
local instance = {role=0, data={0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0},
orginData={0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0}}
local instance = {role=0, data={0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0},
orginData={0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0, 0,0,0}}
setmetatable(instance, RoleData)
return instance
end

View File

@ -199,7 +199,7 @@ function EnemyView:onCreate(go, role, position, root, isBoss,enemyId)
self.URoleProperty = URoleProperty
self.URoleProperty.uid = role.uid
role.data:Foreach(function (name, value)
self.URoleProperty:AddProperty(name, value)
--self.URoleProperty:AddProperty(name, value)
end)
end
@ -313,7 +313,7 @@ function EnemyView:Update()
if IsOpenBattleDebug then
self.role.data:Foreach(function (name, value)
self.URoleProperty:SetValue(name, value)
--self.URoleProperty:SetValue(name, value)
end)
end
end

View File

@ -107,7 +107,7 @@ function MonsterView:onCreate(go, role, position, root)
self.URoleProperty = URoleProperty
self.URoleProperty.uid = role.uid
role.data:Foreach(function (name, value)
self.URoleProperty:AddProperty(name, value)
--self.URoleProperty:AddProperty(name, value)
end)
end
self.combat=nil
@ -121,7 +121,7 @@ end
function MonsterView:Update()
if IsOpenBattleDebug then
self.role.data:Foreach(function (name, value)
self.URoleProperty:SetValue(name, value)
--self.URoleProperty:SetValue(name, value)
end)
end
end

View File

@ -257,8 +257,15 @@ function PlayerView:onCreate(go, role, position, root)
end
self.URoleProperty = URoleProperty
self.URoleProperty.uid = role.uid
-- local bbb={}
-- bbb=self.URoleProperty:GetNames()
-- --LogError("# aaa len=="..#bbb)
-- for key, value in pairs(bbb) do
-- LogError("# aaa i=="..value)
-- end
role.data:Foreach(function (name, value)
self.URoleProperty:AddProperty(name, value)
--self.URoleProperty:AddProperty(name, value)
end)
end
@ -366,7 +373,7 @@ function PlayerView:Update()
if IsOpenBattleDebug then
self.role.data:Foreach(function (name, value)
self.URoleProperty:SetValue(name, value)
--self.URoleProperty:SetValue(name, value)
end)
end
end

View File

@ -195,7 +195,7 @@ function RoleView:onCreate(go, role, position, root)
self.URoleProperty = URoleProperty
self.URoleProperty.uid = role.uid
role.data:Foreach(function (name, value)
self.URoleProperty:AddProperty(name, value)
--self.URoleProperty:AddProperty(name, value)
end)
end
@ -294,7 +294,7 @@ function RoleView:Update()
if IsOpenBattleDebug then
self.role.data:Foreach(function (name, value)
self.URoleProperty:SetValue(name, value)
--self.URoleProperty:SetValue(name, value)
end)
end
end

View File

@ -117,7 +117,7 @@ end
function WeaponView:Update()
if IsOpenBattleDebug then
self.role.data:Foreach(function (name, value)
self.URoleProperty:SetValue(name, value)
--self.URoleProperty:SetValue(name, value)
end)
end
end

View File

@ -29,6 +29,7 @@ function LikeAbilityPanel:InitComponent()
if tabsImg[i + 1] then
Util.GetGameObject(tabs[i], "Image"):GetComponent("Image").sprite = self.spLoader:LoadSprite(tabsImg[i + 1])
end
tabs[i]:SetActive(true)
end
self.selectBtn = Util.GetGameObject(self.btnPrant, "selectBtn")