diff --git a/Assets/Scripts/Roads/Node/Node.cs b/Assets/Scripts/Roads/Node/Node.cs index 954a843..b9c6bd5 100644 --- a/Assets/Scripts/Roads/Node/Node.cs +++ b/Assets/Scripts/Roads/Node/Node.cs @@ -47,8 +47,9 @@ TextMesh text = textObject.AddComponent(); text.text = ""; text.anchor = TextAnchor.MiddleCenter; + textObject.transform.localScale = Vector3.one * 0.25f; textObject.transform.parent = gameObject.transform; - textObject.transform.localPosition = new Vector3(0f, 4f, 0f); + textObject.transform.localPosition = new Vector3(0f, 3f, 0f); update(); return this; } diff --git a/Assets/Scripts/Roads/Node/Node.cs b/Assets/Scripts/Roads/Node/Node.cs index 954a843..b9c6bd5 100644 --- a/Assets/Scripts/Roads/Node/Node.cs +++ b/Assets/Scripts/Roads/Node/Node.cs @@ -47,8 +47,9 @@ TextMesh text = textObject.AddComponent(); text.text = ""; text.anchor = TextAnchor.MiddleCenter; + textObject.transform.localScale = Vector3.one * 0.25f; textObject.transform.parent = gameObject.transform; - textObject.transform.localPosition = new Vector3(0f, 4f, 0f); + textObject.transform.localPosition = new Vector3(0f, 3f, 0f); update(); return this; } diff --git a/Assets/Scripts/Roads/Node/NodeData.cs b/Assets/Scripts/Roads/Node/NodeData.cs index 3113b6f..20c117c 100644 --- a/Assets/Scripts/Roads/Node/NodeData.cs +++ b/Assets/Scripts/Roads/Node/NodeData.cs @@ -30,7 +30,11 @@ } else { node.circleObject.GetComponent().material = config.carBrakingMaterial; } - node.textObject.GetComponent().text = string.Format("phase: {0}", customNode.lightPhase); + string text = ""; + if (config.mode == Mode.TrafficLight) { + text = string.Format("phase: {0}", customNode.lightPhase); + } + node.textObject.GetComponent().text = text; Vector3 target = Camera.main.transform.position; node.textObject.transform.LookAt(-target, Vector3.up); }