–5 votes

i made a 83x9 array to Save values {83 Slots, 9 Variables}
when i turn an array into a File. it loses it's array properties, so it stores it like normal (0,0,0,0,0,0,0,0,0) instead of an array [0,0,0,0,0,0,0,0,0] {i found this out by using C++}

so this maybe basic coding, but i dunno how you separate (0,0,0,0,0,0,0,0,0) into 9 variables

can't index or resize a File.

Edit: i found out the Godot doesn't know what something like (10,0,1000,0,0,0,100,0,0) is. so it assumes you want (1110). meaning unless i do something silly like (1000000100000000010000000000000) i can't separate it

{btw it's been 2~3 hours and this question has still not been approved}

Edit2: 4 hours

Edit3: i solved it myself

Godot version 3.2?
in Engine by (9 points)
edited by

1 Answer

0 votes

Congrats on solving your issue.
If you would, please share here so that others with the same or similar problems can access it.

If your saved file is only being used in Godot use var2str() and str2var() respectively to save and load

Manipulations otherwise use File store_buffer()

by (6,876 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.