Multi-object editing not supported error resolution

error message


Add a property [caneditmultipleobjects] before your editor class declaration.

When an editor without this attribute selects multiple objects, it will prompt “multi object editing not supported”, and other drawing errors will not be displayed.

Note: the script file of customeditor must be placed in the assets / editor folder in the project, and using unityeditor; must be added to the reference of the script header file;.

using System.Collections;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;

[CanEditMultipleObjects]//add this
public class TestLightmapsHolderEditor : Editor
    public override void OnInspectorGUI()
        TestLightmapsHolder holder = target as TestLightmapsHolder;
        if (GUILayout.Button("Save light mapping"))

Read More: