So, how do you version and organize your adventures?

Started by fernewelten, Sun 15/08/2021 02:59:49

Previous topic - Next topic

fernewelten

I'm not quite sure where to put this, so I'm going to put this here.

I started out without using any source control whatsoever. My games all had an "_Assets" folder within the main game folder that contained all the assets and their respective source files for the game.

For backups and intermediate states, I simply copied all the whole main game folder with all its files to an USB stick into a suitably named folder ("AGS/TheSpecificGame/1999-12-04a/" and such). Nowadays, sticks have so much memory that a single stick will have storage for many saves even if you blindly copy all the files. And my computer itself is set up with an automatic backup system that does regular saves, so this simple system was enough to guarantee that I'd never lose more than a few hour's work in case of a system failure. That was sufficient for the typical month-long jam.

Trouble is, by now i've written several adventures, and this simple system has rapidly come to its limits.

By now,

  • The different adventures have their own assets (of course)
  • but they also share some assets, particularly background music, sounds, fonts, cursor sprites, and character sprites.
  • Shared assets evolve at a different pace from the games that use them. They've become separate, independent entities with their own version progression.
  • The adventures and assets have been written with different AGS versions. Different versions aren't always freely exchangeable, due to their file format: If GUIs or (I think) modules have been saved with a specific AGS version, they won't be importable into an AGS that is older. If I don't want to be forced to upgrade the whole game just because I need to fix something tiny, I need to juggle with different save formats.
  • Due to space constraints, my games proper have ended up at a different place from the shared assets, on another volume even.

Simply "saving everything" won't cut it any longer, it's no longer error-proof when different shared assets in different places are involved.

Just source controlling the game would similarly not be good enough; how do I keep the shared files in sync that reside in different locations, even on a different volume?

Putting a copy of the shared assets into the individual games is ugly, too. Then if the copy of the assets is modified/improved, these modifications might get lost on the original shared asset.

So something must come; I haven't a clear idea what exactly.

What system have you come up with to keep track of all your sprites, pics, and sources?

BTW. I'm noticing that the AGS documentation on source control discusses SourceSafe (that I've never heard of) but not git. AGS doesn't detect git either although git is indeed installed on my box and integrated into Visual Studio.




Alan v.Drake

You could use a junction or symbolic link to point all the shared folders to a single source of truth. Linking them through different volumes is allowed, unlike hard-links.

- Alan

deadsuperhero

So, what I ended up doing is that I put each game into its own Git repository, for version control purposes. This ensures that I can easy download the last working version of my game and its source code if a major catastrophe happens with my computer.
Basically, I just use git functions from the command line, and create commits in a local directory before pushing them up to a remote branch.

In other words, I do this:

0. Save my work in the editor and close it.

1. Add any changes from my game's directory that might have been changed
Code: ags
git add .


2. Create a commit detailing what I did
Code: ags
git commit -m 'Add new scene in bar'


3. Push that code to a repo
Code: ags
git push origin master


For assets: one thing that I'm doing right now is that I keep all assets in a subdirectory of my game's working directory, meaning the assets go with the source code. This may or may not be preferable, and probably balloons up your repository's size - but, keeping your assets in git means that you can also keep track of the revisions as time goes on. One alternative I'm interested in trying is moving all of those assets into one big git repo of their own, keeping it all separate from source code. Then, when I'm working on a game, I can reference the shared asset directory for all of my games, in case I want to re-use some assets somewhere else.
The fediverse needs great indie game developers! Find me there!

SMF spam blocked by CleanTalk