Unity-Technologies/UnityCsReference · error · NotSupportedException
PlayerSettings.phoneAppIcon240 is deprecated. Use GetVisualA
Error message
PlayerSettings.phoneAppIcon240 is deprecated. Use GetVisualAssetsImage() instead.
What it means
PlayerSettings.WSA.phoneAppIcon240 is a deprecated static property getter that always throws NotSupportedException. The 240% scale Windows Phone app icon property was replaced by GetVisualAssetsImage(WSAImageType, WSAImageScale) with type WSAImageType.UWPSquare44x44Logo. It is [Obsolete(..., true)] and [EditorBrowsable(Never)].
Source
Thrown at Editor/Mono/PlayerSettingsWSA.cs:527
public static string phoneAppIcon140
{
get
{
throw new NotSupportedException("PlayerSettings.phoneAppIcon140 is deprecated. Use GetVisualAssetsImage() instead.");
}
set
{
throw new NotSupportedException("PlayerSettings.phoneAppIcon140 is deprecated. Use SetVisualAssetsImage() instead.");
}
}
[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
[Obsolete("Use GetVisualAssetsImage()/SetVisualAssetsImage()", true)]
public static string phoneAppIcon240
{
get
{
throw new NotSupportedException("PlayerSettings.phoneAppIcon240 is deprecated. Use GetVisualAssetsImage() instead.");
}
set
{
throw new NotSupportedException("PlayerSettings.phoneAppIcon240 is deprecated. Use SetVisualAssetsImage() instead.");
}
}
[System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
[Obsolete("Use GetVisualAssetsImage()/SetVisualAssetsImage()", true)]
public static string phoneSmallTile
{
get
{
throw new NotSupportedException("PlayerSettings.phoneSmallTile is deprecated. Use GetVisualAssetsImage() instead.");
}
set
{
throw new NotSupportedException("PlayerSettings.phoneSmallTile is deprecated. Use SetVisualAssetsImage() instead.");View on GitHub (pinned to 225b0fbdb5)
Solutions
- Replace with PlayerSettings.WSA.GetVisualAssetsImage(WSAImageType.UWPSquare44x44Logo, WSAImageScale._200) — the 240% legacy scale maps closest to UWP _200.
- Audit and migrate all phoneAppIcon240 references.
- Update plugin DLLs that reference the deprecated getter.
Example fix
// before string path = PlayerSettings.WSA.phoneAppIcon240; // after string path = PlayerSettings.WSA.GetVisualAssetsImage(WSAImageType.UWPSquare44x44Logo, WSAImageScale._200);
Defensive patterns
Strategy: type-guard
Validate before calling
// Use the new getter for app icon at ~240% scale string path = PlayerSettings.WSA.GetVisualAssetsImage(WSAImageType.UWPSquare44x44Logo, WSAImageScale._200);
Type guard
static bool IsDeprecatedWsaProperty(string name) =>
typeof(PlayerSettings.WSA)
.GetProperty(name,
System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Static)
?.GetCustomAttribute<ObsoleteAttribute>()?.IsError == true; Prevention
- Map legacy 240% app icon scale to WSAImageScale._200 (the closest UWP scale).
- Filter deprecated properties during reflection-based enumeration of PlayerSettings.WSA.
- Search for 'phoneAppIcon240' after Unity version upgrades.
When it happens
Trigger: Reading PlayerSettings.WSA.phoneAppIcon240 (the getter) in editor scripts, build reports, or configuration readers. Direct access fails to compile; runtime hits come from reflection or SerializedProperty traversal.
Common situations: Upgrading from a Windows Phone 8.1-era Unity project to UWP; plugins that read multi-scale app icon paths; build scripts that export current WSA configuration.
Related errors
- PlayerSettings.phoneAppIcon is deprecated. Use GetVisualAsse
- PlayerSettings.phoneAppIcon is deprecated. Use SetVisualAsse
- PlayerSettings.phoneAppIcon140 is deprecated. Use GetVisualA
- PlayerSettings.phoneAppIcon140 is deprecated. Use SetVisualA
- PlayerSettings.storeSmallTile180 is deprecated. Use SetVisua
AI-assisted analysis of Unity-Technologies/UnityCsReference@225b0fbdb5 (2026-08-13).
Data as JSON: /api/errors/92860a7a35cab482.
Report an issue: GitHub.