【问题标题】:Unity Edior Drawer Property AlignUnity 编辑器绘制属性对齐
【发布时间】:2020-10-04 17:37:40
【问题描述】:

有人知道如何处理这个问题吗? 我需要在没有恒定值的情况下偏移该网格。 Unity Editor 可以给我属性的位置吗?

enter image description here

【问题讨论】:

    标签: unity3d unity-editor


    【解决方案1】:

    以下行是移动元素并保持与其他属性对齐所需的偏移量

    float offset = EditorGUIUtility.labelWidth - ((EditorGUI.indentLevel) * 15);
    

    我找到了答案here

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2016-12-11
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-15
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多