Compiler errors

I started a new project and wrote this script:

function Update()
{
if(Input.GetButtonDown(“Jump”))
{
transform.position.z += 1.0;
}
}

I fixed all the errors in the rest of the code and tested building everything in MonoDevelop. There wasn’t any problem. But when I try to add that script to my main camera or test the game outside of MD, It tells me I have to fix all compilation errors and gives me this message in the console:

Internal compiler error. See the console log for more information. output was:Assets/Standard Assets/Scripts/General Scripts/ActivateTrigger.cs(43,58): warning CS0618: UnityEngine.GameObject.active' is obsolete: GameObject.active is obsolete. Use GameObject.SetActive(), GameObject.activeSelf or GameObject.activeInHierarchy.’
Assets/Standard Assets/Scripts/General Scripts/ActivateTrigger.cs(53,58): warning CS0618: UnityEngine.GameObject.active' is obsolete: GameObject.active is obsolete. Use GameObject.SetActive(), GameObject.activeSelf or GameObject.activeInHierarchy.’
Assets/Standard Assets/Scripts/Utility Scripts/MeshCombineUtility.cs(27,74): warning CS0618: UnityEngine.Mesh.GetTriangleStrip(int)' is obsolete: Use GetTriangles instead. Internally this function converts a list of triangles to a strip, so it might be slow, it might be a mess.’
Assets/Standard Assets/Scripts/Utility Scripts/MeshCombineUtility.cs(130,73): warning CS0618: UnityEngine.Mesh.GetTriangleStrip(int)' is obsolete: Use GetTriangles instead. Internally this function converts a list of triangles to a strip, so it might be slow, it might be a mess.’
Assets/Standard Assets/Scripts/Utility Scripts/MeshCombineUtility.cs(177,30): warning CS0618: UnityEngine.Mesh.SetTriangleStrip(int[], int)' is obsolete: Use SetTriangles instead. Internally this function will convert the triangle strip to a list of triangles anyway.’

Unhandled Exception: System.UnauthorizedAccessException: Access to the path “C:\Users\Shiloh\Documents\Spiria\Temp\Assembly-CSharp-firstpass.dll.mdb” is denied.

at System.IO.FileStream…ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) [0x00000] in :0

at System.IO.FileStream…ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean isAsync, Boolean anonymous) [0x00000] in :0

at System.IO.FileStream…ctor (System.String path, FileMode mode, FileAccess access) [0x00000] in :0

at Mono.CompilerServices.SymbolWriter.MonoSymbolWriter.WriteSymbolFile (Guid guid) [0x00000] in :0

at Mono.CSharp.SymbolWriter+SymbolWriterImpl.WriteSymbolFile () [0x00000] in :0

at Mono.CSharp.SymbolWriter.WriteSymbolFile () [0x00000] in :0

at Mono.CSharp.CodeGen.Save (System.String name, Boolean saveDebugInfo, Mono.CSharp.Report Report) [0x00000] in :0

at Mono.CSharp.Driver.Compile () [0x00000] in :0

at Mono.CSharp.Driver.Main (System.String args) [0x00000] in :0

What do I do?

What you’ve pasted is a list of warnings an errors. Your problem is the Unhandled Exception. This “Access to the path” error usually means the file is read-only, but the compiler is trying to replace it with a new version. Is your source control locking the file?

It is safe to ignore the “is obsolete” warnings, that won’t keep the game from playing correctly.