This commit is contained in:
2020-07-04 14:41:25 +08:00
parent 70c346d2c1
commit a8f02e4da5
3748 changed files with 587372 additions and 0 deletions

View File

@@ -0,0 +1,81 @@
/*
********************************************************************************
*Copyright(C),coolae.net
*Author: chenbin
*Version: 2.0
*Date: 2017-01-09
*Description: 页面后面的档板
*Others:
*History:
*********************************************************************************
*/
using UnityEngine;
using System.Collections;
//档板
namespace Coolape
{
public class CLPBackplate : CLPanelLua
{
public static CLPBackplate self;
// public UITexture textureBg;
// public Camera camera;
public CLPBackplate ()
{
self = this;
}
public override void show ()
{
base.show ();
}
public void procOtherPanel ()
{
if (CLPanelManager.panelRetainLayer.Count > 0) {
CLPanelBase[] ps = CLPanelManager.panelRetainLayer.ToArray ();
if (ps != null) {
for (int i = 0; i < ps.Length; i++) {
if (ps [i].isNeedBackplate && ps [i].isActive) {
_proc (ps [i]);
ps = null;
return;
}
}
hide ();
ps = null;
} else {
hide ();
}
} else {
hide ();
}
}
public void proc (CLPanelBase clpanel)
{
if (clpanel == null) {
procOtherPanel ();
return;
}
if (clpanel.isNeedBackplate) {
_proc (clpanel);
} else {
procOtherPanel ();
}
}
public void _proc (CLPanelBase clpanel)
{
setData (clpanel);
show ();
this.panel.depth = clpanel.panel.depth - 1;
Vector3 pos = transform.localPosition;
this.panel.renderQueue = UIPanel.RenderQueue.StartAt;
// 设置startingRenderQueue是为了可以在ui中使用粒子效果注意在粒子中要绑定CLUIParticle角本
this.panel.startingRenderQueue = CLPanelManager.Const_RenderQueue + this.panel.depth;
pos.z = -180;
transform.localPosition = pos;
}
}
}