DirectoryNotFoundException in published PC version, not when testing in editor
Hi all (my first question on here!)
I'm using this code to get all of the scene files in my scenes folder:
DirectoryInfo dir = new DirectoryInfo(Application.dataPath+"/Scenes/");
And this works great when I test in editor, but when i publish my game and test that, I get:
"DirectoryNotFoundException: Directory '(myprojectdirectory...)[...]_Data\Scenes' not found"
Which makes sense because when I publish my game and go to that folder, the Scenes folder isn't there (along with all my other folders in my project Assets folder). They're presumably compiled into some other files / format.
So what file / folder structure, if any, are my Assets folders converted into when I publish the game to PC? How can I access them (to dynamically create menu content based on Scenes I've created for different levels in my game), via "Application.dataPath", etc?
Hope this is enough info - thanks in advance.