You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe this is an error in the VDF file itself if it uses escape sequences. It should have been written as "some\\text" and would have been parsed correctly.
However, Valve's own VDF parser has an option to disable escape sequences. So it's possible some VDF files just don't support them. In this library, support for escape sequences is enabled by default, but this can be changed by setting UsesEscapeSequences to false. Or simply by using var config = VdfConvert.Deserialize(text, VdfSerializerSettings.Default);.
The naming for the two VdfSerializerSettings might seem counter-intuitive since VdfSerializerSettings.Default is actually not the default, but rather VdfSerializerSettings.Common. This is because VdfSerializerSettings.Default refers to the defaults in Valve's own VDF parser, not the defaults of this library. In my experience, it's far more common for users to encounter VDF files that use escape sequences, so the default of this library is VdfSerializerSettings.Common instead.
When I try to parse text:
With code:
Value "Games" is parsed as "some\text" instead of "some\\text" (if you "Console.Write" this you get "some ext").
The text was updated successfully, but these errors were encountered: