diff --git a/docs/platforms/unity/configuration/il2cpp/index.mdx b/docs/platforms/unity/configuration/il2cpp/index.mdx index 8f1e370bce78b3..559d2f912de978 100644 --- a/docs/platforms/unity/configuration/il2cpp/index.mdx +++ b/docs/platforms/unity/configuration/il2cpp/index.mdx @@ -18,14 +18,16 @@ The Sentry SDK provides line number support for IL2CPP builds for the following When you build with IL2CPP, errors in your game will happen in the native code. Also, the mapping between your C# code and the generated C++ code is part of the build process and isn't shipped with your game. That means the event the Sentry SDK reports can only contain the native stack trace. To provide you with C# line numbers, the Sentry server needs to have access to that line mapping through [Debug Information Files](/platforms/unity/data-management/debug-files/). -This feature is enabled by default. You can opt out of it through the editor configuration window by selecting **Tools -> Sentry -> Advanced -> IL2CPP line numbers** or [programmatically](/platforms/unity/configuration/options/#programmatic-configuration). +The support for line numbers in C# Exceptions with IL2CPP relies on the debug symbol upload. +With the automated debug symbol upload enabled, the [Sentry SDK will upload the line mapping automatically](/platforms/unity/native-support/#debug-symbols). + +**This feature is enabled by default**. You can opt out of it through the editor configuration window by selecting **Tools -> Sentry -> Advanced -> IL2CPP line numbers** or [programmatically](/platforms/unity/configuration/options/#programmatic-configuration). ```csharp +// If you need to disable this feature, you can set it to 'false': options.Il2CppLineNumberSupportEnabled = false; ``` -The support for line numbers in C# Exceptions with IL2CPP relies on the debug symbol upload. With the automated debug symbol upload enabled, the [Sentry SDK will upload the line mapping automatically](/platforms/unity/native-support/#debug-symbols). - ### Known Limitations Currently, line number support is limited when programmatically subscribing to button click events via `Button.onClick.AddListener`. However, you can set up callbacks through the editor to work around this.