Files
CartoonRPG/Assets/StixGames/GrassShader/Editor/LayerFieldAttributeEditor.cs

15 lines
441 B
C#
Raw Normal View History

2025-06-05 22:59:18 +01:00
using StixGames.NatureCore.Utility;
using UnityEditor;
using UnityEngine;
namespace StixGames.GrassShader
{
[CustomPropertyDrawer(typeof(LayerFieldAttribute))]
class LayerFieldAttributeEditor : PropertyDrawer
{
public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
{
property.intValue = EditorGUI.LayerField(position, label, property.intValue);
}
}
}