Ejemplo n.º 1
0
    public void OnButton1Clicked()
    {
        Button1ClickCount++;

        // Log event by name, without data
        LogSession.Log("Button1Clicked");
    }
Ejemplo n.º 2
0
    public void OnButton3Clicked()
    {
        Button3ClickCount++;

        // Log event by type; name will be derived from class name, and object contents will be serialized into JSON data
        ButtonClicked data = new ButtonClicked("Button 3", Button2ClickCount);

        LogSession.Log(data);
    }
Ejemplo n.º 3
0
    public void OnButton2Clicked()
    {
        Button2ClickCount++;

        // Log event by name, with JSON data
        ButtonClicked data     = new ButtonClicked("Button 2", Button2ClickCount);
        string        jsonData = JsonUtility.ToJson(data);

        LogSession.Log("ButtonClicked", jsonData);
    }