I know in languages like Java you have GSON or in C# you have Newtonsoft-JSON which allows you to parse whole Objects into JSON and back.
Now, I created a little script called NetPacket.gd with this content:
var data = 
I preloaded this in my root node and created an instance of it with the ".new()" method.
Then I filled the type and data from the root node. In the next step I´d like to convert the NetPacket to a json String and send it to my server. I can create a JSON String of the array inside the NetPacket by calling
but then I´d have to do this multiple times in order to get the the whole object parsed.
Is there a way to do it faster and in one step ?