예제 #1
0
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();
        MapLane mapLane = (MapLane)target;

        EditorGUILayout.LabelField("", GUI.skin.horizontalSlider);

        if (GUILayout.Button("Reverse Lane"))
        {
            Undo.RecordObject(mapLane, "change builder");
            mapLane.ReversePoints();
        }
    }
예제 #2
0
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();
        MapLane mapLane = (MapLane)target;


        if (mapLane.leftLineBoundry != null)
        {
            mapLane.leftLineBoundry.lineType = (MapData.LineType)EditorGUILayout.EnumPopup("Left Boundary Type: ", mapLane.leftLineBoundry?.lineType);
        }

        if (mapLane.rightLineBoundry != null)
        {
            mapLane.rightLineBoundry.lineType = (MapData.LineType)EditorGUILayout.EnumPopup("Right Boundary Type: ", mapLane.rightLineBoundry?.lineType);
        }

        EditorGUILayout.LabelField("", GUI.skin.horizontalSlider);

        if (GUILayout.Button("Reverse Lane"))
        {
            Undo.RecordObject(mapLane, "change builder");
            mapLane.ReversePoints();
        }
    }