The Immerse SDK reporting module can be optionally included in your project. This provides a facility to create customised reports, based on events that occurred during a Session.
Reporting Events
To report an event, a Session must first be joined. Once connected, it is as simple as calling a single static method ImmerseSDK.Reporting.Report.Send
Example 1
ReportCollisions.cs is an example script that will send a reporting event each time a collision occurs with another GameObject.
using ImmerseSDK.Reporting;
using UnityEngine;
/// <summary>
/// A Reporting example that captures every collision with a GameObject
/// </summary>
public class ReportCollisions : MonoBehaviour
{
/// <summary>
/// OnCollisionEnter is called when this collider/rigidbody has begun touching another rigidbody/collider
/// </summary>
private void OnCollisionEnter(Collision collision)
{
// Report the collision
Report.Send("Collision", name, collision.gameObject.name);
}
}
xAPI Data
Reporting messages can also be sent as xAPI Data , providing compatibility with common Learning Management Systems and Learning Record Stores.
using ImmerseSDK.Networking;
using ImmerseSDK.Reporting;
/// <summary>
/// Example on sending xAPI complete message with a score
/// </summary>
public void SendxApiCompleteMessage(float score)
{
if (Multiplayer.Status == ConnectionStatus.Connected)
{
var xApi = new XApiData {Completion = true, Score = score};
// The first 3 parameters of this can be customized as you like
// e.g "UserID" can be replace with Multiplayer.Session.Users.LocalUser.Id to send the local user's ID
Report.Send("Complete", "User", "UserID", xApi);
}
}
Reviewing reporting events in the Immerse SDK
To review reporting events, navigate to the Reporting tab under Immerse SDK in Unity's Project Settings and click 'Refresh' to import the latest results. A list of all recent sessions should now appear, with a unique ID and timestamp for each. Click 'Open' to see the report or 'Share...' to generate a shareable link.


Shareable reporting links for your developer session will expire after 1 hour
Updated 2 months ago