hadashiA / VYaml

The extra fast, low memory footprint YAML library for C#, focued on .NET and Unity.
MIT License
309 stars 19 forks source link

UnityYaml (serialized from prefab, schene, etc..) compatiblity #6

Closed hadashiA closed 1 year ago

hadashiA commented 1 year ago

Refs: https://forum.unity.com/threads/scene-files-invalid-yaml.355653/

unity auto-generated yaml includes document indicator “—“ that has invalid suffix.

%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!4 &41387171 stripped
Transform:
m_PrefabParentObject: {fileID: 476688, guid: d1cbe4ee1e40dbb46aa458321c1b846a, type: 2}
m_PrefabInternal: {fileID: 41387170}

--- !u!4 &41387171 stripped

In YAML 1.2, stripped is valid scalar. But unity seems to intend this to be just meta-information.