Search Unity

Unable to access UnityEditor.ProBuilder namespace in my own Editor scripts

Discussion in 'World Building' started by tomsseisums, Jul 10, 2019.

  1. tomsseisums

    tomsseisums

    Joined:
    Oct 8, 2012
    Posts:
    37
    I have a script in an Editor folder, where I attempt to reference UnityEditor.ProBuilder, but it fails with:

    Code (CSharp):
    1. The type or namespace name 'ProBuilder' does not exist in the namespace 'UnityEditor'
    I managed to get around this by creating an asmdef, that itself references UnityEditor.ProBuilder.asmdef.

    Is this the expected way of doing things? Could not find a documentation about this anywhere...
     
  2. kaarrrllll

    kaarrrllll

    Unity Technologies

    Joined:
    Aug 24, 2017
    Posts:
    552
    Yes, that is the expected path as of ProBuilder 4.0.5. The next update (4.1.0) makes ProBuilder an automatically referenced assembly, so this will no longer be necessary.
     
    tomsseisums likes this.