[神兵]==============修改提交
parent
3f8a00cb14
commit
6d3fe931d3
Binary file not shown.
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 18 KiB |
Binary file not shown.
Before Width: | Height: | Size: 7.2 KiB After Width: | Height: | Size: 20 KiB |
File diff suppressed because it is too large
Load Diff
|
@ -12,6 +12,7 @@ function GodWeaponGetInfoPopup:InitComponent()
|
|||
this.spLoader = SpriteLoader.New()
|
||||
|
||||
this.BtnBack=Util.GetGameObject(self.transform, "bg/btnBack")
|
||||
Util.GetGameObject(self.transform, "bg/title"):GetComponent("Text").text="查看神兵"
|
||||
this.liveRoot=Util.GetGameObject(self.transform, "bg/liveRoot"):GetComponent("Image")
|
||||
this.heroName = Util.GetGameObject(self.transform, "bg/nameInfo/nameText"):GetComponent("Text")
|
||||
this.starGrid = Util.GetGameObject(self.transform, "bg/PokemonInfo/starGrid(Clone)")
|
||||
|
@ -67,7 +68,7 @@ function this.GetShowPanelData()
|
|||
local pokemonSData=ConfigManager.GetConfigData(ConfigName.ShenBing, pokemonBackData.tempId)
|
||||
this.heroName.text = GetStringByEquipQua(pokemonSData.Quality, GetLanguageStrById(pokemonSData.Name))
|
||||
SetTextVerTial(this.heroName,Vector3.New(96.87,0,0))
|
||||
--this.ShowPokemonLive(pokemonSData)
|
||||
----this.ShowPokemonLive(pokemonSData)
|
||||
this.liveRoot.sprite=this.spLoader:LoadSprite(GetResourcePath(pokemonSData.Icon))
|
||||
--星级
|
||||
PokemonManager.SetHeroStars(this.spLoader, this.starGrid, pokemonBackData.star,2,Vector2.New(60,60))
|
||||
|
@ -95,32 +96,21 @@ function this.GetShowPanelData()
|
|||
skillList[i]:SetActive(true)
|
||||
local skillName=Util.GetGameObject(skillList[i].transform,"nameText"):GetComponent("Text")
|
||||
local skillIcon=Util.GetGameObject(skillList[i].transform,"icon"):GetComponent("Image")
|
||||
local skillBtn=Util.GetGameObject(skillList[i].transform,"bg/PokemonInfo/skill/icon")
|
||||
skillName.text=skills[i].Name
|
||||
skillIcon.sprite= this.spLoader:LoadSprite(GetResourcePath(skills[i].Icon))
|
||||
Util.AddOnceClick(skillIcon.gameObject, function()
|
||||
local allSkillData=ConfigManager.GetAllConfigsDataByDoubleKey(ConfigName.ShenBingSkill,"SkillPanDuan",skills[i].SkillPanDuan,"SpiritAnimalMatch",skills[i].SpiritAnimalMatch)
|
||||
UIManager.OpenPanel(UIName.GodWeaponSkillInfoPopup,skills[i].Name,allSkillData)
|
||||
end)
|
||||
end
|
||||
|
||||
-- local curSkillId = 0
|
||||
-- local skillArray = ConfigManager.GetConfigData(ConfigName.SpiritAnimal,pokemonBackData.tempId).SkillArray
|
||||
-- for i = 1, #skillArray do
|
||||
-- if skillArray[i][1] == pokemonBackData.star then
|
||||
-- curSkillId = skillArray[i][2]
|
||||
-- end
|
||||
-- end
|
||||
-- local curSkillConFig = ConfigManager.GetConfigData(ConfigName.SpiritAnimalSkill,curSkillId)
|
||||
-- this.skillName.text = GetLanguageStrById(curSkillConFig.Name)
|
||||
-- this.skillLvGo:SetActive(true)
|
||||
-- this.skillLv.text = curSkillConFig.Level
|
||||
-- this.skillIcon.sprite = this.spLoader:LoadSprite(GetResourcePath(curSkillConFig.Icon))
|
||||
Util.AddOnceClick(this.skillBtn, function()
|
||||
UIManager.OpenPanel(UIName.PokemonSkillInfoPopup,pokemonBackData.tempId,pokemonBackData.level,pokemonBackData.star)
|
||||
end)
|
||||
|
||||
end
|
||||
function this.NoGetShowPanelData()
|
||||
local pokemonSData=ConfigManager.GetConfigData(ConfigName.ShenBing, pokemonSid)
|
||||
this.heroName.text = GetStringByEquipQua(pokemonSData.Quality, GetLanguageStrById(pokemonSData.Name))
|
||||
SetTextVerTial(this.heroName,Vector3.New(96.87,0,0))
|
||||
--this.ShowPokemonLive(pokemonSData)
|
||||
this.liveRoot.sprite=this.spLoader:LoadSprite(GetResourcePath(pokemonSData.Icon))
|
||||
--星级
|
||||
PokemonManager.SetHeroStars(this.spLoader, this.starGrid, pokemonSData.MaxStar,2,Vector2.New(60,60))
|
||||
--属性
|
||||
|
@ -148,11 +138,14 @@ function this.NoGetShowPanelData()
|
|||
local skillBtn=Util.GetGameObject(skillList[i].transform,"bg/PokemonInfo/skill/icon")
|
||||
skillName.text=skills[i].Name
|
||||
skillIcon.sprite= this.spLoader:LoadSprite(GetResourcePath(skills[i].Icon))
|
||||
Util.AddOnceClick(skillIcon.gameObject, function()
|
||||
--UIManager.OpenPanel(UIName.PokemonSkillInfoPopup,pokemonSid,pokemonSData.MaxLevel,pokemonSData.MaxStar)
|
||||
local allSkillData=ConfigManager.GetAllConfigsDataByDoubleKey(ConfigName.ShenBingSkill,"SkillPanDuan",skills[i].SkillPanDuan,"SpiritAnimalMatch",skills[i].SpiritAnimalMatch)
|
||||
UIManager.OpenPanel(UIName.GodWeaponSkillInfoPopup,skills[i].Name,allSkillData)
|
||||
end)
|
||||
end
|
||||
|
||||
Util.AddOnceClick(this.skillBtn, function()
|
||||
UIManager.OpenPanel(UIName.PokemonSkillInfoPopup,pokemonSid,pokemonSData.MaxLevel,pokemonSData.MaxStar)
|
||||
end)
|
||||
|
||||
end
|
||||
|
||||
function this.ShowPokemonLive(_heroSConfigData)
|
||||
|
|
|
@ -239,9 +239,13 @@ function this.ShowSinglePokemonList(go,singleData,liveIndex)
|
|||
upZhenInfo:SetActive(true)
|
||||
local spiritAnimalConfig = ConfigManager.GetConfigData(ConfigName.ShenBing,curData.id)
|
||||
local parent = Util.GetGameObject(go, "upZhenInfo/titleImage")
|
||||
local starGrid=Util.GetGameObject(go, "upZhenInfo/starGrid")
|
||||
local starGrid=Util.GetGameObject(go, "upZhenInfo/starGrid/starGrid(Clone)")
|
||||
--starGrid.transform.posit=Vector2.New(-30,-30)
|
||||
--local starSize = Vector2.New(65,65)
|
||||
--SetHeroStars(this.spLoader,starGrid,curData.star,1,starSize)
|
||||
local starSize = Vector2.New(65,65)
|
||||
LogError("curData.star===="..curData.star)
|
||||
PokemonManager.SetHeroStars(this.spLoader, starGrid, curData.star,1,starSize)
|
||||
local nameText = Util.GetGameObject(parent, "nameText"):GetComponent("Text")
|
||||
nameText.text = GetStringByEquipQua(spiritAnimalConfig.Quality, GetLanguageStrById(spiritAnimalConfig.Name))
|
||||
local liveImg=Util.GetGameObject(go, "upZhenInfo/pokemonLive"):GetComponent("Image")
|
||||
|
|
|
@ -202,15 +202,20 @@ end
|
|||
|
||||
--碎片可以合成红点
|
||||
function this.WeaponChipCompoundRedPoint()
|
||||
local isOpen = ActTimeCtrlManager.SingleFuncState(FUNCTION_OPEN_TYPE.POKEMON)
|
||||
-- local isOpen = ActTimeCtrlManager.SingleFuncState(FUNCTION_OPEN_TYPE.POKEMON)
|
||||
-- if not isOpen then
|
||||
-- return false
|
||||
-- end
|
||||
local isOpen=CheckFunctionOpen(FUNCTION_OPEN_TYPE.GodWeapon)
|
||||
if not isOpen then
|
||||
return false
|
||||
LogError("神兵功能未开启-------------------")
|
||||
return false
|
||||
end
|
||||
local pokemonChipList = BagManager.GetDataByItemType(ItemType.GodWeaponChip)
|
||||
if #pokemonChipList > 0 then
|
||||
for i = 1, #pokemonChipList do
|
||||
if BagManager.GetItemCountById(pokemonChipList[i].id) >= itemConfig[pokemonChipList[i].id].UsePerCount then
|
||||
-- LogPink("碎片可以合成红点true")
|
||||
LogError("神兵碎片可以合成红点true")
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
@ -395,10 +400,13 @@ function this.CheckUpStarRedPoint(_curData)
|
|||
end
|
||||
--检测主城神兵红点
|
||||
function this.CheckGodWeaponRedPoint()
|
||||
LogError("====================================检测主城神兵红点")
|
||||
--检测可上阵
|
||||
local list=GodWeaponManager.GetCanUpZhenWeapons()
|
||||
if #list>0 then
|
||||
return true
|
||||
end
|
||||
--检测上阵可升级升星
|
||||
for key, value in pairs(godWeaponTeamInfo) do
|
||||
if value then
|
||||
if this.CheckUpLvRedPoint(value) or this.CheckUpStarRedPoint(value) then
|
||||
|
@ -406,10 +414,15 @@ function this.CheckGodWeaponRedPoint()
|
|||
end
|
||||
end
|
||||
end
|
||||
--检测可合成
|
||||
local isCanHe=this.WeaponChipCompoundRedPoint()
|
||||
if isCanHe then
|
||||
return true
|
||||
end
|
||||
local jiban=TianShuMiJuanManger.CheckRedPoint(5)
|
||||
if jiban then
|
||||
return true
|
||||
end
|
||||
return false
|
||||
end
|
||||
return this
|
|
@ -1359,6 +1359,7 @@ function this:OnShow()
|
|||
this.shenzunRedPoint:SetActive(BagManager.GetItemCountById(15)>=10)
|
||||
|
||||
--山河试炼红点
|
||||
CheckRedPointStatus(RedPointType.GodWeapon)
|
||||
CheckRedPointStatus(RedPointType.FightLevelTrial)
|
||||
CheckRedPointStatus(RedPointType.MingWangPri)
|
||||
CheckRedPointStatus(RedPointType.song10Wan)
|
||||
|
|
|
@ -358,7 +358,7 @@ function this.InitRedPointAllRelate()
|
|||
RPData:SetParent(RedPointType.eastSeaFindGod2,RedPointType.eastSeaFindGod)
|
||||
RPData:SetParent(RedPointType.eastSeaFindGod3,RedPointType.eastSeaFindGod)
|
||||
RPData:SetParent(RedPointType.eastSeaFindGod4,RedPointType.eastSeaFindGod)
|
||||
RPData:SetParent(RedPointType.Weapon_Fetter,RedPointType.GodWeapon)
|
||||
--RPData:SetParent(RedPointType.Weapon_Fetter,RedPointType.GodWeapon)
|
||||
for k,v in ConfigPairs(ConfigManager.GetConfig(ConfigName.ActivityGroups)) do
|
||||
if v.RpType > 0 and v.RpTypeParent > 0 then
|
||||
RPData:SetParent(v.RpType,v.RpTypeParent)
|
||||
|
|
|
@ -206,14 +206,14 @@ function GodsWayMyTeamPanel:SetSingleFormation(go,data,index)
|
|||
SetHeroIcon(self.spLoader,heroData,self.Heros[index][hero.position].icon,heroConfig)
|
||||
local heroData = {}
|
||||
Util.AddOnceClick(self.Heros[index][hero.position].icon.gameObject, function()
|
||||
--local heroData = HeroManager.GetSingleHeroData(hero.heroId)
|
||||
--UIManager.OpenPanel(UIName.RoleInfoPopup, heroData,false)
|
||||
NetManager.ViewHeroInfoRequest(PlayerManager.uid,heroTid,PlayerManager.serverInfo.name,2000+index,function(msg)
|
||||
local heroData = HeroManager.GetSingleHeroData(hero.heroId)
|
||||
UIManager.OpenPanel(UIName.RoleInfoPopup, heroData,false)
|
||||
-- NetManager.ViewHeroInfoRequest(PlayerManager.uid,heroTid,PlayerManager.serverInfo.name,2000+index,function(msg)
|
||||
|
||||
heroData= GoodFriendManager.GetHeroDatas(msg.hero,msg.force,msg.SpecialEffects,msg.guildSkill)
|
||||
GoodFriendManager.InitEquipData(msg.equip,heroData)--HeroManager.GetSingleHeroData(heroData.dynamicId)
|
||||
UIManager.OpenPanel(UIName.RoleInfoPopup, heroData,true)
|
||||
end)
|
||||
-- heroData= GoodFriendManager.GetHeroDatas(msg.hero,msg.force,msg.SpecialEffects,msg.guildSkill)
|
||||
-- GoodFriendManager.InitEquipData(msg.equip,heroData)--HeroManager.GetSingleHeroData(heroData.dynamicId)
|
||||
-- UIManager.OpenPanel(UIName.RoleInfoPopup, heroData,true)
|
||||
-- end)
|
||||
end)
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue