|
@@ -1013,6 +1013,8 @@ public static class TalkingDataSDK
|
|
|
public static void OnEvent(string eventId, Dictionary<string, object> parameters,
|
|
public static void OnEvent(string eventId, Dictionary<string, object> parameters,
|
|
|
Dictionary<string, object> eventValue)
|
|
Dictionary<string, object> eventValue)
|
|
|
{
|
|
{
|
|
|
|
|
+ if (talkingdataClass == null)
|
|
|
|
|
+ return;
|
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
|
{
|
|
{
|
|
|
#if UNITY_ANDROID
|
|
#if UNITY_ANDROID
|
|
@@ -1045,6 +1047,8 @@ public static class TalkingDataSDK
|
|
|
/// </summary>
|
|
/// </summary>
|
|
|
public static void OnError(string message, string stackTrace, LogType logType)
|
|
public static void OnError(string message, string stackTrace, LogType logType)
|
|
|
{
|
|
{
|
|
|
|
|
+ if (talkingdataClass == null)
|
|
|
|
|
+ return;
|
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
|
{
|
|
{
|
|
|
#if UNITY_ANDROID
|
|
#if UNITY_ANDROID
|
|
@@ -1065,6 +1069,8 @@ public static class TalkingDataSDK
|
|
|
/// </summary>
|
|
/// </summary>
|
|
|
public static void ReportException(System.Exception exception)
|
|
public static void ReportException(System.Exception exception)
|
|
|
{
|
|
{
|
|
|
|
|
+ if (talkingdataClass == null)
|
|
|
|
|
+ return;
|
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
if (Application.platform != RuntimePlatform.OSXEditor && Application.platform != RuntimePlatform.WindowsEditor)
|
|
|
{
|
|
{
|
|
|
#if UNITY_ANDROID
|
|
#if UNITY_ANDROID
|
|
@@ -1091,6 +1097,8 @@ public static class TalkingDataSDK
|
|
|
/// <param name="enabled">true:开启, false:关闭</param>
|
|
/// <param name="enabled">true:开启, false:关闭</param>
|
|
|
public static void SetReportUncaughtExceptions(bool enabled)
|
|
public static void SetReportUncaughtExceptions(bool enabled)
|
|
|
{
|
|
{
|
|
|
|
|
+ if (talkingdataClass == null)
|
|
|
|
|
+ return;
|
|
|
try
|
|
try
|
|
|
{
|
|
{
|
|
|
talkingdataClass.CallStatic("setReportUncaughtExceptions", enabled);
|
|
talkingdataClass.CallStatic("setReportUncaughtExceptions", enabled);
|