From dbc38e01953ab6b496b422dfa6933b40227abcab Mon Sep 17 00:00:00 2001 From: Booklordofthedings Date: Thu, 26 Sep 2024 14:32:37 +0200 Subject: [PATCH] Add Bofa.Deserialize --- src/Bofa.bf | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Bofa.bf b/src/Bofa.bf index aeb0277..03371c4 100644 --- a/src/Bofa.bf +++ b/src/Bofa.bf @@ -14,6 +14,16 @@ class Bofa public StringView Typename; public BofaValue Value; + public static bool Deserialize(ref T pType, Dictionary pDictionary) where T : Bofa.Serialization.IBofaParseable + { + Bofa b = scope .(); + b.Type = .Object; + b.Value.Object = pDictionary; + + defer {b.Type = .Integer;} + return pType.Deserialize(b); + } + public override void ToString(String strBuffer) { int64 depth = 0;