四灵提交

dev_chengFeng
jiaoyangna 2021-03-10 17:31:40 +08:00
parent 10b8db2d48
commit a7353213aa
12 changed files with 85 additions and 43 deletions

View File

@ -108,8 +108,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: 6, y: -55.3}
m_SizeDelta: {x: 289.34, y: 55.8}
m_AnchoredPosition: {x: 46.60001, y: -55.3}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &1259667852263442369
CanvasRenderer:
@ -261,8 +261,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: -2.3, y: -113.3}
m_SizeDelta: {x: 297.91, y: 60.2}
m_AnchoredPosition: {x: 46.60001, y: -113.3}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &2491344334083209969
CanvasRenderer:
@ -511,7 +511,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: -46, y: 152.1}
m_AnchoredPosition: {x: -37.900024, y: 149.89993}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &1166276110248449307
@ -888,8 +888,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: -46, y: 210.1}
m_SizeDelta: {x: 369.57, y: 55.8}
m_AnchoredPosition: {x: -37.900024, y: 210.09988}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &1201162720067139774
CanvasRenderer:
@ -1046,8 +1046,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: -46, y: -53.399994}
m_SizeDelta: {x: 369.57, y: 55.8}
m_AnchoredPosition: {x: -37.90002, y: -53.399994}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &6280232126945355572
CanvasRenderer:
@ -1125,8 +1125,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: 6, y: 208.89993}
m_SizeDelta: {x: 289.34, y: 55.8}
m_AnchoredPosition: {x: 46.600006, y: 211.1}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7590201538734806173
CanvasRenderer:
@ -1204,8 +1204,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: -1.5, y: 150.9}
m_SizeDelta: {x: 297.91, y: 60.2}
m_AnchoredPosition: {x: 46.600006, y: 150.9}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &3124771122818329842
CanvasRenderer:
@ -1431,7 +1431,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: -46, y: -111.4}
m_AnchoredPosition: {x: -37.90002, y: -111.4}
m_SizeDelta: {x: 375.8, y: 60.2}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8555414412520089612

View File

@ -943,7 +943,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: 68b0233fbe21e6646ad33ae3cf1b72e7, type: 3}
m_Sprite: {fileID: 21300000, guid: 8f9362bef86acb146925242736e5f414, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
@ -3966,7 +3966,7 @@ MonoBehaviour:
m_HorizontalOverflow: 1
m_VerticalOverflow: 1
m_LineSpacing: 1
m_Text: "\u4F24\u5BB3\u52A0\u6210"
m_Text:
--- !u!1 &2449184198827426303
GameObject:
m_ObjectHideFlags: 0
@ -6977,7 +6977,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: 0afcaaf43a0c4744bb8b70d268045136, type: 3}
m_Sprite: {fileID: 21300000, guid: 0146c9a83b59e4744b38c5182880535e, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1

View File

@ -34,7 +34,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: 135.58, y: -100.80005}
m_AnchoredPosition: {x: 135.58, y: -67}
m_SizeDelta: {x: 619.76, y: 59}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &9085467742055475009
@ -326,9 +326,9 @@ 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: -54.5, y: -29.299988}
m_AnchoredPosition: {x: -54.5, y: -16}
m_SizeDelta: {x: 243, y: 84}
m_Pivot: {x: 0.5, y: 0.5}
m_Pivot: {x: 0.5, y: 0.49999994}
--- !u!222 &5943304494707415906
CanvasRenderer:
m_ObjectHideFlags: 0
@ -1058,8 +1058,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: -48, y: 50}
m_SizeDelta: {x: 256, y: 100}
m_AnchoredPosition: {x: -48, y: 56.349976}
m_SizeDelta: {x: 256, y: 87.3}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7831237541682940990
CanvasRenderer:

View File

@ -44,8 +44,8 @@ function this:InitComponent(gameObject)
this.returnLook=Util.GetGameObject(gameObject,"returnLook")
this.returnLook.gameObject:SetActive(true)
this.tip = Util.GetGameObject(gameObject,"tip"):GetComponent("Text")
Util.GetGameObject(gameObject, "RoleGrid/FrontImage"):GetComponent("Image").sprite = Util.LoadSprite("bd_qianqi_zh")
Util.GetGameObject(gameObject, "RoleGrid/BehindImage"):GetComponent("Image").sprite = Util.LoadSprite("bd_houqi_zh")
Util.GetGameObject(gameObject, "RoleGrid/FrontImage"):GetComponent("Image").sprite = Util.LoadSprite("bd_xinqianpai_zh")
Util.GetGameObject(gameObject, "RoleGrid/BehindImage"):GetComponent("Image").sprite = Util.LoadSprite("bd_xinhoupai_zh")
this.returnLook:GetComponent("Image").sprite = Util.LoadSprite("s_silingshilian_huifanganniu_zh")
Util.GetGameObject(gameObject, "Power"):GetComponent("Image").sprite = Util.LoadSprite("t_tongyong-zhanli_zh")
end

View File

@ -163,21 +163,26 @@ function this.InitMonsterShow()
local tempData = this.SingleDataShow(go, monsterInfo[index])
this.singledataList[monsterInfo[index].wave] = tempData
end)
this.scrollView:SetIndex((#monsterInfo-trailData.monsterWave-2))
if MonsterCampManager.CurOffsetIndex < 0 then
this.scrollView:SetIndex((#monsterInfo-trailData.monsterWave-2))
else
this.scrollView:SetIndex((#monsterInfo-MonsterCampManager.CurOffsetIndex-2))
end
end
--界面关闭时调用(用于子类重写)
function FourElementMonsterCampPanel:OnClose()
ClearRedPointObject(redTrailType[curType],Util.GetGameObject(this.btnHelpFight, "redPoint"))
MonsterCampManager.CurOffsetIndex = -1
end
--界面销毁时调用(用于子类重写)
function FourElementMonsterCampPanel:OnDestroy()
this.singledataList = {}
for k,v in pairs(this.singledataList) do
v:OnDestroy()
end
this.singledataList = {}
SubUIManager.Close(this.scrollView)
end
return FourElementMonsterCampPanel

View File

@ -131,9 +131,9 @@ function MonsterCampMainPanel:SetSingleTrailData(go,data)
title.sprite = Util.LoadSprite(FourElementNameImage[data.fourElementType])
curwave.text = (data.monsterWave + 1)..""
if data.canFightTime >= campTowerSetting.TimesStoreMax then
canFightWave.text = string.format("<color=#%s>可挑战层数:%s</color>","FFD695",data.canFightTime)
canFightWave.text = string.format("可挑战层数:<color=#%s>%s</color>","FE9C00",data.canFightTime)
else
canFightWave.text = string.format("<color=#%s>可挑战层数:%s</color>","FFEED3",data.canFightTime)
canFightWave.text = string.format("可挑战层数:<color=#%s>%s</color>","FFEED3",data.canFightTime)
end
openTime.text = this:GetOpenTime(data.fourElementType).."开启"

View File

@ -12,6 +12,7 @@ local gameSetting = ConfigManager.GetConfig(ConfigName.GameSetting)
local itemConfig = ConfigManager.GetConfig(ConfigName.ItemConfig)
--四灵试炼数据
this.fourMonsterData = {}
this.CurOffsetIndex = -1
function this.Initialize()
this.isMaxMonsterWave = false
@ -41,6 +42,7 @@ function this.InitFourMonsterData(msg)
this.fourMonsterData[index].monsterWave = msg.info[i].currentFloor
this.fourMonsterData[index].canFightTime = msg.info[i].remainTimes
this.fourMonsterData[index].openState = msg.info[i].overTime
this.GetTimeTip(index)
end
Game.GlobalEvent:DispatchEvent(GameEvent.FourEle.RefreshView)
end
@ -194,11 +196,11 @@ function this.StraightBattle(id,type,func,curType)
-- end
-- end)
-- UIManager.OpenPanel(UIName.RewardItemPopup,msg.drop,1,function()
-- end)
end
end)
else
LogGreen(#msg.drop.itemlist)
UIManager.OpenPanel(UIName.RewardItemPopup,msg.drop,1,function()
if func then
func()
@ -256,6 +258,7 @@ function this.UpdateHeroDatas(_msgHeroData)
heroData.heroBackData=_msgHeroData
heroData.dynamicId = _msgHeroData.id
local _id = _msgHeroData.heroId
LogYellow("_id:".._id)
heroData.id = _id
heroData.star = _msgHeroData.star
heroData.lv = _msgHeroData.level--30
@ -542,7 +545,7 @@ function this.FourElementRedCheck(redType)
if not ActTimeCtrlManager.IsQualifiled(FUNCTION_OPEN_TYPE.FourElementTrail) then
return false
end
if redType == RedPointType.PersonTrail then
if redType == RedPointType.PersonTrail then
if this.fourMonsterData[1] and this.fourMonsterData[1].openState > 0 then
if this.fourMonsterData[1].freeTime > 0 then
return true
@ -557,7 +560,7 @@ function this.FourElementRedCheck(redType)
end
return this.CheckHelpFightRedPoint(RedPointType.BuddishTrailHelp)
elseif redType == RedPointType.DemonTrail then
if this.fourMonsterData[3] and this.fourMonsterData[3].openState > 0 then
if this.fourMonsterData[3] and this.fourMonsterData[3].openState > 0 then
if this.fourMonsterData[3].freeTime > 0 then
return true
end
@ -566,7 +569,6 @@ function this.FourElementRedCheck(redType)
elseif redType == RedPointType.TaoistTrail then
if this.fourMonsterData[4] and this.fourMonsterData[4].openState > 0 then
if this.fourMonsterData[4].freeTime > 0 then
LogGreen("道玄 红点开了")
return true
end
end
@ -580,13 +582,21 @@ function this.CheckHelpFightRedPoint(redType)
return false
end
if redType == RedPointType.PersonTrailHelp then
if this.fourMonsterData[1] and this.fourMonsterData[1].openState > 0 then
local heros = HeroManager.GetHeroDataByProperty(1,0)
if not heros or #heros < 1 then
return false
end
if this.fourMonsterData[1] and this.fourMonsterData[1].openState > 0 then
if not this.GetMyHelpHero(1) then
return true
end
end
return false
elseif redType == RedPointType.BuddishTrailHelp then
local heros = HeroManager.GetHeroDataByProperty(2,0)
if not heros or #heros < 1 then
return false
end
if this.fourMonsterData[2] and this.fourMonsterData[2].openState > 0 then
if not this.GetMyHelpHero(2) then
return true
@ -594,6 +604,10 @@ function this.CheckHelpFightRedPoint(redType)
end
return false
elseif redType == RedPointType.DemonTrailHelp then
local heros = HeroManager.GetHeroDataByProperty(3,0)
if not heros or #heros < 1 then
return false
end
if this.fourMonsterData[3] and this.fourMonsterData[3].openState > 0 then
if not this.GetMyHelpHero(3) then
return true
@ -601,6 +615,10 @@ function this.CheckHelpFightRedPoint(redType)
end
return false
elseif redType == RedPointType.TaoistTrailHelp then
local heros = HeroManager.GetHeroDataByProperty(4,0)
if not heros or #heros < 1 then
return false
end
if this.fourMonsterData[4] and this.fourMonsterData[4].openState > 0 then
if not this.GetMyHelpHero(4) then
LogGreen("道玄 红点开了")

View File

@ -196,6 +196,14 @@ function this.SendFourChallengeInfoIndication(buffer)
MonsterCampManager.InitFourMonsterData(msg)
MonsterCampManager.SetFriendHelpHero({},nil)
MonsterCampManager.SetMyHelpHeroData(nil)
CheckRedPointStatus(RedPointType.PersonTrail)
CheckRedPointStatus(RedPointType.BuddishTrai)
CheckRedPointStatus(RedPointType.DemonTrail)
CheckRedPointStatus(RedPointType.TaoistTrail)
CheckRedPointStatus(RedPointType.PersonTrailHelp)
CheckRedPointStatus(RedPointType.BuddishTraiHelp)
CheckRedPointStatus(RedPointType.DemonTrailHelp)
CheckRedPointStatus(RedPointType.TaoistTrailHelp)
end
function this.HeroSkinUseIndication(buffer)
local data = buffer:DataByte()
@ -301,6 +309,7 @@ function this.ReceiveFriendChat(buffer)
if msg.type == 1 then
FriendChatManager.ReceiveFriendChat(msg)
elseif msg.type == 2 then
LogGreen("收到了跑马灯消息")
ChatManager.ReceiveFamilyChat(msg)
end
end

View File

@ -13,6 +13,7 @@ function BattleFailPopup:InitComponent()
orginLayer = 0
this.btnClose = Util.GetGameObject(self.gameObject, "Lose")
this.btnBattleBack = Util.GetGameObject(this.btnClose, "btnBattleBack")
this.btnBattleBack:GetComponent("Image").sprite = Util.LoadSprite("s_silingshilian_huifanganniu_zh")
end
--绑定事件(用于子类重写)

View File

@ -46,6 +46,7 @@ function RewardItemPopup:InitComponent()
-- 战斗结果按钮
this.btnResult = Util.GetGameObject(self.gameObject, "ScrollView/Content/bg/btnResult")
this.btnBattleBack = Util.GetGameObject(self.gameObject, "ScrollView/Content/bg/btnBattleBack")
this.btnBattleBack:GetComponent("Image").sprite = Util.LoadSprite("s_silingshilian_huifanganniu_zh")
-- 战斗回放按钮
-- 任意位置继续
this.btnGoOn = Util.GetGameObject(self.gameObject, "btnBack/Image")
@ -137,7 +138,7 @@ function RewardItemPopup:OnOpen(...)
local drop = args[1]
bagType=args[2]
func = args[3]
if args[4] then
compShowType = args[4]
@ -147,6 +148,15 @@ function RewardItemPopup:OnOpen(...)
else
showHero = true
end
if compShowType == CompShowType.fourElement then
this.ScrollView.gameObject:SetActive(false)
this.dropPrefab.gameObject:SetActive(false)
this.ScrollView2.gameObject:SetActive(false)
this.shenying.gameObject:SetActive(true)
this.ShengYingShow(args[8])
return
end
this.shenying.gameObject:SetActive(false)
local haveRecord = BattleRecordManager.isHaveRecord()
this.btnResult:SetActive(haveRecord and args[5])
this.btnBattleBack:SetActive(haveRecord and args[5] and BattleManager.GetLastBattleType() ~= BATTLE_TYPE.MAP_FIGHT and not GuideManager.IsInMainGuide() and not MapManager.Mapping)
@ -176,13 +186,6 @@ function RewardItemPopup:OnOpen(...)
if compShowType == 6 then
this.GuildTranscriptShow()
end
if compShowType == CompShowType.fourElement then
this.ScrollView.gameObject:SetActive(false)
this.dropPrefab.gameObject:SetActive(false)
this.ScrollView2.gameObject:SetActive(false)
this.ShengYingShow(args[8])
return
end
local starItemDataList=BagManager.GetItemListFromTempBag(drop)
-- LogError("获取宝物的数量:".. LengthOfTable(starItemDataList))
--做装备叠加特殊组拼数据
@ -237,6 +240,7 @@ function this.SetComPShowState(type)
end
function this.ShengYingShow(propertyId)
LogGreen("propertyId:"..propertyId)
this.shenyingTxt.text = ConfigManager.GetConfigData(ConfigName.PropertyConfig,propertyId).Info
end

View File

@ -98,11 +98,12 @@ function this:SetSingleData(go,data,index)
else
local fightData = BattleManager.GetBattleServerData(msg)
UIManager.OpenPanel(UIName.BattlePanel, fightData, BATTLE_TYPE.DAILY_CHALLENGE,function(result)
MonsterCampManager.CurOffsetIndex = waveId
if MonsterCampManager.fourMonsterData[curType].openState ~= 0 then
UIManager.OpenPanel(UIName.FourElementMonsterCampPanel,curType)
UIManager.OpenPanel(UIName.ExpeditionMonsterInfoPopup,EXPEDITON_POPUP_TYPE.FourElementMonster,curType,waveId)
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.FourElementReturnLook,waveId,curType,nil)
else
else
UIManager.OpenPanel(UIName.MonsterCampMainPanel)
end
end)

View File

@ -86,15 +86,18 @@ function FourTrailSingleHelpHero:SetIcon1(heroData,player)
self.btn:GetComponent("Button").enabled = true
if self.heifhtPower < heroData.warPower then
self.select.sprite = Util.LoadSprite("s_silingshilian_zhanliguogao_zh")
self.select:SetNativeSize()
self.selectText.text = ""
self.btn:GetComponent("Button").enabled = false
elseif tempData and heroData.dynamicId == tempData.hero.dynamicId then
if tempData.player and tempData.player.state == 1 then
self.select.sprite = Util.LoadSprite("s_silingshilian_yishiyong_zh")
self.select:SetNativeSize()
self.selectText.text = ""
self.btn:GetComponent("Button").enabled = false
else
self.select.sprite = Util.LoadSprite("r_hero_button_001")
self.select:SetNativeSize()
self.selectText.text = "取消选择"
Util.AddOnceClick(self.btn, function()
NetManager.UseHelpHeroRequest(heroData.dynamicId,self.curType,0,function()
@ -121,6 +124,7 @@ function FourTrailSingleHelpHero:SetIcon1(heroData,player)
end
else
self.select.sprite = Util.LoadSprite("r_hero_button_001")
self.select:SetNativeSize()
self.selectText.text = "选择神将"
Util.AddOnceClick(self.btn, function()
if tempData and tempData.player and tempData.player.state == 0 then