- Home /
Unable to overcome Assembly-CSharp.csproj assembly Error
I have been having the same script compilation error as many other people on this forum, however, using the answers I came to the conclusion that it was the compile file that was the issue. So when I opened up Visual Studio I simply saved the project name as the main file name of the project I was working on. It worked, it actually saved as a new .csproj file type. However, the script itself still showed the file path of Assembly-CSharp.dll which is what was causing my issue.
The other infuriating aspect is whenever I reopen the project in unity it defaults back to and recreates the Assembly-CSharp.csproj file and does not allow me to change it under any circumstances. I am 100% positive everything else in the code is correctly formatted, whether or not the code itself will do what I want it to do is NOT the issue. This problem persisted even with free to test program files that were tested in Unity before.
The code is formatted as follows
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Movement : MonoBehaviour
{
void Update()
{
if (GetComponent<Health>().current > 0)
{
if (clickedSomewhere())
{
moveToDestination();
}
}
}
}
I saved the .cs file name as the Class name, I ensured MonoBehaviour was spelled with the "u", I even tried replacing the colon with "extends" to see if it was a programming language error. Absolutely nothing I have attempted has resolved this issue and it is getting very frustrating to attempt to use this program to even learn how to program let alone have a functional piece of software when all is said and done.
Hi $$anonymous$$ate,
Did you fix it ? I have same problem and i couldnt find any solution since 1 week.
can you show the error and where in your code it's breaking I don't really know what the issue you are having is, are you sure there is a health stript on the object? what are cickedSomewhere() and moveToDestination()? where is that code?
Your answer
![](https://koobas.hobune.stream/wayback/20220612222003im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
can mono touch be used to make unity iPhone plugins 0 Answers
how to select which object i want to use in itween C# 0 Answers
Problem with 3D platform tutorial 2 Answers
AssetPostprocessor (in dll) doesn't work when there's a compiler error in another script 0 Answers
I test to build a WebGL app and got a compiler error 0 Answers