Search Unity

  1. We are looking for feedback on the experimental Unity Safe Mode which is aiming to help you resolve compilation errors faster during project startup.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

BCE0005 Script errors with terrain Stitcher

Discussion in 'Editor & General Support' started by Adragen, Jun 28, 2013.

  1. Adragen

    Adragen

    Joined:
    May 4, 2013
    Posts:
    25
    Hi guys, i need to some help with some scripts as i have no idea how the code :)

    I have basically stitched 2 maps together with Terrain Stitcher and have 3 BCE0005 Errors and i have no idea how to fix them as i have no coding knowledge what so ever :)
    Here are the lines i need fixed if anyone can be so helpful,

    var terrainObjs = new Array(EditorUtility.CollectDeepHierarchy([terrain1, terrain2]));

    terrainObjs = terrainObjs.concat(new Array(EditorUtility.CollectDeepHierarchy([terrain1.terrainData, terrain2.terrainData])));

    Undo.RegisterUndo(terrainObjs.ToBuiltin(UnityEngine.Object), "Stitch Terrains")

    If anyone could point me out what needs to be fixed it would be greatly appreciated.

    Thanks in advance,
    Andrew
     
  2. Adragen

    Adragen

    Joined:
    May 4, 2013
    Posts:
    25
    Can anyone help me with this code please the first 2 lines from above have,
    BCE0005: unknown identifier: 'EditorUtility,
    and the last line has
    BCE0005: unknown identifier: Undo
    all in the error console, i really need to get these fixed so i can build it to show as a project.
    Thanks
     
  3. EssyTech

    EssyTech

    Joined:
    Jun 17, 2013
    Posts:
    9
    Place the script in the Editor folder in your project. Then it should compile.
     
unityunity