Merge branch 'china/dev' into 0功能/命格

dev_chengFeng
ZhangBiao 2021-12-10 18:32:41 +08:00
commit f444315fee
15 changed files with 95 additions and 68 deletions

View File

@ -296,8 +296,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: -227.7}
m_SizeDelta: {x: -115, y: -945.6}
m_AnchoredPosition: {x: 0, y: -194.27}
m_SizeDelta: {x: -115, y: -1012.56}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &263232123
CanvasRenderer:
@ -788,8 +788,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: -11.200012, y: -212}
m_SizeDelta: {x: -56, y: -850}
m_AnchoredPosition: {x: -11.200012, y: -181.5}
m_SizeDelta: {x: -56, y: -911}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &700413945
CanvasRenderer:
@ -1734,8 +1734,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 184, y: 175}
m_AnchoredPosition: {x: 0.12504, y: -0.04}
m_SizeDelta: {x: 160, y: 74}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &6962248010961131481
CanvasRenderer:
@ -1765,8 +1765,8 @@ MonoBehaviour:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 21300000, guid: 461e6af409ec67d45ba908596f22e977, type: 3}
m_Type: 1
m_Sprite: {fileID: 21300000, guid: d8e19ffb0a1c14b4dba326a273e52e7a, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
@ -1889,7 +1889,7 @@ RectTransform:
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 184, y: 175}
m_SizeDelta: {x: 160, y: 74}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8921616627170501590
CanvasRenderer:
@ -1919,7 +1919,7 @@ MonoBehaviour:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 21300000, guid: d780da214597bd144b017ef450a9142d, type: 3}
m_Sprite: {fileID: 21300000, guid: adc4c40d7df40e94db1c69896e51878c, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
@ -1986,7 +1986,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1}
m_Color: {r: 0.70980394, g: 0.6431373, b: 0.5058824, a: 1}
m_RaycastTarget: 1
m_OnCullStateChanged:
m_PersistentCalls:
@ -1994,11 +1994,11 @@ MonoBehaviour:
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_FontData:
m_Font: {fileID: 12800000, guid: 6fa15837529b0e640af6620b07d3207d, type: 3}
m_FontSize: 39
m_Font: {fileID: 12800000, guid: 4b73e9e4512d17e4daeea351e090d33c, type: 3}
m_FontSize: 36
m_FontStyle: 0
m_BestFit: 0
m_MinSize: 10
m_MinSize: 3
m_MaxSize: 40
m_Alignment: 4
m_AlignByGeometry: 0
@ -2876,7 +2876,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 74.9, y: 23}
m_AnchoredPosition: {x: 78.99998, y: 16.095001}
m_SizeDelta: {x: 26, y: 26}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &6875376091408120744
@ -2950,7 +2950,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 0}
m_AnchoredPosition: {x: 0.000030517578, y: 38}
m_AnchoredPosition: {x: 0, y: 38}
m_SizeDelta: {x: 0, y: 76}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &4125706634736168924
@ -2971,7 +2971,7 @@ MonoBehaviour:
m_Top: 0
m_Bottom: 0
m_ChildAlignment: 4
m_Spacing: 27.71
m_Spacing: 1.7
m_ChildForceExpandWidth: 0
m_ChildForceExpandHeight: 0
m_ChildControlWidth: 0
@ -3106,7 +3106,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 0}
m_AnchoredPosition: {x: 9.15, y: 175.2}
m_AnchoredPosition: {x: 9.1501, y: 214.5}
m_SizeDelta: {x: -96.7, y: 75.6}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &5457082822150884615

View File

@ -85,7 +85,7 @@ ConfigName = {
GuildSetting = "GuildSetting",
GuildLevelConfig = "GuildLevelConfig",
GuildRewardConfig = "GuildRewardConfig",
ActivityRankingReward = "ActivityRankingRewardActivityRankingReward",
ActivityRankingReward = "ActivityRankingReward",
ExchangeActivityConfig = "ExchangeActivityConfig",
FloodConfig = "FloodConfig",
LoginPosterConfig = "LoginPosterConfig",

View File

@ -3560,8 +3560,8 @@ GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.index = 5
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.label = 1
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.has_default_value = false
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.default_value = 0
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.type = 5
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.cpp_type = 1
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.type = 3
GETGUILDCHALLENGEINFORESPONSE_SWEEPDAMAGE_FIELD.cpp_type = 2
GETGUILDCHALLENGEINFORESPONSE_REFRESHEDBOSS_FIELD.name = "refreshedBoss"
GETGUILDCHALLENGEINFORESPONSE_REFRESHEDBOSS_FIELD.full_name = ".rpc.protocols.GetGuildChallengeInfoResponse.refreshedBoss"
@ -3656,8 +3656,8 @@ GUILDCHALLENGERESPONSE_DAMAGE_FIELD.index = 3
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.label = 1
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.has_default_value = false
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.default_value = 0
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.type = 5
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.cpp_type = 1
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.type = 3
GUILDCHALLENGERESPONSE_DAMAGE_FIELD.cpp_type = 2
GUILDCHALLENGERESPONSE.name = "GuildChallengeResponse"
GUILDCHALLENGERESPONSE.full_name = ".rpc.protocols.GuildChallengeResponse"

View File

@ -2822,7 +2822,7 @@ local effectList = {
local round = args[3]
BattleLogic.WaitForTrigger(interval, function ()
local damage=floor(target:GetRoleData(p1)*v1)
local damage=floor(target:GetRoleData(BattlePropList[p1])*v1)
local buff=Buff.Create(caster,BuffName.HOT,round,1,damage)
buff.hotType=2
target:AddBuff(buff)
@ -2858,7 +2858,7 @@ local effectList = {
local lessNum = max(maxNum - curNum, 0)
local level = math.floor(lessNum/i1)
local extra = BattleUtil.ErrorCorrection(level * v2)
local damage=floor(target:GetRoleData(pro)*(v1+extra))
local damage=floor(target:GetRoleData(BattlePropList[pro])*(v1+extra))
BattleUtil.FinalDamageCountShield(nil,caster, target,damage)
end)
end,

View File

@ -6999,17 +6999,19 @@ local passivityList = {
local onPassiveDamaging = function(func, defRole, damage,skill)
if skill and not skill.isTriggerJudge and judge==1 then
return
end
end
--观音,这个被动只有额外技能才能触发 by王振兴 2021/1/21 17:48
if skill and skill.type == BattleSkillType.Extra then
if skill and skill.isAdd and (skill.type == BattleSkillType.Extra or skill.type == BattleSkillType.Special ) then
--如果是boss 并且额外伤害是根据最大生命则返回
if (f1==12 or f1==13) and BattleUtil.CheckIsBoss(defRole) then
return
end
local val = -floor(BattleUtil.FP_Mul(dt, defRole:GetRoleData(BattlePropList[f1])))
if func then
func(val)
end
local val = floor(BattleUtil.FP_Mul(dt, defRole:GetRoleData(BattlePropList[f1])))
-- LogError("val=="..val)
-- if func then
-- func(val)
-- end
BattleUtil.FinalDamageCountShield(nil,role,defRole,val)
end
end
role.Event:AddEvent(BattleEventName.PassiveDamaging, onPassiveDamaging,nil,nil,role)

View File

@ -1,8 +1,7 @@
Shield = Buff:New()
-- 无敌吸血盾的免疫状态
local immune0 = function(buff)
return buff.type == BuffName.Control or buff.isDeBuff or buff.type == BuffName.DOT or buff.caster.camp~=buff.target.camp
end
local immune0 = nil
local onRoleBeHit=nil
--初始化Buff通过传入一些自定义参数控制成长相关的数值
function Shield:SetData(...)
@ -16,26 +15,30 @@ function Shield:SetData(...)
self.cover = self.shieldType ~= ShieldTypeName.NormalReduce -- 除固定减伤盾外都不能叠加
-- 刷新排序等级
self.sort = 4
end
local onRoleBeHit=function(atkRole, damage, bCrit, finalDmg, damageType, skill)
--damagetype为3 是 舍身济世分摊伤害
if damageType==3 then
return
immune0=function(buff)
return buff.type == BuffName.Control or buff.isDeBuff or buff.type == BuffName.DOT or buff.caster.camp~=self.target.camp
end
if skill then --技能造成的直接伤害
local rDamage = math.floor(damage*self.shieldValue)
if rDamage ~= 0 then
BattleUtil.ApplyDamage(nil,self.target,atkRole, rDamage)
onRoleBeHit=function(atkRole, damage, bCrit, finalDmg, damageType, skill)
--damagetype为3 是 舍身济世分摊伤害
if damageType==3 then
return
end
if skill then --技能造成的直接伤害
LogError("damage=="..damage.." shiledv=="..self.shieldValue.." type=="..self.shieldType)
local rDamage = math.floor(damage*self.shieldValue)
if rDamage ~= 0 then
BattleUtil.ApplyDamage(nil,self.target,atkRole, rDamage)
end
end
end
end
--初始化后调用一次
function Shield:OnStart()
self.target.shield:Add(self)
if self.shieldType == ShieldTypeName.AllReduce then
self.target.buffFilter:Add(immune0)
-- 清除所有负面buff
@ -96,6 +99,8 @@ function Shield:CountShield(damage, atkRole,skill)
local treatValue = math.floor(BattleUtil.ErrorCorrection(damage * self.shieldValue))
BattleUtil.ApplyTreat(self.target, self.target, treatValue)
end
elseif self.shieldType == ShieldTypeName.ThornsReduce then
finalDamage=damage
end
--
@ -140,6 +145,8 @@ function Shield:PreCountShield(damage)
elseif self.shieldType == ShieldTypeName.AllReduce then
finalDamage = 0
elseif self.shieldType == ShieldTypeName.ThornsReduce then
finalDamage=damage
end
return finalDamage
end

View File

@ -192,7 +192,7 @@ BattleEventName = {
ImmuneDebuffSuccess = indexAdd(),--免疫debuff成功
ChangeRoleRage = indexAdd(),--改变角色怒气
PassiveChangeIgnoreDef = indexAdd(),--被动改变无视防御比例
PassiveChangeDefDMGReFac = indexAdd(),--被动改变伤比例
PassiveChangeDefDMGReFac = indexAdd(),--被动改变防御方减伤比例
PassiveChangeRoleHit = indexAdd(),--被动改变角色命中
}

View File

@ -434,6 +434,8 @@ function EnemyView:OnShieldTrigger(shield,isImmuneAllReduceShield)
if atkRole and not isImmuneAllReduceShield then
self.Floater:ImageBuffFloating("z_zhandou_wudizi_zh")
end
elseif shield.shieldType == ShieldTypeName.ThornsReduce then
-- body
else
self.Floater:ImageBuffFloating("z_zhandou_jianshang_zh")
end

View File

@ -144,6 +144,9 @@ end
-- 播放动画
function MonsterView:PlaySpineAnim(gog, time, name, isLoop)
if self.isMainPlayer then
name = "idle"
end
if isLoop then
gog.AnimationState:SetAnimation(time, name, isLoop)
else

View File

@ -493,7 +493,9 @@ function PlayerView:OnShieldTrigger(shield,isImmuneAllReduceShield)
if shield.shieldType == ShieldTypeName.AllReduce then
if atkRole and not isImmuneAllReduceShield then
self.Floater:ImageBuffFloating("z_zhandou_wudizi_zh")
end
end
elseif shield.shieldType == ShieldTypeName.ThornsReduce then
else
self.Floater:ImageBuffFloating("z_zhandou_jianshang_zh")
end

View File

@ -447,6 +447,8 @@ function RoleView:OnShieldTrigger(shield,isImmuneAllReduceShield)
if atkRole and not isImmuneAllReduceShield then
self.Floater:ImageBuffFloating("z_zhandou_wudizi_zh")
end
elseif shield.shieldType == ShieldTypeName.ThornsReduce then
else
self.Floater:ImageBuffFloating("z_zhandou_jianshang_zh")
end

View File

@ -1,6 +1,10 @@
MonthCardManager = {}
local this = MonthCardManager
local MonthCardText = {
[MONTH_CARD_TYPE.MONTHCARD] = "普通月卡",
[MONTH_CARD_TYPE.LUXURYMONTHCARD] = "豪华月卡",
[MONTH_CARD_TYPE.GIFT] = "挚礼月卡",
}
--初始化月卡数据
local monthCardData = {}
function this.InitMonthCardData(data)
@ -24,8 +28,8 @@ function this.UpdateMonthCardData(msg)
--当我数据没有 后端推过来的有数据 此时需要弹窗
this.showStr = ""
for i = 1, #msg.monthinfos do
if monthCardData[i].endingTime <= 0 then
this.showStr = Language[11384]
if monthCardData[i].endingTime <= 0 then
this.showStr = string.format("恭喜您成功激活%s功能是否立即前往月卡界面领取奖励。", MonthCardText[i])--Language[11384]
end
end
monthCardData = {}

View File

@ -255,12 +255,12 @@ function PrivilegeManager.GetPrivilegeOpenTip(privilegeType)
-- end
-- end
-- end
if privilegeType==PRIVILEGE_TYPE.DoubleTimesFight then
local lvOpenTimeScaleConFig = ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.PrivilegeTypeConfig,"PrivilegeType",PRIVILEGE_TYPE.DoubleTimesFight,"UnlockType",1)
-- local fightConfig = ConfigManager.GetConfigData(ConfigName.MainLevelConfig, infoList[1])
-- return string.format("通关 %s 关卡解锁或玩家特权等级达到 %s 级解锁",GetLanguageStrById(fightConfig.Name),infoList[2])
return string.format(Language[11406],lvOpenTimeScaleConFig.Condition[1][1])
end
-- if privilegeType==PRIVILEGE_TYPE.DoubleTimesFight then
-- local lvOpenTimeScaleConFig = ConfigManager.TryGetConfigDataByDoubleKey(ConfigName.PrivilegeTypeConfig,"PrivilegeType",PRIVILEGE_TYPE.DoubleTimesFight,"UnlockType",1)
-- -- local fightConfig = ConfigManager.GetConfigData(ConfigName.MainLevelConfig, infoList[1])
-- -- return string.format("通关 %s 关卡解锁或玩家特权等级达到 %s 级解锁",GetLanguageStrById(fightConfig.Name),infoList[2])
-- return string.format(Language[11406],lvOpenTimeScaleConFig.Condition[1][1])
-- end
-- end
local privilegeData = privilegeList[1]

View File

@ -38,8 +38,7 @@ end
function this.CheckIsBuyTreasureByGoodsId(goodsId)
local goodsInfo = OperatingManager.GetGiftGoodsInfo(GoodsTypeDef.RecruiteTreasure,goodsId)
LogGreen("goodsInfo.isBought:"..tostring(goodsInfo.isBought))
return goodsInfo.isBought > 0
return goodsInfo and goodsInfo.isBought > 0
end
function this.GetConfigDataByActId(actId)

View File

@ -25,14 +25,15 @@ function RecruitTreasurePanel:InitComponent()
this.buyBtn = Util.GetGameObject(self.transform, "bg/topBar/buyBtn")
this.Text1 = Util.GetGameObject(this.buyBtn, "buy"):GetComponent("Text")
this.tips = Util.GetGameObject(self.transform, "bg/topBar/tips"):GetComponent("Text")
this.topBarImage = Util.GetGameObject(self.transform, "bg/topBar"):GetComponent("Image")
--Content
this.scoreText = Util.GetGameObject(self.transform, "bg/pageContent/bg/score/number"):GetComponent("Text")
this.treasureList = Util.GetGameObject(self.transform, "bg/pageContent/treasureList")
this.itemPre = Util.GetGameObject(self.transform, "bg/pageContent/itemPro")
local v = this.treasureList:GetComponent("RectTransform").rect
--设置滚动条
this.ScrollView = SubUIManager.Open(SubUIConfig.ScrollCycleView,this.treasureList.transform,this.itemPre,nil,Vector2.New(950, 1000),1,1,Vector2.New(100, 25))
this.ScrollView = SubUIManager.Open(SubUIConfig.ScrollCycleView,this.treasureList.transform,this.itemPre,nil,Vector2.New(v.width, v.height),1,1,Vector2.New(100, 25))
this.ScrollView.gameObject:GetComponent("RectTransform").anchoredPosition = Vector2.New(0, 0)
this.ScrollView.gameObject:GetComponent("RectTransform").anchorMin = Vector2.New(0.5, 0.5)
this.ScrollView.gameObject:GetComponent("RectTransform").anchorMax = Vector2.New(0.5, 0.5)
@ -54,7 +55,6 @@ function RecruitTreasurePanel:BindEvent()
this.PageTabCtrl:SetTabAdapter(this.PageTabAdapter)
this.PageTabCtrl:SetTabIsLockCheck(this.PageTabIsLockCheck)
this.PageTabCtrl:SetChangeTabCallBack(this.OnPageTabChange)
end
function this.PageTabAdapter(tab, index, status)
@ -64,10 +64,11 @@ function this.PageTabAdapter(tab, index, status)
local redpot = Util.GetGameObject(tab, "redpot")
if status == "select" then
select.gameObject:SetActive(true)
tip.text = string.format("<color=#%s>%s</color>","FDF4D6",configs[index].Icon[1])
else
select.gameObject:SetActive(false)
tip.text = string.format("<color=#%s>%s</color>","B5A481",configs[index].Icon[1])
end
tip.text = configs[index].Icon[1]
if redPointTypeList[configs[index].RpType] then
ClearRedPointObject(configs[index].RpType,redPointTypeList[configs[index].RpType])
redPointTypeList[configs[index].RpType] = nil
@ -92,6 +93,9 @@ end
function this.OnPageTabChange(index)
curPage = index
this.actId = configs[curPage].ActId
this.tips.text = configs[curPage].TitleText
this.topBarImage.sprite = this.spLoader:LoadSprite(configs[curPage].Icon[2])
this:refresh()
end
@ -122,7 +126,6 @@ function RecruitTreasurePanel:OnShow(_sortingOrder)
sortingOrder = _sortingOrder
this.actType = this.actConfig.ActiveType > 0 and this.actConfig.ActiveType or this.actConfig.FunType
this.titleImage.sprite = this.spLoader:LoadSprite(this.actConfig.Icon[3])
local activeNum = 0
curPage = 0
for i = 1,#configs do
@ -148,15 +151,13 @@ function RecruitTreasurePanel:OnShow(_sortingOrder)
if curPage < 1 then
curPage = activeNum
end
this.actData = ActivityGiftManager.GetActivityInfoByType(configs[curPage].ActId)
this.PageTabCtrl:Init(this.tabbox.gameObject, configs,curPage)
end
function RecruitTreasurePanel:refresh()
this.actId = configs[curPage].ActId
this.tips.text = configs[curPage].TitleText
this.isBuy = RecruitTreasureManager.CheckIsBuyTreasureByGoodsId(configs[curPage].ShopData[1][1])
LogGreen("this.isBuy:"..tostring(this.isBuy))
this.treasureData = RecruitTreasureManager.GetRecruitTreasureData(configs[curPage].ActId,configs[curPage].ShopData[1][1])
this.actData = ActivityGiftManager.GetActivityInfoByType(configs[curPage].ActId)
this.isBuy = RecruitTreasureManager.CheckIsBuyTreasureByGoodsId(configs[curPage].ShopData[1][1])
self:topBar()
self:showTaskList()
end
@ -318,6 +319,11 @@ end
--界面销毁时调用(用于子类重写)
function RecruitTreasurePanel:OnDestroy()
this.spLoader:Destroy()
for k,v in pairs(this.itemsList) do
for n,m in pairs(v) do
SubUIManager.Close(m)
end
end
this.itemsList = {}
if this.ScrollView then
SubUIManager.Close(this.ScrollView)