Sorry, why do you check for a file JP? You might as well just changedir to the correct directory regardless of whether it's already set or not, surely? It's a win-win situation.
Because when you run your code from the IDE Appdir will be the Blitz dir not your game folder. It's written this way so you can just forget about it rather than having different code depending on how you run it.