Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: Input System 1.9.0 does not compile on Console Platforms (ISXB-963) #1971

Merged
merged 2 commits into from
Jul 24, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
using System.Reflection;
using UnityEditor;
using UnityEditorInternal;

#endif

// This should be the only file referencing the API at UnityEngineInternal.Input.
Expand Down Expand Up @@ -394,22 +393,22 @@ public Action onProjectChange

public void SendAnalytic(InputAnalytics.IInputAnalytic analytic)
{
#if (UNITY_EDITOR)
#if (UNITY_EDITOR && ENABLE_CLOUD_SERVICES_ANALYTICS)
jfreire-unity marked this conversation as resolved.
Show resolved Hide resolved
#if (UNITY_2023_2_OR_NEWER)
EditorAnalytics.SendAnalytic(analytic);
#else
var info = analytic.info;
EditorAnalytics.RegisterEventWithLimit(info.Name, info.MaxEventsPerHour, info.MaxNumberOfElements, InputAnalytics.kVendorKey);
EditorAnalytics.SendEventWithLimit(info.Name, analytic);
#endif // UNITY_2023_2_OR_NEWER
#elif UNITY_ANALYTICS // Implicitly: !UNITY_EDITOR
#elif (!UNITY_EDITOR && ENABLE_CLOUD_SERVICES_ANALYTICS) // Implicitly: !UNITY_EDITOR
var info = analytic.info;
Analytics.Analytics.RegisterEvent(info.Name, info.MaxEventsPerHour, info.MaxNumberOfElements, InputAnalytics.kVendorKey);
if (analytic.TryGatherData(out var data, out var error))
Analytics.Analytics.SendEvent(info.Name, data);
else
Debug.Log(error); // Non fatal
#endif // UNITY_EDITOR
#endif //UNITY_EDITOR && ENABLE_CLOUD_SERVICES_ANALYTICS
}

#endif // UNITY_ANALYTICS || UNITY_EDITOR
Expand Down