unity-coding-data

Implements UniT.Data IDataManager save/load with JSON, MessagePack, MemoryPack serializers and PlayerPrefs, Assets, External file storage in Unity C# projects.

Updated Aug 20, 2025
One-click install
npx skills add https://github.com/frostbun/dotfiles --skill unity-coding-data
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: unity-coding-data
Source: https://github.com/frostbun/dotfiles/tree/main/configs/opencode/skills/unity/unity-coding-data
Command: npx skills add https://github.com/frostbun/dotfiles --skill unity-coding-data

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill simplifies and standardizes the implementation of data persistence in Unity C# projects, covering everything from saving game state to loading complex data structures.

Core Features & Use Cases

  • Data Management: Provides an IDataManager for robust save/load operations.
  • Serialization: Supports JSON, MessagePack, and MemoryPack for flexible data serialization.
  • Storage Options: Integrates with PlayerPrefs, Assets, and external files for diverse storage needs.
  • Use Case: Effortlessly save player progress, inventory, and settings using various serialization formats and storage backends.

Quick Start

Use the unity-coding-data skill to save the current game data for the 'GameData' type.

Frequently Asked Questions about unity-coding-data

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I save and load game state in Unity using C#?

To save and load game state in Unity, use an IDataManager interface handling serialization and storage. This standardizes saving player progress, inventory, and settings using robust save and load operations across various storage providers.

What is the best way to serialize data in Unity for player preferences?

The best way to serialize data in Unity is using flexible formats like JSON, MessagePack, or MemoryPack. These allow you to efficiently manage user preferences and complex data structures across different storage backends.

Does Unity data persistence work with external files and PlayerPrefs?

Unity data persistence works directly with PlayerPrefs, project Assets, and external files. This integration allows developers to choose appropriate storage providers based on specific game configuration and save data requirements.

Can I use CSV data types for loading configuration files in Unity?

Yes, you can use CSV data types with specific attributes for loading configuration files in Unity. This method includes type conversion features to accurately parse and manage complex data structures into your game.

How does the UniT.Data package handle type conversion for save data?

The UniT.Data package handles type conversion by applying specific attributes to CSV data types. This ensures serialized data is accurately mapped and converted when saving or loading game state across different formats.

When should I use MemoryPack instead of JSON for Unity data serialization?

Use MemoryPack instead of JSON for Unity data serialization when you need higher performance for complex data structures. JSON remains suitable for readable configurations, while MemoryPack optimizes saving larger game states efficiently.