|
|
|
|
|
|
/// <param name="data">Payload of the event.</param>
|
|
|
|
static void SendPerceptionAnalyticsEvent(AnalyticsEvent theEvent, object data) |
|
|
|
{ |
|
|
|
try |
|
|
|
{ |
|
|
|
if (theEvent.type == AnalyticsEventType.Editor || theEvent.type == AnalyticsEventType.RuntimeAndEditor) |
|
|
|
{ |
|
|
|
EditorAnalytics.SendEventWithLimit(theEvent.name, data, theEvent.versionId); |
|
|
|
} |
|
|
|
if (theEvent.type == AnalyticsEventType.Editor || theEvent.type == AnalyticsEventType.RuntimeAndEditor) |
|
|
|
{ |
|
|
|
EditorAnalytics.SendEventWithLimit(theEvent.name, data, theEvent.versionId); |
|
|
|
} |
|
|
|
#else
|
|
|
|
if (theEvent.type == AnalyticsEventType.Runtime || theEvent.type == AnalyticsEventType.RuntimeAndEditor) |
|
|
|
{ |
|
|
|
|
|
|
} |
|
|
|
catch (Exception exc) |
|
|
|
{ |
|
|
|
Debug.Log($"Unable to report ${theEvent.name}: {exc.Message}"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
#endregion
|
|
|
|