Here is the new script
I actually have a question, although I don’t know if this is the right place to ask. Is there a reason why, in my screenshot and in others that use the \n to create a new line, the message “UnityEngine.MonoBehaviour:print(Object)” does not appear??
I feel like it’s a silly question but it’s bugging me that I don’t know!
YARGH! I knew I was using this forum wrong. HERE is the link to where I accidentally incorrectly posted this!
Here are the console results.
Yes i found that lacking in mine but a good touch
Here is my GoHome script:
public class ConsolePrinter : MonoBehaviour {
// Use this for initialization
void Start () {
print("Hello World!");
print("It's great to see you again.");
}
// Update is called once per frame
void Update () {
}
}
using UnityEngine;
using System.Collections;
public class ConsolePrint : MonoBehaviour {
// Use this for initialization
void Start () {
print ("Welcome to Go Home \n Next Line?");
}
// Update is called once per frame
void Update () {
}
}
Output:
Welcome to Go Home
Next Line?
UnityEngine.MonoBehaviour:print(Object)
ConsolePrint:Start() (at Assets/ConsolePrint.cs:8)
Here is my print statement. I’m glad to learn that (at least) some of the coding in java translates into C#.
The \n is telling the console that the third string should start on a new line. So I guess there is at least two options to writing multiple lines, using a command or manually printing multiple strings.