Search Unity

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.