Edit: A wrong-headed question that I wish I could delete.

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By jerryjrowe

EDIT : This whole question is wrong-headed. For some reason one of my folders (full of custom data, like saved game data and character data, saved as a single string – a dictionary changed via var_to_str – in custom file formats) is not seen at all by my exported projects. Thus, I will be asking a new question----but I do not know how to remove this very bad question. My apologies.

Original question : Upon exporting a project, DirAccess/FileAccess do not work. What do I replace them with?

Original body:

I made a game that makes a lot of use of DirAccess and FileAccess.

I have a folder full of other folders, each with their own kind of special data (all of which are just dictionaries, saved as a string).

For instance, res://Serialized/Creatures and res://Serialized/Hazards and so on. Each folder has dozens of individual files.

After exporting, nothing works. For instance, DirAccess cannot find the res://Serialized folder.

I thought I might be able to replace DirAccess / FileAccess with ResourceLoader, but ResourceLoader only seems to be able to find normal file types, as opposed to these dictionaries that I saved as a single large string, that I convert using str_to_var when I load them with FileAccess. (For instance, res://Serialized/Creatures/Wizard.stats doesn’t work.)

Does anyone know how to locate / iterate on directories or files in an exported project?
Or how to open custom file types that were saved with FileAccess.WRITE and store_line()?

but I do not know how to remove this very bad question.

To “remove” a question, press the forum’s Hide button…

jgodfrey | 2023-05-16 02:02

:bust_in_silhouette: Reply From: jerryjrowe

I…found at least one of the problems.

But I’m even more baffled now.

The entire Serialized folder is not even exporting.

When I use DirAccess to look at all folders, I can make it see every other folder, but not Serialized (which is full of folders, and each folder is full of custom save data).

So it would seem my entire question is just wrong. FileAccess and DirAccess do work, it would seem, but…exporting of custom data seems to be the problem?