中心部分点击领取奖励
parent
c55aad07df
commit
46edb1a00c
|
|
@ -11366,6 +11366,114 @@ MonoBehaviour:
|
|||
m_ChildForceExpandHeight: 1
|
||||
m_ChildControlWidth: 0
|
||||
m_ChildControlHeight: 0
|
||||
--- !u!1 &2889677954625239401
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 6776360784755451779}
|
||||
- component: {fileID: 8172608782320730989}
|
||||
- component: {fileID: 5733164051521648386}
|
||||
- component: {fileID: 2567406817090281184}
|
||||
m_Layer: 5
|
||||
m_Name: btnGet
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &6776360784755451779
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2889677954625239401}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 5226093220144160963}
|
||||
m_RootOrder: 4
|
||||
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: -88}
|
||||
m_SizeDelta: {x: 450, y: 350}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &8172608782320730989
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2889677954625239401}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 1392445389, guid: f70555f144d8491a825f0804e09c671c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Navigation:
|
||||
m_Mode: 3
|
||||
m_SelectOnUp: {fileID: 0}
|
||||
m_SelectOnDown: {fileID: 0}
|
||||
m_SelectOnLeft: {fileID: 0}
|
||||
m_SelectOnRight: {fileID: 0}
|
||||
m_Transition: 0
|
||||
m_Colors:
|
||||
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
|
||||
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
|
||||
m_ColorMultiplier: 1
|
||||
m_FadeDuration: 0.1
|
||||
m_SpriteState:
|
||||
m_HighlightedSprite: {fileID: 0}
|
||||
m_PressedSprite: {fileID: 0}
|
||||
m_DisabledSprite: {fileID: 0}
|
||||
m_AnimationTriggers:
|
||||
m_NormalTrigger: Normal
|
||||
m_HighlightedTrigger: Highlighted
|
||||
m_PressedTrigger: Pressed
|
||||
m_DisabledTrigger: Disabled
|
||||
m_Interactable: 1
|
||||
m_TargetGraphic: {fileID: 0}
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_TypeName: UnityEngine.UI.Button+ButtonClickedEvent, UnityEngine.UI, Version=1.0.0.0,
|
||||
Culture=neutral, PublicKeyToken=null
|
||||
--- !u!222 &5733164051521648386
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2889677954625239401}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!114 &2567406817090281184
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2889677954625239401}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: e459a084d8e15a240b58db751097122b, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
|
||||
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
--- !u!1 &2910750955178774158
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
@ -34195,6 +34303,7 @@ RectTransform:
|
|||
- {fileID: 531644364764230931}
|
||||
- {fileID: 7746197626127731834}
|
||||
- {fileID: 5817873623771994884}
|
||||
- {fileID: 6776360784755451779}
|
||||
m_Father: {fileID: 8919506895467505745}
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
|
|
|||
|
|
@ -43,6 +43,7 @@ function this:InitComponent(gameObject)
|
|||
this.btnStore = Util.GetGameObject(this.rightUp,"store")
|
||||
--center
|
||||
this.centerTime = Util.GetGameObject(this.gameObject,"center/time/num"):GetComponent("Text")
|
||||
this.btnGet = Util.GetGameObject(this.gameObject,"center/btnGet")
|
||||
--leftTime
|
||||
this.leftTime = Util.GetGameObject(this.gameObject,"limitdi/limit"):GetComponent("Text")
|
||||
--shop
|
||||
|
|
@ -76,6 +77,10 @@ function SheJiDaDian:BindEvent()
|
|||
UIManager.OpenPanel(UIName.HelpPopup,HELP_TYPE.QianKunBox,this.helpPosition.x,this.helpPosition.y)
|
||||
end)
|
||||
|
||||
Util.AddClick(this.btnGet,function()
|
||||
PopupTipPanel.ShowTip("点击此处领取奖励,还没写~")
|
||||
end)
|
||||
|
||||
Util.AddClick(this.btnStore,function()
|
||||
-- this.effect:SetActive(false)
|
||||
this.shop:SetActive(true)
|
||||
|
|
@ -140,6 +145,8 @@ function this:Refresh()
|
|||
|
||||
end
|
||||
|
||||
|
||||
--点击或长按处理升级处理
|
||||
function this.OnPointerDown(Pointgo,data)--按下
|
||||
numCount = 0
|
||||
isLongPress = true
|
||||
|
|
@ -147,18 +154,16 @@ function this.OnPointerDown(Pointgo,data)--按下
|
|||
end
|
||||
function this.OnPointerUp(Pointgo,data)--抬起
|
||||
if isPress then
|
||||
PopupTipPanel.ShowTip("捐献")
|
||||
this:RequestDonate(1)
|
||||
end
|
||||
isLongPress = false
|
||||
isPress = false
|
||||
end
|
||||
|
||||
--升级处理
|
||||
function this.OnUpdate()
|
||||
if isLongPress then
|
||||
numCount = numCount + 1
|
||||
if numCount > 20 then
|
||||
PopupTipPanel.ShowTip("捐献献献献献献献献献献献")
|
||||
this:RequestDonate(2)
|
||||
isPress = false
|
||||
else
|
||||
if not isPress then
|
||||
|
|
@ -167,6 +172,14 @@ function this.OnUpdate()
|
|||
end
|
||||
end
|
||||
end
|
||||
function this:RequestDonate(type)
|
||||
if type == 1 then
|
||||
PopupTipPanel.ShowTip("捐献")
|
||||
elseif type == 2 then
|
||||
PopupTipPanel.ShowTip("长按捐献")
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function this:LeftUpShow(ActInfo,_curRankType)
|
||||
local allRankData,myRankData,rankType
|
||||
|
|
|
|||
Loading…
Reference in New Issue