Unity-Technologies/UnityCsReference · error · NotSupportedException

PlayerSettings.packageLogo240 is deprecated. Use GetVisualAs

Error message

PlayerSettings.packageLogo240 is deprecated. Use GetVisualAssetsImage() instead.

What it means

PlayerSettings.WSA.packageLogo240 was a string property that retrieved the UWP package logo image path at 240% scale. Unity replaced all per-scale visual asset getters with GetVisualAssetsImage(WSAImageType, WSAImageScale). The [Obsolete(..., true)] attribute blocks direct compilation; the NotSupportedException fires for reflection-based reads.

Source

Thrown at Editor/Mono/PlayerSettingsWSA.cs:737

            public static string packageLogo180
            {
                get
                {
                    throw new NotSupportedException("PlayerSettings.packageLogo180 is deprecated. Use GetVisualAssetsImage() instead.");
                }
                set
                {
                    throw new NotSupportedException("PlayerSettings.packageLogo180 is deprecated. Use SetVisualAssetsImage() instead.");
                }
            }

            [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
            [Obsolete("Use GetVisualAssetsImage()/SetVisualAssetsImage()", true)]
            public static string packageLogo240
            {
                get
                {
                    throw new NotSupportedException("PlayerSettings.packageLogo240 is deprecated. Use GetVisualAssetsImage() instead.");
                }
                set
                {
                    throw new NotSupportedException("PlayerSettings.packageLogo240 is deprecated. Use SetVisualAssetsImage() instead.");
                }
            }

            [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
            [Obsolete("PlayerSettings.enableLowLatencyPresentationAPI is deprecated. It is now always enabled.", true)]
            public static bool enableLowLatencyPresentationAPI
            {
                get
                {
                    return true;
                }
                set
                {
                }

View on GitHub (pinned to 225b0fbdb5)

Solutions

  1. Replace the getter with PlayerSettings.WSA.GetVisualAssetsImage(WSAImageType.PackageLogo, WSAImageScale._240)
  2. Migrate to UWP-supported scales (_100, _125, _150, _200, _400) since _240 is deprecated for UWP
  3. Update reflection-based code to call the method API directly

Example fix

// before
string logo = PlayerSettings.WSA.packageLogo240;

// after
string logo = PlayerSettings.WSA.GetVisualAssetsImage(WSAImageType.PackageLogo, WSAImageScale._200);
Defensive patterns

Strategy: validation

Validate before calling

var prop = typeof(PlayerSettings.WSA).GetProperty("packageLogo240");
if (prop?.GetCustomAttribute<System.ObsoleteAttribute>()?.IsError == true)
    Debug.LogError("Property is obsolete. Use GetVisualAssetsImage() instead.");

Try / catch

try { /* deprecated getter via reflection */ }
catch (NotSupportedException ex) when (ex.Message.Contains("GetVisualAssetsImage"))
{ Debug.LogError("Migrate to GetVisualAssetsImage()."); }

Prevention

When it happens

Trigger: Reading PlayerSettings.WSA.packageLogo240 via reflection (PropertyInfo.GetValue), dynamic dispatch, or a legacy compiled assembly calling the getter.

Common situations: Editor tools that read and validate package logo configuration at high DPI scales. Legacy project inspection scripts. Plugins targeting pre-2018 Unity API.

Related errors


AI-assisted analysis of Unity-Technologies/UnityCsReference@225b0fbdb5 (2026-08-13). Data as JSON: /api/errors/e3465c1dec7e994d. Report an issue: GitHub.