Upgraded to 4.2.2f1. Mono will not compile basic code (c#).
It’s as though the compiler is not registering carriage returns/lf’s in the editor. Good clean code triggers novice errors, like forgetting ‘}’.
Apologies if repeat posting, I don’t even know how to search for an issue with a broken text compiler??
Here’s the code.
using UnityEngine;
using System.Collections;
public class PaintLine : MonoBehaviour {
// Use this for initialization
void Start () {
private LineRenderer lineRenderer;
private float counter;
private float dist;
public Transform origin;
public Transform destination;
public float lineDrawSpeed = 6f;
}
// Update is called once per frame
void Update () {
}
}
Damned upgrade… lost a few hours and more from this.
Thanks Dantus for the quick reply. I’ll remember to use tags.
Just created a new project, simplest of scripts, again, below. Still broken.
using UnityEngine;
using System.Collections;
private LineRenderer lineRenderer;
public class DrawLine : MonoBehaviour {
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
}
}
Actually… It IS your code… Do not declare private/public variables inside method…
using UnityEngine;
using System.Collections;
public class DrawLine : MonoBehaviour {
private LineRenderer lineRenderer;
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
}
}