BITFALL/Assets/Plugins/Polaris - Low Poly Ecosystem/Polaris - Low Poly Terrain .../Runtime/Scripts/Utilities/GLayerInitializer.cs

34 lines
1.1 KiB
C#
Raw Normal View History

2024-03-05 17:34:41 +08:00
#if GRIFFIN
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using Pinwheel.Griffin.SplineTool;
namespace Pinwheel.Griffin
{
#if UNITY_EDITOR
public static class GLayerInitializer
{
public static void SetupRaycastLayer()
{
int index = GEditorSettings.Instance.layers.raycastLayerIndex;
string layer = GStylizedTerrain.RAYCAST_LAYER;
if (GEditorSettings.Instance.layers.SetupLayer(index, layer))
{
Debug.Log($"POLARIS: Set layer {index} to {layer}. This layer is reserved for the terrain to work!");
}
}
public static void SetupSplineLayer()
{
int index = GEditorSettings.Instance.layers.splineLayerIndex;
string layer = GSplineCreator.SPLINE_LAYER;
if (GEditorSettings.Instance.layers.SetupLayer(index, layer))
{
Debug.Log($"POLARIS: Set layer {index} to {layer}. This layer is reserved for Spline tool to work!");
}
}
}
#endif
}
#endif