Merge branch 'master_develop' of http://60.1.1.230/gaoxin/JL_Client into master_develop

gaoxin 2020-11-11 15:31:10 +08:00
commit 14bab99f0e
29 changed files with 84557 additions and 16919 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -0,0 +1,88 @@
fileFormatVersion: 2
guid: db6fe3e950012f644b3aaf02debee77a
TextureImporter:
fileIDToRecycleName: {}
externalObjects: {}
serializedVersion: 9
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 2
aniso: -1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 1e8ceeecbb3628645ace881f744ae183
vertices: []
indices:
edges: []
weights: []
spritePackingTag: RoleInfoAtlas
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

View File

@ -0,0 +1,88 @@
fileFormatVersion: 2
guid: 10d9295a3b56eaf4da800dd332421ae1
TextureImporter:
fileIDToRecycleName: {}
externalObjects: {}
serializedVersion: 9
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 2
aniso: -1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 78425e5855f17be469b411087ff171af
vertices: []
indices:
edges: []
weights: []
spritePackingTag: RoleInfoAtlas
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 5.5 KiB

View File

@ -32243,7 +32243,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &2457012460713235842
RectTransform:
m_ObjectHideFlags: 0
@ -63553,6 +63553,11 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 5269011775435973205}
m_Modifications:
- target: {fileID: 4040402500520929852, guid: caa674551693c3c43937202ed26254b6,
type: 3}
propertyPath: m_Name
value: live2d_c_swk_00015_s1
objectReference: {fileID: 0}
- target: {fileID: 3404555805505803963, guid: caa674551693c3c43937202ed26254b6,
type: 3}
propertyPath: m_LocalPosition.x
@ -63673,11 +63678,6 @@ PrefabInstance:
propertyPath: m_LocalScale.z
value: 0.7
objectReference: {fileID: 0}
- target: {fileID: 4040402500520929852, guid: caa674551693c3c43937202ed26254b6,
type: 3}
propertyPath: m_Name
value: live2d_c_swk_00015_s1
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: caa674551693c3c43937202ed26254b6, type: 3}
--- !u!224 &2063543484280785985 stripped
@ -63909,6 +63909,11 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 6292815448464137924}
m_Modifications:
- target: {fileID: 8738943556520059787, guid: d84e4645d382bd244899351e6efacbc8,
type: 3}
propertyPath: m_Name
value: DynamicActivityPanel_dakai
objectReference: {fileID: 0}
- target: {fileID: 684639772055139411, guid: d84e4645d382bd244899351e6efacbc8,
type: 3}
propertyPath: m_LocalPosition.x
@ -63964,11 +63969,6 @@ PrefabInstance:
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8738943556520059787, guid: d84e4645d382bd244899351e6efacbc8,
type: 3}
propertyPath: m_Name
value: DynamicActivityPanel_dakai
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: d84e4645d382bd244899351e6efacbc8, type: 3}
--- !u!4 &5536667510165372974 stripped
@ -63984,6 +63984,11 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 4364234898477055512}
m_Modifications:
- target: {fileID: 8096286917689290514, guid: 385d5e664702ab74aa985d27de27bb19,
type: 3}
propertyPath: m_Name
value: Effect_UI_changjing_qiankuanbaoguo
objectReference: {fileID: 0}
- target: {fileID: 2626320712165749272, guid: 385d5e664702ab74aa985d27de27bb19,
type: 3}
propertyPath: m_LocalPosition.x
@ -64039,11 +64044,6 @@ PrefabInstance:
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8096286917689290514, guid: 385d5e664702ab74aa985d27de27bb19,
type: 3}
propertyPath: m_Name
value: Effect_UI_changjing_qiankuanbaoguo
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 385d5e664702ab74aa985d27de27bb19, type: 3}
--- !u!4 &5379899409067946649 stripped
@ -64059,6 +64059,16 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 7319957226166616999}
m_Modifications:
- target: {fileID: 3774195657356619162, guid: 5daa3a0ddb216d14093aa7cd11574675,
type: 3}
propertyPath: m_Name
value: UI_Effect_BaoXiang_KeKaiQi
objectReference: {fileID: 0}
- target: {fileID: 3774195657356619162, guid: 5daa3a0ddb216d14093aa7cd11574675,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 6473444402870397754, guid: 5daa3a0ddb216d14093aa7cd11574675,
type: 3}
propertyPath: m_LocalPosition.x
@ -64164,16 +64174,6 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 3774195657356619162, guid: 5daa3a0ddb216d14093aa7cd11574675,
type: 3}
propertyPath: m_Name
value: UI_Effect_BaoXiang_KeKaiQi
objectReference: {fileID: 0}
- target: {fileID: 3774195657356619162, guid: 5daa3a0ddb216d14093aa7cd11574675,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 5daa3a0ddb216d14093aa7cd11574675, type: 3}
--- !u!224 &3110801484483406645 stripped

View File

@ -4554,7 +4554,7 @@ ParticleSystem:
--- !u!199 &199787422305027156
ParticleSystemRenderer:
serializedVersion: 6
m_ObjectHideFlags: 0
m_ObjectHideFlags: 2
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
@ -9203,7 +9203,7 @@ ParticleSystem:
--- !u!199 &199651780022285358
ParticleSystemRenderer:
serializedVersion: 6
m_ObjectHideFlags: 0
m_ObjectHideFlags: 2
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
@ -20266,7 +20266,7 @@ RectTransform:
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
@ -20778,6 +20778,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -20813,7 +20818,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
@ -20943,6 +20948,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -20978,7 +20988,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
@ -21108,6 +21118,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -21143,7 +21158,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
@ -21273,6 +21288,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -21308,7 +21328,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
@ -21438,6 +21458,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -21473,7 +21498,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
@ -21603,6 +21628,11 @@ PrefabInstance:
propertyPath: m_Pivot.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2320031818794305969, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_AnchoredPosition.y
@ -21638,7 +21668,7 @@ PrefabInstance:
propertyPath: m_AnchoredPosition.y
value: 3.2600002
objectReference: {fileID: 0}
- target: {fileID: 2320031819680067764, guid: e356d5948e4971f499cfe38db3551f59,
- target: {fileID: 2320031819916146514, guid: e356d5948e4971f499cfe38db3551f59,
type: 3}
propertyPath: m_IsActive
value: 0

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 8e7c35c98345a4946b9b2a1d2f92a573
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 6fdbc06502e2f3943ae668768cfe612a
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -1060,7 +1060,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &2853265494666372061
RectTransform:
m_ObjectHideFlags: 0
@ -1616,7 +1616,7 @@ MonoBehaviour:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4041547246533256848}
m_Enabled: 1
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3}
m_Name:
@ -1971,8 +1971,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: 51, y: 55}
m_AnchoredPosition: {x: 0, y: -10.5}
m_SizeDelta: {x: 60, y: 57}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &6987409428865215157
CanvasRenderer:
@ -2002,7 +2002,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: abae95ba31b5b5a4fa83a82d0c56db63, type: 3}
m_Sprite: {fileID: 21300000, guid: b96ce91822621be4b824b0b7f9504f92, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
@ -2178,7 +2178,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &9016431241116717463
RectTransform:
m_ObjectHideFlags: 0

View File

@ -1296,6 +1296,7 @@ FUNCTION_OPEN_TYPE = {
COMPOUND_HERO=78,--神将合成、置换
POKEMON=79,--灵兽山
XiaoYaoYou = 80, -- 逍遥游
RoleAwake = 81, -- 神将觉醒
}
TaskGetBtnIconDef = {

View File

@ -746,7 +746,7 @@ function GetQuantityImageByquality(quality,star)
elseif star >= 6 and star <=10 then
return "r_characterbg_gules"
elseif star > 10 then
return "r_characterbg_gules"
return "t_tongyong_topkaung"
end
else
if quality == 0 or quality == 1 then
@ -841,7 +841,7 @@ function GetHeroQuantityImageByquality(quality,star)
elseif star >= 6 and star <=10 then
return "r_characterbg_gules"
elseif star > 10 then
return "r_characterbg_gules"
return "t_tongyong_topkaung"
end
else
if quality == 0 or quality == 1 then

View File

@ -355,6 +355,8 @@ UIName = {
PokemonSingleResultPanel=354,--灵兽
GeneralRewardPopup = 355,--通用奖励领取弹窗
GeneralBigPopup = 357,--通用大弹窗界面
RoleAwakeTalentPopup = 358,--通用大弹窗界面
RoleAwakeSuccessPanel = 359,--通用大弹窗界面
}
SubUIConfig = {

View File

@ -287,21 +287,21 @@ function this.ExecuteBehavior(beType, beArgs)
local startFunc
local endFunc
local timePressStarted
_trigger.onPointerDown = _trigger.onPointerDown + RoleInfoPanel._onPointerDown
_trigger.onPointerDown = _trigger.onPointerDown + RoleInfoPanel.PageList[1]._onPointerDown
startFunc = function()
timePressStarted = Time.realtimeSinceStartup
end
_trigger.onPointerDown = _trigger.onPointerDown + startFunc
_trigger.onPointerUp = _trigger.onPointerUp + RoleInfoPanel._onPointerUp
_trigger.onPointerUp = _trigger.onPointerUp + RoleInfoPanel.PageList[1]._onPointerUp
endFunc = function()
_trigger.onPointerDown = _trigger.onPointerDown - RoleInfoPanel._onPointerDown
_trigger.onPointerDown = _trigger.onPointerDown - RoleInfoPanel.PageList[1]._onPointerDown
_trigger.onPointerDown = _trigger.onPointerDown - startFunc
_trigger.onPointerUp = _trigger.onPointerUp - RoleInfoPanel._onPointerUp
_trigger.onPointerUp = _trigger.onPointerUp - RoleInfoPanel.PageList[1]._onPointerUp
_trigger.onPointerUp = _trigger.onPointerUp - endFunc
-- 长按时间小于4秒
if Time.realtimeSinceStartup - timePressStarted <= 0.4 then
RoleInfoPanel.timePressStarted = timePressStarted
RoleInfoPanel.PageList[1].timePressStarted = timePressStarted
local btn = Util.GetGameObject(UIManager.uiNode, beArgs):GetComponent("Button")
btn.onClick:Invoke()
end
@ -311,7 +311,7 @@ function this.ExecuteBehavior(beType, beArgs)
Util.AddClick(this.button, this.NextGuide)
end
_trigger.onPointerUp = _trigger.onPointerUp + endFunc
this.SetBtnGOPosition(RoleInfoPanel.upLvTrigger.gameObject:GetComponent("RectTransform").position)
this.SetBtnGOPosition(RoleInfoPanel.PageList[1].upLvTrigger.gameObject:GetComponent("RectTransform").position)
elseif beType == 9 then --关联上阵成员界面对应名字的预设
local item = RoleListPanel.GetRoleItemByName(beArgs)
if item then
@ -329,10 +329,10 @@ function this.ExecuteBehavior(beType, beArgs)
this.SetBtnGOPosition(item.gameObject:GetComponent("RectTransform").position)
end
elseif beType == 10 then --连续升级后突破
local btn = RoleInfoPanel.upLvBtn:GetComponent("Button")
local btn = RoleInfoPanel.PageList[1].upLvBtn:GetComponent("Button")
this.button:GetComponent("Button").onClick:RemoveAllListeners()
Util.AddClick(this.button, function()
RoleInfoPanel:LvUpClick(true)
RoleInfoPanel.PageList[1]:LvUpClick(true)
this.NextGuide()
this.button:GetComponent("Button").onClick:RemoveAllListeners()
Util.AddClick(this.button, this.NextGuide)

View File

@ -116,6 +116,7 @@ end
function HandBookHeroAndEquipListPanel:GetHeroData()
--得到所有的对应星级的英雄
local elevenHeroList = {}
local tenHeroList = {}
local sexHeroList = {}
local fiveHeroList = {}
@ -127,6 +128,9 @@ function HandBookHeroAndEquipListPanel:GetHeroData()
--5星最高星级是10的要在十星里面显示出来
if v.Star == 5 and v.MaxRank >= 10 and (proId == 0 or v.PropertyName == proId) then
table.insert(tenHeroList,v)
if v.MaxRank >= 11 and ActTimeCtrlManager.SingleFuncState(FUNCTION_OPEN_TYPE.RoleAwake) then
table.insert(elevenHeroList,v)
end
end
--所有的5星都要在六星里面显示出来
if v.Star == 5 and (proId == 0 or v.PropertyName == proId) then
@ -142,6 +146,7 @@ function HandBookHeroAndEquipListPanel:GetHeroData()
table.insert(oneHeroList,v)
end
end
self:SortHeroNatural(elevenHeroList)
self:SortHeroNatural(tenHeroList)
self:SortHeroNatural(sexHeroList)
self:SortHeroNatural(fiveHeroList)
@ -151,6 +156,7 @@ function HandBookHeroAndEquipListPanel:GetHeroData()
self:SortHeroNatural(oneHeroList)
--设置图鉴的循环列表
local herodatas={}
herodatas[11]=elevenHeroList
herodatas[10]=tenHeroList
herodatas[6]=sexHeroList
herodatas[5]=fiveHeroList
@ -209,6 +215,7 @@ function HandBookHeroAndEquipListPanel:GetHeroData()
end
function HandBookHeroAndEquipListPanel:HeroHaveNum()
local curelevenStarActiveNum = 0
local curtenStarActiveNum = 0
local cursexStarActiveNum = 0
local curfiveStarActiveNum = 0
@ -219,7 +226,10 @@ function HandBookHeroAndEquipListPanel:HeroHaveNum()
--计算玩家拥有的英雄中对应星级的英雄的数量
for i, v in pairs(PlayerManager.heroHandBook) do
local conFig = ConfigManager.GetConfigData(ConfigName.HeroConfig,i)
if conFig then
if conFig then
if PlayerManager.GetHeroDataByStar(11,conFig.Id) and (proId == 0 or conFig.PropertyName == proId) then
curelevenStarActiveNum = curelevenStarActiveNum + 1
end
if PlayerManager.GetHeroDataByStar(10,conFig.Id) and (proId == 0 or conFig.PropertyName == proId) then
curtenStarActiveNum = curtenStarActiveNum + 1
end
@ -246,6 +256,7 @@ function HandBookHeroAndEquipListPanel:HeroHaveNum()
heroNumList[5] = curfiveStarActiveNum
heroNumList[6] = cursexStarActiveNum
heroNumList[10] = curtenStarActiveNum
heroNumList[11] = curelevenStarActiveNum
end
--英雄展示
@ -315,6 +326,8 @@ function HandBookHeroAndEquipListPanel:OnShowSingleHeroData(...)
lv = 145
elseif star == 10 then
lv = 155
elseif star == 11 then
lv = 330
else
lv = 1
end

View File

@ -312,7 +312,7 @@ function HandBookHeroInfoPanel:CalculateHeroAllProValList(_starType,_starNum)
for i, v in ConfigPairs(propertyConfig) do
allAddProVal[i] = 0
end
local heroRankupConfig = ConfigManager.GetConfigDataByDoubleKey(ConfigName.HeroRankupConfig, "Star", heroConFigData.Star, "LimitStar", _starNum)
local heroRankupConfig = ConfigManager.GetConfigDataByDoubleKey(ConfigName.HeroRankupConfig, "Star", heroConFigData.Star, "OpenStar", _starNum)
local curLvNum=1
local breakId = 0
local upStarId = 0
@ -387,7 +387,7 @@ function HandBookHeroInfoPanel:UpdateLiveList()
leftIndex = index - 1
leftHeroData=heroDatas[leftIndex]
else
if _curStar==10 then
if _curStar==11 then
_leftStar = 1
elseif _curStar==6 then
_leftStar = 10
@ -406,7 +406,7 @@ function HandBookHeroInfoPanel:UpdateLiveList()
if _curStar==10 then
_rightStar = 6
elseif _curStar==1 then
_rightStar = 10
_rightStar = 11
else
_rightStar = _curStar - 1
end

View File

@ -41,6 +41,9 @@ this.heroResolveLicence = {}
--this.lvProVal = {}--单体等级限制加成
--this.allHeroProVal = {}--团体加成
--this.specialProVal = {}--减乘
this.awakeStarIndex = 10-- 前端写死觉醒星级标志
this.awakeNextStarIndex = 11-- 前端写死觉醒星级标志
function this.Initialize()
for i = 1, WarPowerTypeAllNum do
this.allProVal[i] = {
@ -568,11 +571,12 @@ function this.UpdateSingleHeroSkillData(_heroDId)
end
heroData.passiveSkillList = {}
--被动技
if heroData.heroConfig.OpenPassiveSkillRules then
for i = 1, #heroData.heroConfig.OpenPassiveSkillRules do
if heroData.heroConfig.OpenPassiveSkillRules[i][1] == heroData.star then
local OpenPassiveSkillRules = heroData.star == this.awakeNextStarIndex and heroData.heroConfig.Awaken or heroData.heroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
for i = 1, #OpenPassiveSkillRules do
if OpenPassiveSkillRules[i][1] == heroData.star then
local heroSkill = {}
heroSkill.skillId = heroData.heroConfig.OpenPassiveSkillRules[i][2]
heroSkill.skillId = OpenPassiveSkillRules[i][2]
heroSkill.skillConfig = passiveSkillConfig[heroSkill.skillId]
table.insert(heroData.passiveSkillList, heroSkill)
end
@ -2250,11 +2254,12 @@ function this.GetCurHeroSidAndCurStarAllSkillDatas(sid, star)
end
end
end
if curHeroConfig.OpenPassiveSkillRules then
for i = 1, #curHeroConfig.OpenPassiveSkillRules do
if curHeroConfig.OpenPassiveSkillRules[i][1] == star then
local OpenPassiveSkillRules = star == this.awakeNextStarIndex and curHeroConfig.Awaken or curHeroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
for i = 1, #OpenPassiveSkillRules do
if OpenPassiveSkillRules[i][1] == star then
local heroSkill = {}
heroSkill.skillId = curHeroConfig.OpenPassiveSkillRules[i][2]
heroSkill.skillId = OpenPassiveSkillRules[i][2]
heroSkill.skillConfig = passiveSkillConfig[heroSkill.skillId]
allSkillDatas[skillIndex] = heroSkill
skillIndex = skillIndex + 1
@ -2534,19 +2539,20 @@ end
--更新英雄被动技能
function this.UpdatePassiveHeroSkill(heroData)
heroData.passiveSkillList = {} --被动技
if heroData.heroConfig.OpenPassiveSkillRules then
for i = 1, #heroData.heroConfig.OpenPassiveSkillRules do
if heroData.heroConfig.OpenPassiveSkillRules[i][1] == 1 then --突破
if heroData.breakId >= heroData.heroConfig.OpenPassiveSkillRules[i][2] then
local OpenPassiveSkillRules = heroData.star == this.awakeNextStarIndex and heroData.heroConfig.Awaken or heroData.heroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
for i = 1, #OpenPassiveSkillRules do
if OpenPassiveSkillRules[i][1] == 1 then --突破
if heroData.breakId >= OpenPassiveSkillRules[i][2] then
local heroSkill = {}
heroSkill.skillId = heroData.heroConfig.OpenPassiveSkillRules[i][3]
heroSkill.skillId = OpenPassiveSkillRules[i][3]
heroSkill.skillConfig = passiveSkillConfig[heroSkill.skillId]
table.insert(heroData.passiveSkillList, heroSkill)
end
else --升星
if heroData.upStarId >= heroData.heroConfig.OpenPassiveSkillRules[i][2] then
if heroData.upStarId >= OpenPassiveSkillRules[i][2] then
local heroSkill = {}
heroSkill.skillId = heroData.heroConfig.OpenPassiveSkillRules[i][3]
heroSkill.skillId = OpenPassiveSkillRules[i][3]
heroSkill.skillConfig = passiveSkillConfig[heroSkill.skillId]
table.insert(heroData.passiveSkillList, heroSkill)
end
@ -2585,37 +2591,38 @@ function this.GetAllPassiveSkillIds(heroConfig, breakId, upStarId)
--只用于界面升星开放技能提示显示用
local compoundNum = 0
local compoundOPenNum = 0
if heroConfig.OpenPassiveSkillRules then
for i = 1, #heroConfig.OpenPassiveSkillRules do
if heroConfig.OpenPassiveSkillRules[i][1] == 1 then --突破
if breakId >= heroConfig.OpenPassiveSkillRules[i][2] then
-- local openPassiveSkillRules = allPassiveSkillIds,heroConfig.OpenPassiveSkillRules
table.insert(allPassiveSkillIds, heroConfig.OpenPassiveSkillRules[i][3])
if allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] then
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] =
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] + 1
local OpenPassiveSkillRules = (upStarId and upStarId ~=0 and heroRankUpConfig[upStarId].OpenStar == this.awakeNextStarIndex) and heroConfig.Awaken or heroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
for i = 1, #OpenPassiveSkillRules do
if OpenPassiveSkillRules[i][1] == 1 then --突破
if breakId >= OpenPassiveSkillRules[i][2] then
-- local openPassiveSkillRules = allPassiveSkillIds,OpenPassiveSkillRules
table.insert(allPassiveSkillIds, OpenPassiveSkillRules[i][3])
if allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] then
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] =
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] + 1
else
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] = 1
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] = 1
end
end
else --升星
allUpStarOpenData[heroRankUpConfig[heroConfig.OpenPassiveSkillRules[i][2]].Phase[2]] =
heroConfig.OpenPassiveSkillRules[i]
if upStarId >= heroConfig.OpenPassiveSkillRules[i][2] then
table.insert(allPassiveSkillIds, heroConfig.OpenPassiveSkillRules[i][3])
if allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] then
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] =
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] + 1
allUpStarOpenData[heroRankUpConfig[OpenPassiveSkillRules[i][2]].Phase[2]] =
OpenPassiveSkillRules[i]
if upStarId >= OpenPassiveSkillRules[i][2] then
table.insert(allPassiveSkillIds, OpenPassiveSkillRules[i][3])
if allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] then
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] =
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] + 1
else
allOpenPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] = 1
allOpenPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] = 1
end
end
end
if allPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] then
allPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] =
allPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] + 1
if allPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] then
allPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] =
allPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] + 1
else
allPassiveSkillIdcompound[heroConfig.OpenPassiveSkillRules[i][2]] = 1
allPassiveSkillIdcompound[OpenPassiveSkillRules[i][2]] = 1
end
end
end
@ -2639,7 +2646,7 @@ function this.GetHeroAllPassiveSkillIds(curHeroData)
end
--英雄天赋被动技
if curHeroData.heroConfig.OpenPassiveSkillRules then
local openPassiveSkillRules = curHeroData.heroConfig.OpenPassiveSkillRules
local openPassiveSkillRules = curHeroData.star == this.awakeNextStarIndex and curHeroData.heroConfig.Awaken or curHeroData.heroConfig.OpenPassiveSkillRules
for i = 1, #openPassiveSkillRules do
local skillType = openPassiveSkillRules[i][1]
local skillRanUpId = openPassiveSkillRules[i][2]

View File

@ -0,0 +1,395 @@
require("Base/BasePanel")
this = Inherit(BasePanel)
local this = this
local itemConfig = ConfigManager.GetConfig(ConfigName.ItemConfig)
local heroRankupConfig = ConfigManager.GetConfig(ConfigName.HeroRankupConfig)
local propertyConfig = ConfigManager.GetConfig(ConfigName.PropertyConfig)
local heroSkinConfig = ConfigManager.GetConfig(ConfigName.HeroSkin)
local isUpStarMaterials=true--升星 材料是否充足
local curSelectUpStarData--当前选择升星坑位的数据
local curSelectUpStarGo--当前选择升星坑位的预设
local upStarConsumeMaterial={}--升星消耗的英雄组 {{1坑位英雄信息}{2坑位英雄信息}{}}
local upStarMaterialIsAll={}--升星消耗的英雄组是否满足 {{1满足}{2不满足}{}}
local isHeroUpStar=false--是否可升星
local upStarRankUpConfig={}--即将要升星的数据
local curStarRankUpConfig={}--当前升星的数据
local curHeroData--当前英雄信息
local parent = {}
local upStarPreList = {}
local heroDatas = {}
local isUpZhen = false
--初始化组件(用于子类重写)
function this:InitComponent(gameObject)
this.gameObject = gameObject
Util.GetGameObject(this.gameObject,"Image/Text"):GetComponent("Text").text = "神将觉醒"
Util.GetGameObject(this.gameObject,"Image (3)/Text"):GetComponent("Text").text = "觉醒要求"
Util.GetGameObject(this.gameObject,"tip"):GetComponent("Text").text = "觉醒后神将天赋会发生变化"
Util.GetGameObject(this.gameObject,"upStarBtn/Text"):GetComponent("Text").text = "觉 醒"
Util.GetGameObject(this.gameObject,"lvUp/Text"):GetComponent("Text").text = "等级上限:"
--天赋
this.talent1Image = Util.GetGameObject(this.gameObject,"talent/talent (1)"):GetComponent("Image")
this.talent1Progress = Util.GetGameObject(this.gameObject,"talent/talent (1)/progress"):GetComponent("Text")
this.talent2Image = Util.GetGameObject(this.gameObject,"talent/talent (2)"):GetComponent("Image")
this.talent2Progress = Util.GetGameObject(this.gameObject,"talent/talent (2)/progress"):GetComponent("Text")
this.talentBtn = Util.GetGameObject(this.gameObject,"talent/talentBtn")
this.curLvEnd = Util.GetGameObject(this.gameObject,"lvUp/curLvEnd"):GetComponent("Text")
this.nextLvEnd = Util.GetGameObject(this.gameObject,"lvUp/nextLvEnd"):GetComponent("Text")
--升星觉醒
this.upStarPre=Util.GetGameObject(this.gameObject,"upStarPre")
this.upStarGrid=Util.GetGameObject(this.gameObject,"grid")
this.upStarBtnRedPoint=Util.GetGameObject(this.gameObject,"upStarBtn/redPoint")
this.goldBtn=Util.GetGameObject(this.gameObject,"goldGrid/gold")
this.goldText=Util.GetGameObject(this.gameObject,"goldGrid/gold/Text"):GetComponent("Text")
this.goldImage=Util.GetGameObject(this.gameObject,"goldGrid/gold")
this.gold2Btn=Util.GetGameObject(this.gameObject,"goldGrid/gold2")
this.gold2Text=Util.GetGameObject(this.gameObject,"goldGrid/gold2/Text"):GetComponent("Text")
this.gold2Image=Util.GetGameObject(this.gameObject,"goldGrid/gold2")
this.upStarBtn=Util.GetGameObject(this.gameObject,"upStarBtn")
return this
end
--绑定事件(用于子类重写)
function this:BindEvent()
--升星
Util.AddClick(this.upStarBtn, function()
this.StarUpClick()
end)
end
--添加事件监听(用于子类重写)
function this:AddListener()
Game.GlobalEvent:AddEvent(GameEvent.Bag.BagGold, this.UpdateHeroUpStarMaterialShow)
end
--移除事件监听(用于子类重写)
function this:RemoveListener()
Game.GlobalEvent:RemoveEvent(GameEvent.Bag.BagGold,this.UpdateHeroUpStarMaterialShow)
end
function this:OnShow(_sortinglayer,_parent,_curHerodata,_isUpZhen,_heroDatas)
this.gameObject:SetActive(true)
this.sortingOrder = _sortinglayer
curHeroData = _curHerodata
parent = _parent
heroDatas = _heroDatas
isUpZhen = _isUpZhen
this.GetCurHeroUpLvOrUpStarSData()
this.UpdateHeroUpStarData()--进阶
end
--更新英雄进阶数据
function this.UpdateHeroUpStarData()
--进阶材料
this.UpdateHeroUpStarMaterialShow()
--进阶属性提升
this.curLvEnd.text= HeroManager.GetCurHeroStarLvEnd(1,curHeroData)
this.nextLvEnd.text= HeroManager.GetCurHeroStarLvEnd(2,curHeroData,curHeroData.breakId,upStarRankUpConfig.Id)
local OpenPassiveSkillRules = curHeroData.star == HeroManager.awakeNextStarIndex and curHeroData.heroConfig.Awaken or curHeroData.heroConfig.OpenPassiveSkillRules
local openlists,compoundOpenNum,compoundNum,allUpStarOpenData = HeroManager.GetAllPassiveSkillIds(curHeroData.heroConfig,curHeroData.breakId,curHeroData.upStarId)
this.talent1Progress.text = #openlists - compoundOpenNum .."/"..#OpenPassiveSkillRules - compoundNum
this.talent2Progress.text = #openlists - compoundOpenNum .."/"..#OpenPassiveSkillRules - compoundNum
Util.AddOnceClick(this.talentBtn, function()
UIManager.OpenPanel(UIName.RoleAwakeTalentPopup,curHeroData.heroConfig)
end)
--进阶吞英雄条件
Util.ClearChild(this.upStarGrid.transform)
local curUpStarData= HeroManager.GetHeroCurUpStarInfo(curHeroData.dynamicId)
if curUpStarData and #curUpStarData>0 then
upStarConsumeMaterial={}
upStarMaterialIsAll = {}
upStarPreList = {}
for i = 1, #curUpStarData do
local go=newObject(this.upStarPre)
go.transform:SetParent(this.upStarGrid.transform)
go.transform.localScale = Vector3.one
go.transform.localPosition=Vector3.zero;
go:SetActive(true)
go.transform.name = "upStarPre"..i
upStarPreList[i] = go
upStarConsumeMaterial[i]={}
upStarMaterialIsAll[i]=2
Util.GetGameObject(go.transform, "iconbg/proImage"):SetActive(false)
if curUpStarData[i].upStarMaterialsData.Issame==1 or curUpStarData[i].upStarMaterialsData.IsId>0 then
Util.GetGameObject(go.transform,"iconDefault"):SetActive(false)
Util.GetGameObject(go.transform,"icon"):SetActive(true)
Util.GetGameObject(go.transform, "iconbg/proImage"):SetActive(true)
Util.GetGameObject(go.transform, "iconbg/proImage"):GetComponent("Image").sprite=Util.LoadSprite(GetProStrImageByProNum(curHeroData.heroConfig.PropertyName))
if curUpStarData[i].upStarMaterialsData.Issame==1 then
Util.GetGameObject(go.transform,"icon"):GetComponent("Image").sprite=Util.LoadSprite(GetResourcePath(curHeroData.heroConfig.Icon))
Util.GetGameObject(go.transform,"frame"):GetComponent("Image").sprite=Util.LoadSprite(GetHeroQuantityImageByquality(curHeroData.heroConfig.Quality, curUpStarData[i].upStarMaterialsData.StarLimit))
Util.GetGameObject(go.transform, "iconbg/proImage"):GetComponent("Image").sprite=Util.LoadSprite(GetProStrImageByProNum(curHeroData.heroConfig.PropertyName))
elseif curUpStarData[i].upStarMaterialsData.IsId>0 then
local heroConfig = ConfigManager.GetConfigData(ConfigName.HeroConfig, curUpStarData[i].upStarMaterialsData.IsId)
Util.GetGameObject(go.transform,"icon"):GetComponent("Image").sprite=Util.LoadSprite(GetResourcePath(heroConfig.Icon))
Util.GetGameObject(go.transform,"frame"):GetComponent("Image").sprite=Util.LoadSprite(GetHeroQuantityImageByquality(heroConfig.Quality, curUpStarData[i].upStarMaterialsData.StarLimit))
Util.GetGameObject(go.transform, "iconbg/proImage"):GetComponent("Image").sprite=Util.LoadSprite(GetProStrImageByProNum(heroConfig.PropertyName))
end
else
if curUpStarData[i].upStarMaterialsData.IsSameClan ==1 then
Util.GetGameObject(go.transform, "iconbg/proImage"):SetActive(true)
Util.GetGameObject(go.transform, "iconbg/proImage"):GetComponent("Image").sprite=Util.LoadSprite(GetProStrImageByProNum(curHeroData.heroConfig.PropertyName))
end
Util.GetGameObject(go.transform,"iconDefault"):SetActive(true)
Util.GetGameObject(go.transform,"icon"):SetActive(false)
Util.GetGameObject(go.transform,"frame"):GetComponent("Image").sprite=Util.LoadSprite(GetHeroQuantityImageByquality(nil,curUpStarData[i].upStarMaterialsData.StarLimit))
end
local upStarHeroListData=HeroManager.GetUpStarHeroListData(curUpStarData[i].upStarMaterialsData.Id,curHeroData)
if upStarHeroListData.state>0 then
Util.GetGameObject(go.transform,"add/add"):SetActive(true)
else
Util.GetGameObject(go.transform,"add/add"):SetActive(false)
end
Util.GetGameObject(go.transform,"num"):GetComponent("Text").text=string.format("<color=#FF0000FF>%s/%s</color>",0,curUpStarData[i].upStarData[4])
SetHeroStars(Util.GetGameObject(go.transform, "iconbg/starGrid"), curUpStarData[i].upStarMaterialsData.StarLimit,1,nil,-15.3)
local addBtn=Util.GetGameObject(go.transform,"add")
Util.AddOnceClick(addBtn, function()
curSelectUpStarData=curUpStarData[i]
curSelectUpStarGo=go
local curShowHeroListData=this.SetShowHeroListData(upStarConsumeMaterial,upStarHeroListData.heroList)
--参数1 显示的herolist 2 3 升当前星的规则 4 打开RoleUpStarListPanel的界面
UIManager.OpenPanel(UIName.RoleUpStarListPanel,curShowHeroListData,curUpStarData[i].upStarMaterialsData,curUpStarData[i].upStarData,this,upStarConsumeMaterial[i],curHeroData)
end)
end
end
this.AutoSelectUpStarHeroList(curUpStarData)
end
--获取当前英雄的下一突破 和 升星 静态数据
function this.GetCurHeroUpLvOrUpStarSData()
isHeroUpStar = false
upStarRankUpConfig = {}
local heroRankUpConfig = ConfigManager.GetConfig(ConfigName.HeroRankupConfig)
for i, v in ConfigPairs(heroRankUpConfig) do
if v.Star==curHeroData.heroConfig.Star then--初始星级相等
if v.Show==2 then -- 2 升星
if v.Id ~= curHeroData.upStarId and curHeroData.star == v.LimitStar then
--Log("升星 "..v.Id)
upStarRankUpConfig=v
isHeroUpStar = true
end
end
end
end
end
--更新英雄进阶材料显示
function this.UpdateHeroUpStarMaterialShow()
--进阶金币 妖壶条件
if upStarRankUpConfig then
isUpStarMaterials=true
local ConsumeMaterial=upStarRankUpConfig.ConsumeMaterial
if ConsumeMaterial and #ConsumeMaterial>=2 then
if ConsumeMaterial[1][2]>0 then
this.goldImage:SetActive(true)
this.goldImage:GetComponent("Image").sprite = Util.LoadSprite(GetResourcePath(itemConfig[ConsumeMaterial[1][1]].ResourceID))
if BagManager.GetItemCountById(ConsumeMaterial[1][1])<ConsumeMaterial[1][2] then
isUpStarMaterials=false
this.goldText.text=string.format("<color=#FF0000FF>%s</color>",ConsumeMaterial[1][2])
else
this.goldText.text=string.format("<color=#FFFFFFFF>%s</color>",ConsumeMaterial[1][2])
end
Util.AddOnceClick(this.goldBtn,function()
UIManager.OpenPanel(UIName.RewardItemSingleShowPopup,ConsumeMaterial[1][1])
end)
else
this.goldImage:SetActive(false)
end
if ConsumeMaterial[2][2]>0 then
this.gold2Image:SetActive(true)
this.gold2Image:GetComponent("Image").sprite = Util.LoadSprite(GetResourcePath(itemConfig[ConsumeMaterial[2][1]].ResourceID))
if BagManager.GetItemCountById(ConsumeMaterial[2][1])<ConsumeMaterial[2][2] then
isUpStarMaterials=false
this.gold2Text.text=string.format("<color=#FF0000FF>%s</color>",ConsumeMaterial[2][2])
else
this.gold2Text.text=string.format("<color=#FFFFFFFF>%s</color>",ConsumeMaterial[2][2])
end
Util.AddOnceClick(this.gold2Btn,function()
UIManager.OpenPanel(UIName.RewardItemSingleShowPopup,ConsumeMaterial[2][1])
end)
else
this.gold2Image:SetActive(false)
end
end
end
end
--升星选择祭品后刷新界面
function this.AutoSelectUpStarHeroList(_curUpStarData)
local curUpStarData= _curUpStarData
if curUpStarData and #curUpStarData>0 then
for i = 1, #curUpStarData do
curSelectUpStarData=curUpStarData[i]
curSelectUpStarGo=upStarPreList[i]
local upStarHeroListData=HeroManager.GetUpStarHeroListData(curUpStarData[i].upStarMaterialsData.Id,curHeroData)
local curSelectHeroList = {}
if curUpStarData[i].upStarMaterialsData.Issame ==1
or curUpStarData[i].upStarMaterialsData.IsId > 0
or (curUpStarData[i].upStarMaterialsData.IsSameClan == 1
and curUpStarData[i].upStarMaterialsData.StarLimit == 3
and curHeroData.heroConfig.Qualiy ~= 3) then
if LengthOfTable(upStarHeroListData.heroList) >= curUpStarData[i].upStarData[4] then
for i = 1, curUpStarData[i].upStarData[4] do
if upStarHeroListData.heroList[i].lockState == 0 and upStarHeroListData.heroList[i].isFormation == "" then
table.insert(curSelectHeroList,upStarHeroListData.heroList[i])
end
end
this:UpdateUpStarPosHeroData(curSelectHeroList)
end
end
end
end
--进阶红点
local upStarRedPointState = HeroManager.IsShowUpStarRedPoint(curHeroData)
this.upStarBtnRedPoint:SetActive(upStarRedPointState)
parent:CheckRedPointType(2,upStarRedPointState)
end
--刷新当前升星坑位英雄的信息
function this:UpdateUpStarPosHeroData(curSelectHeroList)
if LengthOfTable(curSelectHeroList)<curSelectUpStarData.upStarData[4] then
upStarMaterialIsAll[curSelectUpStarData.upStarData[2]]=2
Util.GetGameObject(curSelectUpStarGo.transform,"add/add"):SetActive(true)
local upStarHeroListData=HeroManager.GetUpStarHeroListData(curSelectUpStarData.upStarMaterialsData.Id,curHeroData)
if upStarHeroListData.state<=0 then
Util.GetGameObject(curSelectUpStarGo.transform,"add/add"):SetActive(false)
end
Util.GetGameObject(curSelectUpStarGo.transform,"num"):GetComponent("Text").text=string.format("<color=#FF0000FF>%s/%s</color>", LengthOfTable(curSelectHeroList),curSelectUpStarData.upStarData[4])
else
upStarMaterialIsAll[curSelectUpStarData.upStarData[2]]=1
Util.GetGameObject(curSelectUpStarGo.transform,"add/add"):SetActive(false)
Util.GetGameObject(curSelectUpStarGo.transform,"num"):GetComponent("Text").text=string.format("<color=#FFFFFFFF>%s/%s</color>", LengthOfTable(curSelectHeroList),curSelectUpStarData.upStarData[4])
end
local curUpStarConsumeMaterial={}
for i, v in pairs(curSelectHeroList) do
table.insert(curUpStarConsumeMaterial,v.dynamicId)
end
upStarConsumeMaterial[curSelectUpStarData.upStarData[2]]=curUpStarConsumeMaterial
for i = 1, #upStarConsumeMaterial do
--Log("选择升星位置的英雄数量 "..#upStarConsumeMaterial[i])
if #upStarConsumeMaterial[i]>0 then
for j = 1, #upStarConsumeMaterial[i] do
--Log("选择升星位置的英雄都有谁 "..upStarConsumeMaterial[i][j])
end
end
end
end
--分析设置升星界面显示的英雄list数据 如果当前升星材料的坑位的英雄数据与 以其他坑位有重合并且选择上的英雄不显示 如果是当前坑位显示的英雄显示对勾
function this.SetShowHeroListData(upStarConsumeMaterial,curHeroList)--1 消耗的总消耗组 2 当前坑位可选择的所有英雄
--Log("#curHeroList "..#curHeroList)
local curEndShowHeroListData2={}
for i = 1, #curHeroList do
table.insert(curEndShowHeroListData2,curHeroList[i])
end
local curEndShowHeroListData={}
for i, v in pairs(curEndShowHeroListData2) do
v.isSelect=2
table.insert(curEndShowHeroListData,v)
end
for j = 1, #upStarConsumeMaterial do
if upStarConsumeMaterial[j] and #upStarConsumeMaterial[j]>0 then
for k = 1, #upStarConsumeMaterial[j] do
if j==curSelectUpStarData.upStarData[2] then--curSelectUpStarData 当前坑位选择的英雄信息
for _, v in pairs(curEndShowHeroListData) do
if v.dynamicId==upStarConsumeMaterial[j][k] then
v.isSelect=1
end
end
else
for i, v in pairs(curEndShowHeroListData) do
if v.dynamicId==upStarConsumeMaterial[j][k] then
curEndShowHeroListData[i] = nil
end
end
end
end
end
end
local curList={}
for _, v in pairs(curEndShowHeroListData) do
table.insert(curList,v)
end
return curList
end
--进阶按钮点击事件处理
function this.StarUpClick()
if curHeroData.lv>=HeroManager.heroLvEnd[curHeroData.heroConfig.Id] then
PopupTipPanel.ShowTip(Language[11846])
return
end
if curHeroData.lv<upStarRankUpConfig.LimitLevel then
PopupTipPanel.ShowTip(Language[11851]..upStarRankUpConfig.LimitLevel)
return
end
local isUpStarMaterialsHero=true
for i = 1, #upStarMaterialIsAll do
if upStarMaterialIsAll[i]==2 then
isUpStarMaterialsHero=false
end
end
if isUpStarMaterials and isUpStarMaterialsHero then
NetManager.HeroUpStarEvent(curHeroData.dynamicId,upStarConsumeMaterial ,function (msg)
UIManager.OpenPanel(UIName.RoleAwakeSuccessPanel,curHeroData,upStarRankUpConfig.Id,upStarRankUpConfig.OpenLevel,function ()
local dropItemTabs = BagManager.GetTableByBackDropData(msg)
if #dropItemTabs > 0 then
BagManager.SetDropIsSHowEquipPrint(false)
UIManager.OpenPanel(UIName.RewardItemPopup, msg, 1, function ()
this.DeleteUpStarMaterials()
end)
else
this.DeleteUpStarMaterials()
end
end)
end)
-- 进阶音效
PlaySoundWithoutClick(SoundConfig.Sound_Recruit3)
else
PopupTipPanel.ShowTip("材料不足无法觉醒!")
end
end
--扣除升星 消耗的材料 更新英雄数据
function this.DeleteUpStarMaterials()
HeroManager.UpdateSingleHeroDatas(curHeroData.dynamicId,curHeroData.lv,curHeroData.star+1,curHeroData.breakId,upStarRankUpConfig.Id,true)
HeroManager.UpdateSingleHeroSkillData(curHeroData.dynamicId)
for i, v in pairs(heroDatas) do
if curHeroData == v then
curHeroData=HeroManager.GetSingleHeroData(curHeroData.dynamicId)
v=curHeroData
end
end
--本地数据删除材料英雄
for i = 1, #upStarConsumeMaterial do
HeroManager.DeleteHeroDatas(upStarConsumeMaterial[i])
end
if HeroManager.heroListPanelProID ~= ProIdConst.All then
heroDatas = HeroManager.GetHeroDataByProperty(HeroManager.heroListPanelProID)
else
heroDatas = HeroManager.GetAllHeroDatas()
end
if UIManager.IsOpen(UIName.RoleInfoPanel) then--当界面存在时需要刷新当前界面
HeroManager.SortHeroDatas(heroDatas)
parent:OnOpen(curHeroData, heroDatas,isUpZhen)
parent:OnShow()
end
end
function this:OnSortingOrderChange()
end
function this:OnHide()
this.gameObject:SetActive(false)
end
function this:OnClose()
end
function this:OnDestroy()
upStarPreList = {}
end
return this

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 2f05c10004e33b54b85babde43971bb8
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,167 @@
require("Base/BasePanel")
RoleAwakeSuccessPanel = Inherit(BasePanel)
local this=RoleAwakeSuccessPanel
this.skillConfig=ConfigManager.GetConfig(ConfigName.SkillConfig)
local passiveSkillConfig=ConfigManager.GetConfig(ConfigName.PassiveSkillConfig)
local orginLayer = 20
local callBack = nil
local heroRankupConfig = ConfigManager.GetConfig(ConfigName.HeroRankupConfig)
local heroConfig = ConfigManager.GetConfig(ConfigName.HeroConfig)
local passiveSkillLogicConfig = ConfigManager.GetConfig(ConfigName.PassiveSkillLogicConfig)
--初始化组件(用于子类重写)
function RoleAwakeSuccessPanel:InitComponent()
orginLayer = 20
this.BtnBack = Util.GetGameObject(self.transform, "backBtn")
this.mask = Util.GetGameObject(self.transform, "mask")
this.live2dRoot=Util.GetGameObject(self.transform,"live2dRoot")
this.heroName = Util.GetGameObject(self.transform, "heroInfo/nameAndPossLayout/heroName"):GetComponent("Text")
this.profession = Util.GetGameObject(self.transform, "Pos/PosImage"):GetComponent("Image")
this.proImage = Util.GetGameObject(self.transform, "heroInfo/nameAndPossLayout/proImage/proImage"):GetComponent("Image")
this.starGrid = Util.GetGameObject(self.transform, "heroInfo/sartAndLvLayout")
this.posBgImage=Util.GetGameObject(self.transform,"Pos"):GetComponent("Image")
this.posText=Util.GetGameObject(self.transform,"Pos/PosText"):GetComponent("Text")
this.lvEndInfo=Util.GetGameObject(self.transform, "proInfo/lvEndText"):GetComponent("Text")
this.UI_Effect_choukaSSR = Util.GetGameObject(self.transform, "UI_Effect_chouka_SSR")
this.prefab = Util.GetGameObject(self.gameObject, "proInfo/pre")
this.ScrollParentView1 = Util.GetGameObject(self.gameObject, "proInfo/ScrollFitter")
this.ScrollView1 = SubUIManager.Open(SubUIConfig.ScrollFitterView, this.ScrollParentView1.transform,
this.prefab, Vector2.New(1017.6, 287.5), 1, 1)
end
--绑定事件(用于子类重写)
function RoleAwakeSuccessPanel:BindEvent()
Util.AddClick(this.BtnBack, function()
PlaySoundWithoutClick(SoundConfig.Sound_UICancel)
self:ClosePanel()
end)
end
--添加事件监听(用于子类重写)
function RoleAwakeSuccessPanel:AddListener()
end
--移除事件监听(用于子类重写)
function RoleAwakeSuccessPanel:RemoveListener()
end
function RoleAwakeSuccessPanel:OnSortingOrderChange()
Util.AddParticleSortLayer(this.UI_Effect_choukaSSR, self.sortingOrder - orginLayer)
this.mask:GetComponent("Canvas").overrideSorting = true
this.mask:GetComponent("Canvas").sortingOrder = self.sortingOrder - 30
orginLayer = self.sortingOrder
end
local curHeroData
--界面打开时调用(用于子类重写)
function RoleAwakeSuccessPanel:OnOpen(_curHeroData,_nextHeroUpStarId,_curHeroRankUpConfigOpenLevel,_callBack)
curHeroData=_curHeroData
local nextHeroUpStarId=_nextHeroUpStarId
local curHeroRankUpConfigOpenLevel=_curHeroRankUpConfigOpenLevel
callBack = _callBack
this.UI_Effect_choukaSSR:SetActive(true)
this.LiveName = GetResourcePath(curHeroData.heroConfig.Live)
this.LiveGO = poolManager:LoadLive(this.LiveName, this.live2dRoot.transform,
Vector3.one * curHeroData.heroConfig.Scale, Vector3.New(curHeroData.heroConfig.Position[1],curHeroData.heroConfig.Position[2],0))
SetHeroStars(this.starGrid, curHeroData.star+1,1,Vector2.New(60,60),-11,Vector2.New(0.5,0.5))
this.profession.sprite = Util.LoadSprite(GetHeroPosStr(curHeroData.heroConfig.Profession))
this.proImage.sprite =Util.LoadSprite(GetProStrImageByProNum(curHeroData.heroConfig.PropertyName))
this.heroName.text =curHeroData.heroConfig.ReadingName
this.posBgImage.sprite=Util.LoadSprite(GetHeroPosBgStr(curHeroData.heroConfig.Profession))
this.posText.text=curHeroData.heroConfig.HeroLocation
this.lvEndInfo.text=string.format(Language[11867],curHeroRankUpConfigOpenLevel)
local TalentData = this.GetNewTalentDataShow()
LogPink("TalentData "..#TalentData)
this.ScrollView1:SetData(TalentData, function(index, go)
this.SingOldTalentDataShow(go, TalentData[index])
end)
end
function this.GetNewTalentDataShow()
local breakSkillDataList = {}
local upStarSkillDataList = {}
if curHeroData.heroConfig.Awaken then
for i = 1, #curHeroData.heroConfig.Awaken do
local Desc = passiveSkillConfig[curHeroData.heroConfig.Awaken[i][3]].Desc
if curHeroData.heroConfig.Awaken[i][1] == 1 then--突破
-- local titleStr = NumToSimplenessFont[heroRankupConfig[curHeroData.heroConfig.Awaken[i][2]].Phase[2]] .. Language[11864]
-- local curBreakId = curHeroData.heroConfig.Awaken[i][2]
-- if breakSkillDataList[curBreakId] then
-- breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str = breakSkillDataList[curBreakId].str .. "  <color=#66FF00>"..Desc.."</color>"}
-- else
-- breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
-- end
else--升星
local curUpStarId = curHeroData.heroConfig.Awaken[i][2]
local titleStr = NumToSimplenessFont[heroRankupConfig[curUpStarId].Phase[2]] .. Language[11865]
local _passiveSkillId = passiveSkillConfig[curHeroData.heroConfig.Awaken[i][3]].Id
if upStarSkillDataList[curUpStarId] then
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str = upStarSkillDataList[curUpStarId].str .. "  <color=#66FF00>"..Desc.."</color>"}
else
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
end
end
end
end
-- local breakSkillDataList2 = {}
-- for i, v in pairs(breakSkillDataList) do
-- table.insert(breakSkillDataList2,v)
-- end
-- table.sort(breakSkillDataList2, function(a,b) return a.index<b.index end)
local upStarSkillDataList2 = {}
for i, v in pairs(upStarSkillDataList) do
table.insert(upStarSkillDataList2,v)
end
table.sort(upStarSkillDataList2, function(a,b) return a.index<b.index end)
-- for i = 1, #upStarSkillDataList2 do
-- table.insert(breakSkillDataList2,upStarSkillDataList2[i])
-- end
return upStarSkillDataList2
end
function this.SingOldTalentDataShow(go,data)
local breakGo = Util.GetGameObject(go, "breakSkillTextPre")
local upStarGo = Util.GetGameObject(go, "upStarSkillTextPre")
if data.type == 1 then--突破
breakGo:SetActive(true)
upStarGo:SetActive(false)
breakGo:GetComponent("Text").text = data.str
else
breakGo:SetActive(false)
upStarGo:SetActive(true)
local kongStr = ""
if passiveSkillLogicConfig[data.passiveSkillId].Judge == 1 then
kongStr = "   "
else
kongStr = ""
end
Util.GetGameObject(upStarGo.transform, "Image"):SetActive(passiveSkillLogicConfig[data.passiveSkillId].Judge == 1)
upStarGo:GetComponent("Text").text = kongStr .. data.str
end
end
--界面关闭时调用(用于子类重写)
function RoleAwakeSuccessPanel:OnClose()
if this.LiveName then
poolManager:UnLoadLive(this.LiveName, this.LiveGO)
this.LiveName = nil
end
if callBack then
callBack()
callBack = nil
end
end
--界面销毁时调用(用于子类重写)
function RoleAwakeSuccessPanel:OnDestroy()
end
return RoleAwakeSuccessPanel

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 8abe75a56e916ca4cad7e3c305129725
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,180 @@
require("Base/BasePanel")
RoleAwakeTalentPopup = Inherit(BasePanel)
local this = RoleAwakeTalentPopup
local heroConfig
local passiveSkillLogicConfig=ConfigManager.GetConfig(ConfigName.PassiveSkillLogicConfig)
local passiveSkillConfig=ConfigManager.GetConfig(ConfigName.PassiveSkillConfig)
local heroRankupConfig=ConfigManager.GetConfig(ConfigName.HeroRankupConfig)
--初始化组件(用于子类重写)
function RoleAwakeTalentPopup:InitComponent()
Util.GetGameObject(self.transform, "bg1/name/text"):GetComponent("Text").text = "觉醒前天赋"
Util.GetGameObject(self.transform, "bg2/name/text"):GetComponent("Text").text = "觉醒后天赋"
self.BackMask = Util.GetGameObject(self.transform, "BackMask")
this.prefab = Util.GetGameObject(self.gameObject, "pre")
this.ScrollParentView1 = Util.GetGameObject(self.gameObject, "bg1/ScrollFitter")
this.ScrollView1 = SubUIManager.Open(SubUIConfig.ScrollFitterView, this.ScrollParentView1.transform,
this.prefab, Vector2.New(417.8, 552.7), 1, 1)
this.ScrollParentView2 = Util.GetGameObject(self.gameObject, "bg2/ScrollFitter")
this.ScrollView2 = SubUIManager.Open(SubUIConfig.ScrollFitterView, this.ScrollParentView2.transform,
this.prefab, Vector2.New(417.8, 552.7), 1, 1)
end
--绑定事件(用于子类重写)
function RoleAwakeTalentPopup:BindEvent()
Util.AddClick(self.BackMask, function()
self:ClosePanel()
end)
end
--添加事件监听(用于子类重写)
function RoleAwakeTalentPopup:AddListener()
end
--移除事件监听(用于子类重写)
function RoleAwakeTalentPopup:RemoveListener()
end
--界面打开时调用(用于子类重写)
--传三个参数 是因为图鉴也要用
function RoleAwakeTalentPopup:OnOpen(_heroConfig)
heroConfig = _heroConfig
end
--界面打开或者重新打开后,界面刷新时调用(用于子类重写)
function RoleAwakeTalentPopup:OnShow()
local OldTalentData = this.GetOldTalentDataShow()
local newTalentData = this.GetNewTalentDataShow()
this.ScrollView1:SetData(OldTalentData, function(index, go)
this.SingOldTalentDataShow(go, OldTalentData[index])
end)
this.ScrollView2:SetData(newTalentData, function(index, go)
this.SingOldTalentDataShow(go, newTalentData[index])
end)
end
function this.GetOldTalentDataShow()
local breakSkillDataList = {}
local upStarSkillDataList = {}
if heroConfig.OpenPassiveSkillRules then
for i = 1, #heroConfig.OpenPassiveSkillRules do
local Desc = passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc
if heroConfig.OpenPassiveSkillRules[i][1] == 1 then--突破
local titleStr = NumToSimplenessFont[heroRankupConfig[heroConfig.OpenPassiveSkillRules[i][2]].Phase[2]] .. Language[11864]
local curBreakId = heroConfig.OpenPassiveSkillRules[i][2]
if breakSkillDataList[curBreakId] then
breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str = breakSkillDataList[curBreakId].str .. "  <color=#66FF00>"..Desc.."</color>"}
else
breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
end
else--升星
local curUpStarId = heroConfig.OpenPassiveSkillRules[i][2]
local titleStr = NumToSimplenessFont[heroRankupConfig[curUpStarId].Phase[2]] .. Language[11865]
local _passiveSkillId = passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Id
if upStarSkillDataList[curUpStarId] then
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str = upStarSkillDataList[curUpStarId].str .. "  <color=#66FF00>"..Desc.."</color>"}
else
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
end
end
end
end
local breakSkillDataList2 = {}
for i, v in pairs(breakSkillDataList) do
table.insert(breakSkillDataList2,v)
end
table.sort(breakSkillDataList2, function(a,b) return a.index<b.index end)
local upStarSkillDataList2 = {}
for i, v in pairs(upStarSkillDataList) do
table.insert(upStarSkillDataList2,v)
end
table.sort(upStarSkillDataList2, function(a,b) return a.index<b.index end)
for i = 1, #upStarSkillDataList2 do
table.insert(breakSkillDataList2,upStarSkillDataList2[i])
end
return breakSkillDataList2
end
function this.GetNewTalentDataShow()
local breakSkillDataList = {}
local upStarSkillDataList = {}
if heroConfig.Awaken then
for i = 1, #heroConfig.Awaken do
local Desc = passiveSkillConfig[heroConfig.Awaken[i][3]].Desc
if heroConfig.Awaken[i][1] == 1 then--突破
local titleStr = NumToSimplenessFont[heroRankupConfig[heroConfig.Awaken[i][2]].Phase[2]] .. Language[11864]
local curBreakId = heroConfig.Awaken[i][2]
if breakSkillDataList[curBreakId] then
breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str = breakSkillDataList[curBreakId].str .. "  <color=#66FF00>"..Desc.."</color>"}
else
breakSkillDataList[curBreakId] = {index = curBreakId,type = 1,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
end
else--升星
local curUpStarId = heroConfig.Awaken[i][2]
local titleStr = NumToSimplenessFont[heroRankupConfig[curUpStarId].Phase[2]] .. Language[11865]
local _passiveSkillId = passiveSkillConfig[heroConfig.Awaken[i][3]].Id
if upStarSkillDataList[curUpStarId] then
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str = upStarSkillDataList[curUpStarId].str .. "  <color=#66FF00>"..Desc.."</color>"}
else
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,type = 2,index = curUpStarId,str ="<color=#66FF00>"..titleStr..Desc.."</color>"}
end
end
end
end
local breakSkillDataList2 = {}
for i, v in pairs(breakSkillDataList) do
table.insert(breakSkillDataList2,v)
end
table.sort(breakSkillDataList2, function(a,b) return a.index<b.index end)
local upStarSkillDataList2 = {}
for i, v in pairs(upStarSkillDataList) do
table.insert(upStarSkillDataList2,v)
end
table.sort(upStarSkillDataList2, function(a,b) return a.index<b.index end)
for i = 1, #upStarSkillDataList2 do
table.insert(breakSkillDataList2,upStarSkillDataList2[i])
end
return breakSkillDataList2
end
function this.SingOldTalentDataShow(go,data)
local breakGo = Util.GetGameObject(go, "breakSkillTextPre")
local upStarGo = Util.GetGameObject(go, "upStarSkillTextPre")
if data.type == 1 then--突破
breakGo:SetActive(true)
upStarGo:SetActive(false)
breakGo:GetComponent("Text").text = data.str
else
breakGo:SetActive(false)
upStarGo:SetActive(true)
local kongStr = ""
if passiveSkillLogicConfig[data.passiveSkillId].Judge == 1 then
kongStr = "   "
else
kongStr = ""
end
Util.GetGameObject(upStarGo.transform, "Image"):SetActive(passiveSkillLogicConfig[data.passiveSkillId].Judge == 1)
upStarGo:GetComponent("Text").text = kongStr .. data.str
end
end
function this.SingNewTalentDataShow(go,data)
-- go:GetComponent("Text").text = breakSkillDataList2[i].str
-- local kongStr = ""
-- if passiveSkillLogicConfig[upStarSkillDataList2[i].passiveSkillId].Judge == 1 then
-- kongStr = "   "
-- else
-- kongStr = ""
-- end
-- Util.GetGameObject(go.transform, "Image"):SetActive(passiveSkillLogicConfig[upStarSkillDataList2[i].passiveSkillId].Judge == 1)
-- go:GetComponent("Text").text = kongStr .. upStarSkillDataList2[i].str
end
--界面关闭时调用(用于子类重写)
function RoleAwakeTalentPopup:OnClose()
end
--界面销毁时调用(用于子类重写)
function RoleAwakeTalentPopup:OnDestroy()
end
return RoleAwakeTalentPopup

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: c9d1c457a0da41f419993e30a1d170b3
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -4,6 +4,7 @@ local this = RoleInfoPanel
local RoleSkinPanel = require("Modules/RoleInfo/RoleSkinPanel")
local RoleInfoLayout = require("Modules/RoleInfo/RoleInfoLayout")
local RoleUpStarLayout = require("Modules/RoleInfo/RoleUpStarLayout")
local RoleAwakeLayout = require("Modules/RoleInfo/RoleAwakeLayout")
local RoleStoryLayout = require("Modules/RoleInfo/RoleStoryLayout")
local _CurPageIndex = 1
@ -14,9 +15,11 @@ local tabs = {
},
[2] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "进阶",rpType = -1,
},
[3] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "传说",rpType = -1,
[3] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "觉醒",rpType = -1,
},
[4] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "皮肤",rpType = -1,
[4] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "传说",rpType = -1,
},
[5] = {default = "r_hero_xuanze_002", lock = "r_hero_xuanze_002", select = "r_hero_xuanze_001",title = "皮肤",rpType = -1,
},
}
@ -101,8 +104,9 @@ function RoleInfoPanel:InitComponent()
this.PageList = {
[1] = RoleInfoLayout:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleInfoLayout")),
[2] = RoleUpStarLayout:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleUpStarLayout")),
[3] = RoleStoryLayout:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleStoryLayout")),
[4] = RoleSkinPanel:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleSkinLayout")),
[3] = RoleAwakeLayout:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleAwakelayout")),
[4] = RoleStoryLayout:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleStoryLayout")),
[5] = RoleSkinPanel:InitComponent(Util.GetGameObject(self.transform, "rolePanel/layout/roleSkinLayout")),
}
this.dragView = SubUIManager.Open(SubUIConfig.DragView, self.gameObject.transform)
@ -210,7 +214,7 @@ function RoleInfoPanel:RemoveListener()
end
this.UpdateSkinShow = function()
if _CurPageIndex == 4 then
if _CurPageIndex == 5 then
this:OnPageTabChange(_CurPageIndex)
end
end
@ -371,7 +375,7 @@ function this:UpdateBtnList()
if not tabsList[k] then
tabsList[k] = newObjToParent(this.btnPre,this.btnList)
end
if k == 4 then
if k == 5 then
local configs = ConfigManager.GetAllConfigsDataByKey(ConfigName.HeroSkin,"HeroId",curHeroData.id)
local HeoSkin = {}
for i = 1 ,#configs do
@ -387,7 +391,6 @@ function this:UpdateBtnList()
else
tabsList[k].gameObject:SetActive(true)
end
local title = Util.GetGameObject(tabsList[k], "Text"):GetComponent("Text")
local redpot = Util.GetGameObject(tabsList[k], "redPoint")
title.text = v.title
@ -410,6 +413,31 @@ function this:UpdateBtnList()
end
end)
end
--根据星级决定叶签现隐
if tabsList[2] and tabsList[3] then
if curHeroData.star < 10 then
if _CurPageIndex == 3 then
_CurPageIndex = 1
this:OnPageTabChange(_CurPageIndex)
end
tabsList[2].gameObject:SetActive(true)
tabsList[3].gameObject:SetActive(false)
elseif curHeroData.star == 10 and curHeroData.heroConfig.Awaken and #curHeroData.heroConfig.Awaken > 0 then
if _CurPageIndex == 2 then
_CurPageIndex = 1
this:OnPageTabChange(_CurPageIndex)
end
tabsList[2].gameObject:SetActive(false)
tabsList[3].gameObject:SetActive(true)
else
if _CurPageIndex == 2 or _CurPageIndex == 3 then
_CurPageIndex = 1
this:OnPageTabChange(_CurPageIndex)
end
tabsList[2].gameObject:SetActive(false)
tabsList[3].gameObject:SetActive(false)
end
end
end
function this:CheckRedPointType(index,isShowRedPoint)
@ -446,7 +474,7 @@ end
function this:UpdateHeroInfoData()
this:UpdateBtnList()
if _CurPageIndex == 4 then
if _CurPageIndex == 5 then
local configs = ConfigManager.GetAllConfigsDataByKey(ConfigName.HeroSkin,"HeroId",curHeroData.id)
local HeoSkin = {}
for i = 1 ,#configs do
@ -517,9 +545,10 @@ function this:UpdateHeroInfoData()
end
--天赋
this.talentBtn:SetActive(curHeroData.heroConfig.OpenPassiveSkillRules ~= nil)
if curHeroData.heroConfig.OpenPassiveSkillRules then
local OpenPassiveSkillRules = curHeroData.star == HeroManager.awakeNextStarIndex and curHeroData.heroConfig.Awaken or curHeroData.heroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
local openlists,compoundOpenNum,compoundNum,allUpStarOpenData = HeroManager.GetAllPassiveSkillIds(curHeroData.heroConfig,curHeroData.breakId,curHeroData.upStarId)
this.talentProgress.text = #openlists - compoundOpenNum .."/"..#curHeroData.heroConfig.OpenPassiveSkillRules - compoundNum
this.talentProgress.text = #openlists - compoundOpenNum .."/"..#OpenPassiveSkillRules - compoundNum
if allUpStarOpenData[curHeroData.star + 1] then
this.talentTipStr.text = Language[11837].. NumToSimplenessFont[curHeroData.star + 1] ..Language[11838]
else

View File

@ -49,39 +49,41 @@ end
function RoleTalentPopup:GetTalentDataShow()
breakSkillDataList = {}
upStarSkillDataList = {}
if heroConfig.OpenPassiveSkillRules then
for i = 1, #heroConfig.OpenPassiveSkillRules do
if heroConfig.OpenPassiveSkillRules[i][1] == 1 then--突破
local titleStr = NumToSimplenessFont[heroRankupConfig[heroConfig.OpenPassiveSkillRules[i][2]].Phase[2]] .. Language[11864]
local curBreakId = heroConfig.OpenPassiveSkillRules[i][2]
local heroRankUpConfig = ConfigManager.GetConfig(ConfigName.HeroRankupConfig)
local OpenPassiveSkillRules = (upStarId and upStarId ~=0 and heroRankUpConfig[upStarId].OpenStar == HeroManager.awakeNextStarIndex) and heroConfig.Awaken or heroConfig.OpenPassiveSkillRules
if OpenPassiveSkillRules then
for i = 1, #OpenPassiveSkillRules do
if OpenPassiveSkillRules[i][1] == 1 then--突破
local titleStr = NumToSimplenessFont[heroRankupConfig[OpenPassiveSkillRules[i][2]].Phase[2]] .. Language[11864]
local curBreakId = OpenPassiveSkillRules[i][2]
if breakId >= curBreakId then
if breakSkillDataList[curBreakId] then
breakSkillDataList[curBreakId] = {index = curBreakId,str = breakSkillDataList[curBreakId].str .. "  <color=#66FF00>"..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
breakSkillDataList[curBreakId] = {index = curBreakId,str = breakSkillDataList[curBreakId].str .. "  <color=#66FF00>"..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
else
breakSkillDataList[curBreakId] = {index = curBreakId,str ="<color=#66FF00>"..titleStr..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
breakSkillDataList[curBreakId] = {index = curBreakId,str ="<color=#66FF00>"..titleStr..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
end
else
if breakSkillDataList[curBreakId] then
breakSkillDataList[curBreakId] = {index = curBreakId,str =breakSkillDataList[curBreakId].str .. " <color=#B9AC97>"..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
breakSkillDataList[curBreakId] = {index = curBreakId,str =breakSkillDataList[curBreakId].str .. " <color=#B9AC97>"..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
else
breakSkillDataList[curBreakId] = {index = curBreakId,str ="<color=#B9AC97>"..titleStr..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
breakSkillDataList[curBreakId] = {index = curBreakId,str ="<color=#B9AC97>"..titleStr..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
end
end
else--升星
local curUpStarId = heroConfig.OpenPassiveSkillRules[i][2]
local curUpStarId = OpenPassiveSkillRules[i][2]
local titleStr = NumToSimplenessFont[heroRankupConfig[curUpStarId].Phase[2]] .. Language[11865]
local _passiveSkillId = passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Id
local _passiveSkillId = passiveSkillConfig[OpenPassiveSkillRules[i][3]].Id
if upStarId >= curUpStarId then
if upStarSkillDataList[curUpStarId] then
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str = upStarSkillDataList[curUpStarId].str .. "  <color=#66FF00>"..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str = upStarSkillDataList[curUpStarId].str .. "  <color=#66FF00>"..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
else
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str ="<color=#66FF00>"..titleStr..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str ="<color=#66FF00>"..titleStr..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
end
else
if upStarSkillDataList[curUpStarId] then
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str =upStarSkillDataList[curUpStarId].str .. " <color=#B9AC97>"..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str =upStarSkillDataList[curUpStarId].str .. " <color=#B9AC97>"..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
else
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str ="<color=#B9AC97>"..titleStr..passiveSkillConfig[heroConfig.OpenPassiveSkillRules[i][3]].Desc.."</color>"}
upStarSkillDataList[curUpStarId] = {passiveSkillId = _passiveSkillId,index = curUpStarId,str ="<color=#B9AC97>"..titleStr..passiveSkillConfig[OpenPassiveSkillRules[i][3]].Desc.."</color>"}
end
end
end

View File

@ -39,6 +39,9 @@ function RoleUpStarListPanel:BindEvent()
Util.AddClick(this.BtnSure, function()
self:ClosePanel()
Log("curSelectHeroList "..LengthOfTable(curSelectHeroList))
for i, v in pairs(curSelectHeroList) do
LogPink("v.dynamicId "..v.dynamicId)
end
openThisPanel:UpdateUpStarPosHeroData(curSelectHeroList)
end)
Util.AddClick(this.btnAutoSelect, function()