Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

unity c# log an error or warning

using UnityEngine;
using System.Collections;

public class MyGameClass : MonoBehaviour
{
    void Start()
    {
       	Debug.Log("Logging Message to Console");
    	Debug.LogWarning("Logging Warning to Console");
        Debug.LogError("Logging Error to Console");
    }
}
Comment

unity error log

using UnityEngine;

public class MyGameClass : MonoBehaviour
{

    void MyGameMethod()
    {
            Debug.LogError("error message");
            Debug.Log("message");
    }
}
Comment

PREVIOUS NEXT
Code Example
Csharp :: Celsius to Fahrenheit c# 
Csharp :: c# read file 
Csharp :: c# loop string array 
Csharp :: unity check if other object is colliding 
Csharp :: make string uppercase c# 
Csharp :: c# color hex 
Csharp :: mvc get base url 
Csharp :: disable rigidbody unity 
Csharp :: console reset color c# 
Csharp :: get last element of array c# 
Csharp :: get diff btw datetimes two C# 
Csharp :: c# csv read write 
Csharp :: unity event 
Csharp :: read all lines from txt c# 
Csharp :: ienumerable count 
Csharp :: c# get char from string 
Csharp :: see if two string arrays are equal c# 
Csharp :: unity ui movement 
Csharp :: what is type unity 
Csharp :: how to make text show a variable in unity 
Csharp :: how to get the transform of an object in unity 
Csharp :: difference between class and struct in c# 
Csharp :: roman 
Csharp :: C# how to use if and else 
Csharp :: unity deactivate component 
Csharp :: switch expression c# multiple cases 
Csharp :: relaycommand 
Csharp :: how to add headers to scripts in unity 
Csharp :: get processor id c# web application 
Csharp :: c# copy files from one folder to another 
ADD CONTENT
Topic
Content
Source link
Name
7+1 =