Same app, different data -> multiple apps. How?
Monkey Forums/Monkey Programming/Same app, different data -> multiple apps. How?
| ||
Here's what I want to do. I have a single set of source code. I want to create multiple apps from it by simply changing which data files are packaged with it. Obviously I can create multiple projects and folded structures and just copy the source file across to each folder every time it's changed, but is there another/better way? |
| ||
You can "hack" Monkey... I did it ages ago: http://www.monkey-x.com/Community/posts.php?topic=1020 Not sure if that code if that works anymore though... |
| ||
You're a braver man than I! I've since realised that having separate projects will be better as I'll have to configure different app names, etc. |
| ||
It probably wouldn't be outside the bounds of possibility to make something like one of those MSVC wizards that will copy files, and do the appropriate renaming and search and replace. I have found that the latter isn't too hard manually, though, when you have a consistent framework: - Copy frame folder and give it a new name - Change 'gameframe' in file and data folder names to 'newgame' - Open four files - Replace all instances of'gameframe' in files with 'newgame' - Replace all instances of 'GameFrame' in files with 'NewGame' I assume project wizards just do this kind of stuff automagically. If there were a script that could do it, people could define their own wizards. |
| ||
Symbolic link? So create "data" folder then create symbolic link called appname.data that points to the shared "data" folder. |
| ||
I've made a similar post to what I was about to post, so I'll just post that. |