Skip to content

2018.4: StaticEditorFlags error messages #79

@unitycoder

Description

@unitycoder

Assets\PointCloudTools\Editor\PointCloud2MeshConverter.cs(1569,81): error CS0117: 'StaticEditorFlags' does not contain a definition for 'ContributeGI'

Assets\PointCloudTools\Editor\PointCloud2MeshConverter.cs(1700,87): error CS0117: 'StaticEditorFlags' does not contain a definition for 'ContributeGI'

Assets\PointCloudTools\Editor\PointCloud2MeshConverter.cs(1701,83): error CS0117: 'StaticEditorFlags' does not contain a definition for 'ContributeGI'

Double click those errors in console and edit code:

fix:

// before
#if UNITY_2018_2_OR_NEWER
            GameObjectUtility.SetStaticEditorFlags(targetGO, ~StaticEditorFlags.ContributeGI);
#else
            GameObjectUtility.SetStaticEditorFlags(targetGO, ~StaticEditorFlags.LightmapStatic);
#endif
// after
#if UNITY_2019_2_OR_NEWER
            GameObjectUtility.SetStaticEditorFlags(targetGO, ~StaticEditorFlags.ContributeGI);
#else
            GameObjectUtility.SetStaticEditorFlags(targetGO, ~StaticEditorFlags.LightmapStatic);
#endif

fix2:

// before
#if UNITY_2018_2_OR_NEWER
                    GameObjectUtility.SetStaticEditorFlags(mainGO, ~StaticEditorFlags.ContributeGI);
                    GameObjectUtility.SetStaticEditorFlags(go, ~StaticEditorFlags.ContributeGI);
#endif
// after
#if UNITY_2019_2_OR_NEWER
                    GameObjectUtility.SetStaticEditorFlags(mainGO, ~StaticEditorFlags.ContributeGI);
                    GameObjectUtility.SetStaticEditorFlags(go, ~StaticEditorFlags.ContributeGI);
#endif

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions