PlayerPrefsRuntime Tool is a Unity plugin that allows you to retrieve all PlayerPrefs at runtime across multiple platforms, including Android, iOS, Windows, and macOS.Tool using Newtonsoft.Json that comes with the packagePlayerPrefsRuntime Toolversion 2.0OverviewPlayerPrefsRuntime Tool is a Unity plugin that allows you to retrieve all PlayerPrefs at runtime across multiple platforms, including Android, iOS, Windows, and macOS. This tool is invaluable for debugging, analytics, and ensuring the integrity of player preferences within your Unity projects.FeaturesCross-Platform Support: Compatible with Android, iOS, Windows, and macOS.Runtime Access: Retrieve all PlayerPrefs as a dictionary directly from the device for easy manipulation.Logging: Display all PlayerPrefs data in the Unity Console for debugging purposes.Interactive UI Viewer: Visual interface with search, sorting, and detailed entry inspection.Extensible Architecture: Easily extendable to support additional platforms or functionalities.UI Viewer FeaturesThe PlayerPrefsRuntime Tool includes a comprehensive visual UI viewer that provides:Real-time Search & FilteringLive search across key names, types, and valuesClear button to reset searchShows filtered count vs total count in headerSorting CapabilitiesToggle between "Sort: Name" and "Sort: Type" modesSecondary sorting (type within name, or name within type)Alphabetical ordering using ordinal comparisonVisual Design & ThemingDark theme with accent colors (blues, cyans)Alternating even/odd row colors for readabilityColor-coded type badges (Int, String, Float)Interactive rows with hover effectsSafe area support for mobile devicesInteractive FeaturesClick on any entry to view detailed information in a dialogClose button to hide the viewer and clean up resourcesSort button to toggle between sorting modesSearch field with placeholder textNotes & LimitationsWindows builds decode the PlayerPrefs registry entries Unity writes. Standard int, float, and string keys are returned; values stored in any other registry format are skipped and reported in a single aggregated warning so logs stay readable.iOS/macOS rely on a native JSON export. The helper normalizes numeric types back to Unity-friendly values (e.g. large long stay long, doubles collapse to float), so downstream code sees the usual PlayerPrefs types.Define PLAYER_PREFS_RUNTIME_TOOL only for targets where the native bridge or registry access exists; editor playback will safely fall back to empty results.The UI Viewer is automatically disabled in editor playback mode and will show an empty state with a message indicating that PlayerPrefs are not accessible in the editor.Platform Support DetailsPlatformImplementationUI ViewerMethodAndroidSharedPreferences via AndroidJavaObject✅RuntimeiOSNative P/Invoke to iOS key-value store✅RuntimemacOSNative P/Invoke to macOS preferences✅RuntimeWindowsRegistry access with binary parsing✅RuntimeEditor (Win)Registry access✅Editor onlyEditor (Mac)plist file parsing✅Editor onlyPlatform-Specific Features:Android:Accesses SharedPreferences using package nameHandles URI-encoded keys and valuesSupports standard int, float, string typesiOS/macOS:Native JSON export via P/InvokeRequires native plugins in Assets/Plugins/Handles binary data and complex typesWindows:Registry-based access at Software\{company}\{product}Custom binary parsing for Unity's PlayerPrefs formatSupports int, float, string, and binary dataData Type Handling:Automatic normalization across platformsType consistency: Ensures long→int, double→float conversionsBinary data support: Base64 encoding/decoding where neededNull safety: Graceful handling of missing or corrupted data1. Enable the ToolTo enable the PlayerPrefsRuntime Tool, define the PLAYER_PREFS_RUNTIME_TOOL scripting symbol:Go to Edit > Project Settings > Player. Under the Other Settings tab, find Scripting Define Symbols. Add PLAYER_PREFS_RUNTIME_TOOL to the list, separated by a semicolon if other symbols are present.2. UI Viewer Setup (Optional)📷The UI Viewer is automatically configured and requires no additional setup. However, you can customize the appearance by modifying the PlayerPrefsRuntimeViewConstants.cs file:Color Customization:Panel colors: PanelColor, HeaderColor, AccentColorRow colors: RowColorEven, RowColorOddText colors: ValueTextColor, BadgeLabelColorControl colors: ControlNormalColor, CloseButtonNormalColorLayout Customization:Row dimensions: RowMinHeight, RowSpacing, RowPaddingHorizontalFont sizes: NameFontSize, ValueFontSize, BadgeFontSizeText limits: MaxNameTextLength, MaxValueTextLengthPerformance Settings:Scroll sensitivity: ScrollSensitivityScroll deceleration: ScrollDecelerationRateCanvas scaling: CanvasMatchWidthOrHeightThe UI Viewer automatically creates required components (Event System, Canvas) if they don't exist.UsageBasic API Usageusing System.Collections.Generic;using UnityEngine;using DmytroUdovychenko.PlayerPrefsRuntimeTool;public class PlayerPrefsRuntimeExample : MonoBehaviour{private void Start(){#if PLAYER_PREFS_RUNTIME_TOOL// Add test data for demonstrationPlayerPrefsRuntime.AddTestPlayerPrefs();// Log all PlayerPrefs to consolePlayerPrefsRuntime.LogAllPlayerPrefs();// Retrieve all PlayerPrefs as Dictionary Dictionary allPrefs = PlayerPrefsRuntime.GetAllPlayerPrefs();// Show the interactive UI viewerPlayerPrefsRuntime.ShowAllPlayerPrefs();#endif}}Demo SceneThe included demo scene (Assets/DmytroUdovychenko/PlayerPrefsRuntimeTool/Demo/DemoScene.unity) showcases:Test Data GenerationString types: Short, medium, long, very long (100+ lines), Unicode (Russian, Japanese)Numeric types: Integers (positive, negative, zero), Floats (small, large, decimal)Special cases: JSON data, empty values, keys with special charactersInteractive DemoPress "P" key to toggle viewer visibilityAutomatically shows viewer after 0.5s delay on startDemonstrates complete workflow: add data → retrieve → displayKey Demo FeaturesHandling of Unicode and special charactersLarge dataset performance (100+ entries)Cross-platform data consistencySearch and sorting with diverse data typesTo use the demo:Open the demo scenePress Play in the Unity EditorPress "P" to toggle the UI viewerUse search and sort features to explore the data