Merge branch 'china/dev' into china/test
commit
c3e47af41f
|
|
@ -138,9 +138,9 @@ function this.InitActivityServerData(msg, isUpdate)
|
||||||
if GlobalActivity[v.activityId] then
|
if GlobalActivity[v.activityId] then
|
||||||
this.CheckMoneyProgress(v)
|
this.CheckMoneyProgress(v)
|
||||||
this.mission[v.activityId] = v
|
this.mission[v.activityId] = v
|
||||||
LogYellow("刷新活动数据activityId:" .. v.activityId .. " value:" .. v.value)
|
-- LogYellow("刷新活动数据activityId:" .. v.activityId .. " value:" .. v.value)
|
||||||
for n, m in ipairs(v.mission) do
|
for n, m in ipairs(v.mission) do
|
||||||
LogGreen(" 刷新活动数据missionId:" .. m.missionId .. " state:" .. m.state .. " progress:" .. m.progress)
|
-- LogGreen(" 刷新活动数据missionId:" .. m.missionId .. " state:" .. m.state .. " progress:" .. m.progress)
|
||||||
if (v.activityId == ActivityTypeDef.OnlineGift) then
|
if (v.activityId == ActivityTypeDef.OnlineGift) then
|
||||||
this.onlineOpen = true
|
this.onlineOpen = true
|
||||||
this.onlineGetRewardState[m.missionId] = m.state
|
this.onlineGetRewardState[m.missionId] = m.state
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ Blood = Buff:New()
|
||||||
function Blood:SetData(...)
|
function Blood:SetData(...)
|
||||||
|
|
||||||
-- 刷新排序等级
|
-- 刷新排序等级
|
||||||
self.bloodValue=...
|
--self.bloodValue=...
|
||||||
|
self.bloodValue=0
|
||||||
self.sort = 4
|
self.sort = 4
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
@ -23,12 +23,12 @@ end
|
||||||
|
|
||||||
--初始化后调用一次
|
--初始化后调用一次
|
||||||
function Blood:OnStart()
|
function Blood:OnStart()
|
||||||
self.target.bloodShield = self
|
--self.target.bloodShield = self
|
||||||
local passiveChange=function(addValue)
|
-- local passiveChange=function(addValue)
|
||||||
self.bloodValue=self.bloodValue+addValue
|
-- self.bloodValue=self.bloodValue+addValue
|
||||||
end
|
-- end
|
||||||
BattleLogic.Event:DispatchEvent(BattleEventName.BloodValuePassiveChange,passiveChange,self.target,self.caster,self.bloodValue)
|
-- BattleLogic.Event:DispatchEvent(BattleEventName.BloodValuePassiveChange,passiveChange,self.target,self.caster,self.bloodValue)
|
||||||
self.target.Event:DispatchEvent(BattleEventName.BloodValueChange,self.bloodValue/self.target:GetRoleData(RoleDataName.MaxHp),1,self.bloodValue)
|
-- self.target.Event:DispatchEvent(BattleEventName.BloodValueChange,self.bloodValue/self.target:GetRoleData(RoleDataName.MaxHp),1,self.bloodValue)
|
||||||
end
|
end
|
||||||
function Blood:GetCurValue()
|
function Blood:GetCurValue()
|
||||||
return self.bloodValue
|
return self.bloodValue
|
||||||
|
|
|
||||||
|
|
@ -1307,13 +1307,15 @@ end
|
||||||
function BattleUtil.AddBlood(target,value)
|
function BattleUtil.AddBlood(target,value)
|
||||||
if not target.isBanBlood then
|
if not target.isBanBlood then
|
||||||
if target.bloodShield then
|
if target.bloodShield then
|
||||||
BattleLogic.WaitForTrigger(BattleLogic.GameDeltaTime*2,function()
|
--BattleLogic.WaitForTrigger(BattleLogic.GameDeltaTime*2,function()
|
||||||
target.bloodShield:AddValue(value)
|
target.bloodShield:AddValue(value)
|
||||||
end)
|
--end)
|
||||||
else
|
else
|
||||||
local buff=Buff.Create(target, BuffName.Blood,0,value)
|
local buff=Buff.Create(target, BuffName.Blood,0,value)
|
||||||
target:AddBuff(buff)
|
target:AddBuff(buff)
|
||||||
target.bloodShield=buff
|
target.bloodShield=buff
|
||||||
|
target.bloodShield:AddValue(value)
|
||||||
|
--target.bloodShield:star
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
target.Event:DispatchEvent(BattleEventName.ShowHintText, BattleArtFontType.Blood)
|
target.Event:DispatchEvent(BattleEventName.ShowHintText, BattleArtFontType.Blood)
|
||||||
|
|
|
||||||
|
|
@ -258,7 +258,7 @@ function PracticeImprint:ShowSingleImprintInfoLayout(_serverData,_configData)
|
||||||
proIcon.sprite = self.spLoader:LoadSprite(GetProStrImageByProNum(heroData.heroConfig.PropertyName))
|
proIcon.sprite = self.spLoader:LoadSprite(GetProStrImageByProNum(heroData.heroConfig.PropertyName))
|
||||||
local star,starType = heroData.GetStar(1)
|
local star,starType = heroData.GetStar(1)
|
||||||
SetHeroStars(self.spLoader,starGrid, star,starType)
|
SetHeroStars(self.spLoader,starGrid, star,starType)
|
||||||
SetHeroFlyEffect(Util.GetGameObject(self.head, "GameObject"),self.spLoader,heroData.star,self.sortingOrder+1,1,3,0)
|
SetHeroFlyEffect(Util.GetGameObject(self.itemPre, "GameObject"),self.spLoader,heroData.star,self.sortingOrder+1,1,3,0)
|
||||||
Util.SetParticleSortLayer(starGrid,self.sortingOrder + 1)
|
Util.SetParticleSortLayer(starGrid,self.sortingOrder + 1)
|
||||||
curhero = _serverData.subId
|
curhero = _serverData.subId
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -260,8 +260,8 @@ function EveryDayGiftNew:RefreshReward(Data)
|
||||||
if Data.data.limitNum - Data.data.boughtNum > 0 then
|
if Data.data.limitNum - Data.data.boughtNum > 0 then
|
||||||
-- LogYellow(tostring(rechargeNum).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
-- LogYellow(tostring(rechargeNum).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
||||||
if rechargeNum >= Data.data.shopItemData.BuyRule[2] then
|
if rechargeNum >= Data.data.shopItemData.BuyRule[2] then
|
||||||
-- LogPink(tostring(BagManager.GetItemCountById(Data.data.costId)).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
-- LogPink(tostring(BagManager.GetItemCountById(Data.data.costId)).." "..tostring(Data.data.price))
|
||||||
if BagManager.GetItemCountById(Data.data.costId) >= Data.data.shopItemData.BuyRule[2] then
|
if BagManager.GetItemCountById(Data.data.costId) >= Data.data.price then
|
||||||
-- LogBlue(tostring(Data.data.shopItemData.buyType).." "..tostring(Data.data.shopData.id))
|
-- LogBlue(tostring(Data.data.shopItemData.buyType).." "..tostring(Data.data.shopData.id))
|
||||||
ShopManager.RequestBuyShopItem(Data.buyType, Data.data.shopData.id, 1, function()
|
ShopManager.RequestBuyShopItem(Data.buyType, Data.data.shopData.id, 1, function()
|
||||||
self:SetGrowGift()
|
self:SetGrowGift()
|
||||||
|
|
|
||||||
|
|
@ -177,7 +177,7 @@ function RechargeViewNew:RefreshReward(Data)
|
||||||
-- LogYellow(tostring(rechargeNum).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
-- LogYellow(tostring(rechargeNum).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
||||||
if rechargeNum >= Data.data.shopItemData.BuyRule[2] then
|
if rechargeNum >= Data.data.shopItemData.BuyRule[2] then
|
||||||
-- LogPink(tostring(BagManager.GetItemCountById(Data.data.costId)).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
-- LogPink(tostring(BagManager.GetItemCountById(Data.data.costId)).." "..tostring(Data.data.shopItemData.BuyRule[2]))
|
||||||
if BagManager.GetItemCountById(Data.data.costId) >= Data.data.shopItemData.BuyRule[2] then
|
if BagManager.GetItemCountById(Data.data.costId) >= Data.data.price then
|
||||||
-- LogBlue(tostring(Data.data.shopItemData.buyType).." "..tostring(Data.data.shopData.id))
|
-- LogBlue(tostring(Data.data.shopItemData.buyType).." "..tostring(Data.data.shopData.id))
|
||||||
ShopManager.RequestBuyShopItem(Data.buyType, Data.data.shopData.id, 1, function()
|
ShopManager.RequestBuyShopItem(Data.buyType, Data.data.shopData.id, 1, function()
|
||||||
self:SetGrowGift()
|
self:SetGrowGift()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue