TheDudeFromCI / Bones3

Bones³ is a Voxel Editor for Unity. Supports both in-game and in-editor building.
MIT License
58 stars 12 forks source link

Move Save folder Into Assets #9

Open TheDudeFromCI opened 4 years ago

TheDudeFromCI commented 4 years ago

The save folder for world data was originally saved outside of the asset folder to prevent it from being targeted by the asset database. However, it would be better to save the worlds inside the asset folder, (as to be more uniform with the standard Unity workflow) while using ~ in the folder name. The Unity Asset Database ignores folders with names ending in ~, so there's no need to worry about "reimporting" the files when the world saves or generating metafiles.

TheDudeFromCI commented 4 years ago

In order to copy the world data to the build client, it would also be a good idea to place the folder inside the StreamingAssets folder in order to have them copied to the BuildData folder when the project is built.

A runtime script can then be written to copy world data from the streaming asset path to the persistant data path if the world is edited and saved in the build.