docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class ProBuilderEditor

    Manages the ProBuilder toolbar and tool mode.

    Inheritance
    object
    ProBuilderEditor
    Implements
    IDisposable
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEditor.ProBuilder
    Assembly: Unity.ProBuilder.Editor.dll
    Syntax
    public sealed class ProBuilderEditor : IDisposable

    Properties

    instance

    Declaration
    public static ProBuilderEditor instance { get; }
    Property Value
    Type Description
    ProBuilderEditor

    selectMode

    Gets and sets the current SelectMode value.

    Declaration
    public static SelectMode selectMode { get; set; }
    Property Value
    Type Description
    SelectMode

    Methods

    Dispose()

    Declaration
    public void Dispose()

    OnSceneGUI(SceneView)

    Declaration
    public void OnSceneGUI(SceneView sceneView)
    Parameters
    Type Name Description
    SceneView sceneView

    Refresh(bool)

    Rebuilds the mesh wireframe and selection caches.

    Declaration
    public static void Refresh(bool vertexCountChanged = true)
    Parameters
    Type Name Description
    bool vertexCountChanged

    True if the number of vertices changed, which is the default value.

    Events

    afterMeshModification

    Raised when vertex modifications are complete.

    Declaration
    public static event Action<IEnumerable<ProBuilderMesh>> afterMeshModification
    Event Type
    Type Description
    Action<IEnumerable<ProBuilderMesh>>

    beforeMeshModification

    Raised immediately prior to beginning vertex modifications, when the ProBuilderMesh is in un-altered state. This is after ToMesh(MeshTopology) and Refresh(RefreshMask) have been called, but before Optimize(ProBuilderMesh, bool).

    Declaration
    public static event Action<IEnumerable<ProBuilderMesh>> beforeMeshModification
    Event Type
    Type Description
    Action<IEnumerable<ProBuilderMesh>>

    selectModeChanged

    Raised when the EditLevel changes.

    Declaration
    public static event Action<SelectMode> selectModeChanged
    Event Type
    Type Description
    Action<SelectMode>

    selectionUpdated

    Raised any time the ProBuilder editor refreshes the selection. This is called every frame when interacting with mesh elements, and after any mesh operation.

    Declaration
    public static event Action<IEnumerable<ProBuilderMesh>> selectionUpdated
    Event Type
    Type Description
    Action<IEnumerable<ProBuilderMesh>>

    Implements

    IDisposable
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)