error CS1525:meaning Unexpected symbol '<internal>'

Asked 1 years ago, Updated 1 years ago, 33 views

Assets/Scenes/Player_NonPhysics2D.cs (42,32): error CS1525: Unexpected symbol'<internal>'

The error appears, but I don't understand what this error means.The 42nd line indicated is the return; line of the following code:

// Redrawing frames
void Update() {
    if(goalCheck){//goalCheck)
        return; // Stop processing if it is a goal

    }
}

c# unity3d

2022-09-29 20:15

2 Answers

An error has occurred because it contains at least full-width spaces.

In addition, the C# language specification specifies that blank characters in the analysis are arbitrary characters in Unicode class Zs, so full-width spaces are acceptable.This is only Unity-specific.


2022-09-29 20:15

Why don't you search for ' (full-width space)?

In line 42, there are three full-width spaces after the return.


2022-09-29 20:15

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.