const 变量名

This commit is contained in:
tpxxn
2025-03-09 02:33:14 +08:00
parent 4c325f7ca6
commit f32e5e79a3
26 changed files with 170 additions and 162 deletions

View File

@@ -18,10 +18,10 @@ namespace GameLogic
private readonly List<UIWindow> _uiStack = new List<UIWindow>(100);
public const int LayerDeep = 2000;
public const int WindowDeep = 100;
public const int WindowHideLayer = 2; // Ignore Raycast
public const int WindowShowLayer = 5; // UI
public const int LAYER_DEEP = 2000;
public const int WINDOW_DEEP = 100;
public const int WINDOW_HIDE_LAYER = 2; // Ignore Raycast
public const int WINDOW_SHOW_LAYER = 5; // UI
public static IUIResourceLoader Resource;
@@ -445,13 +445,13 @@ namespace GameLogic
private void OnSortWindowDepth(int layer)
{
int depth = layer * LayerDeep;
int depth = layer * LAYER_DEEP;
for (int i = 0; i < _uiStack.Count; i++)
{
if (_uiStack[i].WindowLayer == layer)
{
_uiStack[i].Depth = depth;
depth += WindowDeep;
depth += WINDOW_DEEP;
}
}
}

View File

@@ -265,7 +265,7 @@ namespace GameLogic
for (var index = 0; index < listCanvas.Length; index++)
{
var childCanvas = listCanvas[index];
childCanvas.sortingOrder = parentCanvas.sortingOrder + childCanvas.sortingOrder % UIModule.WindowDeep;
childCanvas.sortingOrder = parentCanvas.sortingOrder + childCanvas.sortingOrder % UIModule.WINDOW_DEEP;
}
}
}

View File

@@ -138,7 +138,7 @@ namespace GameLogic
{
if (_canvas != null)
{
return _canvas.gameObject.layer == UIModule.WindowShowLayer;
return _canvas.gameObject.layer == UIModule.WINDOW_SHOW_LAYER;
}
else
{
@@ -150,7 +150,7 @@ namespace GameLogic
{
if (_canvas != null)
{
int setLayer = value ? UIModule.WindowShowLayer : UIModule.WindowHideLayer;
int setLayer = value ? UIModule.WINDOW_SHOW_LAYER : UIModule.WINDOW_HIDE_LAYER;
if (_canvas.gameObject.layer == setLayer)
return;

View File

@@ -15,7 +15,7 @@ namespace Procedure
{
private int _curTryCount;
private const int MaxTryCount = 3;
private const int MAX_TRY_COUNT = 3;
public override bool UseNativeDialog { get; }