How to cope with losing source code?
Miscellaneous Forums/General Discussion/How to cope with losing source code?
Long story short:
I wrote a game yeas ago, it got a publishing deal, I felt brilliant and saw myself going places.
The publisher wanted features in the game I didn't want to add in.
The game never ended up getting published which made me feel crap and not wanting to write anything.
I then lost the source through a combination of moving house several times and changing PC's. So I now have no source code which close to the quality of the game I wrote.
I'm now stuck with rubbish bits of code I've been playing with on and off and can't cope with the idea of spending a long time writing a large game again (by large I mean over 7000 lines of code), because I keep thinking I won't get anywhere. This has been happening for years. And I just can't seem to get over it.
Has anyone else here lost loads of code they thought they could never replace, did it damage a publishing deal, did you then find yourself unable to put your heart into anything new? How did you recover from it?
p.s. My game was called Grenade and it was loosly based around Cannon Fodder if any of you old timers remember seeing it.
Are we talking about a certain Cannon Fodder type game?
[edit] Ah, you edited your post. :)
I gave myself a reality check about a year and a half ago and figured I either keep making games to ridiculous timescales and effectively giving away the rights, or I do it for myself and put more effort in.
So, that's what I'm doing now. Don't think of it as 'writing a large game'. If you think like that you'll never do anything because it all looks like too much to take on. Break it down into component form and tackle it one step at a time. Rome wasn't built in a day. :)
Gfk: Yes, you remember it? Not sure I'll be approaching that publisher next time, not sure they like me... anyways, yes it was my baby and I was very sad to lose it all.
Wasn't it Anthony Flack who had his house burn down with platypus inside it? How did he recover from that? Speaking of which, where the hell is Cletus Clay?
Ive gone through loads of iterations of Elite Multiplayer, the first one had a problem where I lost the entire source due to the CDR wearing out. Now im on max I have source backed up to USB keys.
Is this a silly idea for bmax?
Incbin the code, and add some means to extract it again during the run. This way every exe, anywhere, contains your source.. :P
In that case just give out the code to everyone.
I feel for you, Andy, and there's no easy answer.
I reckon the worst thing you could do is to try recreating your original game. Much better to start something fresh. I'm sure you don't need telling this now, but keep regular backups!! Stick at it. At least you know from experience that you're capable of seeing a project through to completion.
Good to see you back, Gfk.
I've never lost any important source code so I can't really give an answer but I agree with Gfk "Rome wasn't built in a day" philosophy. If you just look at one little job at a time and forget about the rest and just keep going steadily you'll get there one day. Just take your time.
Look at the positives, if you're going to rewrite your game you get a chance to do things better, you can plan it so the game could be built on a framework where you can then get several similar games out of it. If it's a new and improved version you should have more enthusiasm for it.
I had a disaster that totally rocked me, a few years ago, before CD writers were affordable to the likes of me, i had everything id ever done, including my spectrum games i wrote when i was 12 (stored as .sna files) and my amiga & early PC stuff.
I had everything, artwork (90% in LBM/IFFs, source, imagine/pov stuff) stored on my PCs hard disk and a copy of it all on a removable HDD caddy that i kept in a drawer to isolate it. I also had a copy on my dads computer put there via our home (10mb BNC -lol:) network. So i thought i was pretty safe.
Nope
A virus (cant remember what) totally distroyed my file system and my dads and when i went to recover the one in the draw, it would not get recognised by the bios and made some mechanical noises. I was totally devastated. I gave it all up and took up guitar playing, travelling and hippydom for about 6 years without using a pc for anything other than games and internet.
Learned my lesson there didnt I (call me paranoid if you want but im not loosing it all again!)
So this is what i do now:
Now i have a central Linux file/prn server desktop that has a 3 tier 80GB mirroring system (3x80Gb HDDs grandfather > father > son) that syncs the entire disk (excluding temp stuff) once a week and then a monthly burn down to DVDs that are stored well away from the PC incase of a fire (apartment walls are concrete with 4 rooms in between)
This server serves my windows/linux laptops with a shares for everything (eg, p:\ = programming stuff) The laptops (on the linux partition, not windows) i keep an aditional sync of all the important bits (rather than the whole file system) which i sync each time i need to travel somewhere and sync when i get home again. I also take a few dvds to my dads house back home in UK each time i visit, as an offsite solution (2x a year)
Thanks for the reply's, it's not the really the technical side of backing up data I'm having problems with. It's the mental problem of actually getting back to serious coding. I play some games and think I could write a similar game, so I get something simple working, then just forget about it. It's like I've got a phobia of coding now. Maybe it's guilt from not finishing my first game?
Take it as a learning experience, and start backing up. :)
Use subversion, it is a great tool if used even remotely appropriately.
As for losing code, I have done it a couple times, and I can tell you the code will actually be better the second time around, if you start over. It gives you a chance to see the things you did not do as well as you could have, you can write your types (classes) in a different manner making them better, use new techniques you learned after you were halfway through when it was too late to fully implement them, etc.
Code always seems to be better the second time around. I say start over, make it better this time!
Andy: Just think, this time you can make your game a whole lot better. Okay, so you don't have the original source code anymore to look back on, but you at least remember some parts of how things were done, and the big picture of your project organization.
As for going all the way through a project, I don't think its code phobia. I'm having lots of trouble finishing any projects right now, too. I mostly blame it on not having any good tools to make graphics with (I don't want to spend money on high-end tools or spend time trying to learn to use them).
I think we all have stories about loosing valuable project sourcecode. In college I used a zip disk to store all my projects on. Zip disks become unreliable after a while, when you keep writing data to the same locations (and unfortunately Windows isn't wise enough to quit using them). I would buy a new disk every once in a while but they'd start failing too. So well I had this multiplayer space combat game going, and when trying to save it to run it again, the zip disk started failing. When I finally got my sourcecode back, half of a file was missing / corrupted. I kept backups but nothing recent enough to recover what I lost.
As far as backups I keep, I do keep a few copies of all my projects online, on various free web hosts. All you gotta do is have a website existing. My files are encrypted using my own routine so I feel that they're pretty safe. I also have 1 USB drive and recently I've been backing up things to CD annually. I no longer use zip disks because I don't have a drive for them (and they even did away with them at my college).
This probably wouldn't help any right now if my laptop suddenly failed, but I do have all my old source somewhere. Backing up data takes a lot of time because I keep files to track where all the projects are located - and modules too (I use a lot of modules).
Am I the only person who prints a hard copy of there code? i dont really see this as backup but I use it to see more clearly how i might clean up my stucture and keep my code readable. coming back to badly commented code is almost as bad as losing it. which i have done in the past. I lost code because there was such a long time period from when i first got blitz3d to when i really started using it again about 2 years ago. i think id changed my Pc twice and i used to backup to random cds that all look the same and id just dump files anything from mp3s to programs and pictures etc, id label them backup 65 and other unhelpful names. i now label and sort my backups.
as for the topic above i agree with what people have said above. Just think about a nice simple idea that you think would be really fun and start coding it in small chucks. youve done a game so you can do another.
Am I the only person who prints a hard copy of there code?
Yes, yes you are....
Actually, have you tried scanning your print offs and OCRing them to see if the code can be automatically re entered without having to manually type it.
I remember typing in games from Amstrad Action magazines and that used to drive me crazy, those damn Data statements!!!! Data 56,E6,D4,567,8E6,3F,A2,C2,etc, etc, argh!!!!
hmmm, might get the Amiga out soon to find my old AMOS games.... Maybe update them to Blitz3D (or just recreate a commercial Amiga game on Blitz3D and rename it.)
small note: can't actually receate the first game again, as I had it signed to be published, so I'm pretty sure I'd get hunted down if they found out. Although I do have an idea.
I've lost several projects back in the days when I had no way to back stuff up. Usually I give it 6 months, work on a side project then attack it all again from scratch. Usually ends up twice as good as the first attempt. :-)
Start again with some simple, easy to manage projects to get yorself back into the feel of wanting to do it.
I wish i had back those 6 years of freaking out i described above, i would be far more up to date if i had. Try not to despair like i did, you will regret it.
Just make sure you keep more than one backup :P
I used to print out my code to debug it.
I've lost the source to all my Amiga stuff from back in the day. Perhaps I'm weird though, but I can remember most of the projects I'd got near completion, or was in the middle of and still interested in... and I can guarantee that if I sit in front of AMOS Pro, DevPac, MonAm and SAS/C that I can recreate most of it from memory.
I'd got a breakout clone in AMOS Pro, a BBS that I'd started in C and was translating to ASM (everything to be kept in RAM instead of loading from disc like every other BBS, so it would be fast), a dual-chat BBS door written in Amiga E (for DayDream BBS), a cracktro style thing done in ASM with a few basic effects and music, a fairly feature-complete paint program done in AMOS which was then entirely useless when AGA came along, a patch for the speedup patch for Alien Breed 3D 2 that let you patch the cracked version (the original patch didn't because it failed the checksum)... this was my first real use of MonAm to step through someone else's code.
God. I loved my Amiga. Sob.
Is this a silly idea for bmax?
Incbin the code, and add some means to extract it again during the run. This way every exe, anywhere, contains your source.. :P
Sounds like an interesting idea... Of course, you'll also need to be able to retrieve your media, and probably want to have the source code encrypted/password protected in a way you'll be able to reconstruct yourself without anything too proprietary...
I don`t have the exact same bug - but one with similar traits.
I find that I see/hear/imagine an idea for a game, and my mind starts ticking over how would that work, how would I, how would it etc etc
So I then spend a few hours/weeks whatever working out how to overcome whatever the obstacle is, or how to make that effect work or that mechanic work.
Once I have proven to myself I have done it, I kind of lose interest and the next thing I am wondering about (how would it) seems more enticing than the one I have just racked my brains out getting to work.
That is why I have literally hundreds of unfinished bits of games/apps etc all over my hard drives.
Thinking about it there is probably about 5 things I would be interested in going back to complete.
I find that I see/hear/imagine an idea for a game, and my mind starts ticking over how would that work, how would I, how would it etc etc
So I'm not the only one who does this? I see the game in my head, I can visualise all the menu's, gameplay, control system, everything, I try programming one small bit of it, such as a laser sight, or an overhead minimap, then I forget all about it and go back to playing on the xbox. My new years resolution though is to actually see a game through, I've already got the first 5 pages of a design document together, I'm checking out which tools to use now (probably going for anim8or although deleD looks good, is the pro version worth getting?). I'm planning to use sprite candy (hopefully htat will eb easy enough).
The problem seems to be to keep the enthusiasm going enough to get the project moving.
I tried out Deled briefly but didn't like it at all.
For 3d I have got on well with anim8or for player models, ultimate unwrap for uv mapping, wings3d for buildings/objects and Milkshape3d for animating.
Am I the only person who prints a hard copy of there code?
Nope, done this too on occasion -- can't hurt to have it just in case everything else goes tits up, I figured.
With respect to the original post, I remember reading an article about Unreal and how its core engine was written and re-written several times until it became that gob-smacking thing of beauty that dutifully smacked our gobs. If Tim Sweeney can benefit from re-writing stuff then you probably can too -- why aren't you chomping at the bit to apply all the knowledge and skill you've gained to rebuilding this thing so much better? This is ALL opportunity! A fantastically liberating clean slate! Hurrah! (Get on with it.)
small note: can't actually receate the first game again, as I had it signed to be published, so I'm pretty sure I'd get hunted down if they found out. Although I do have an idea.
Well if Grenade was similar to Cannon Fodder in the first place, and you were comfortable with that, then why can't you do something similarly similar to Grenade?
Usually ends up twice as good as the first attempt.
This is the silver lining I always tell people when they lose 3d models, and it's true of code too. As annoying as it sometimes is to recreate something you've already done before, the second time is always a massive improvement. It's not just about generally having learned more, it's that you've already sorted out what problems will come up and how to address them for this specific project.
Well if Grenade was similar to Cannon Fodder in the first place, and you were comfortable with that, then why can't you do something similarly similar to Grenade?
That's the plan now, I had to downscale grenade so much from the original design but now I can aim much higher as I've no deadlines or anything, so now I can make the game ten times more exciting and devote a lot more time to it.
Andy,
You've got the same choice as anyoe else when something knocks them on their arse:
You can either quit or learn from it and move on.
I bet if you started the original game again you'd find it didn't take as long as you think and you would do it better and quicker this time because you have a better visualisation of what you want to achive. This time you'll do it better or give it up and spend your time on something you feel is more worthwhile.
If you just sit there doing nothing your not helping yourself in any way, there are lots of things better to spend you time on than making games, or if for you that isn't true and this is the thing you need to do, then get it done!
Our time is short.
Darkheart
Thank you Darkheart wise words indeed. I just bought the pro version of DeleD and am playing around with it, I'll be using it to build all the objects and levels in my games, not sure what to use for characters though, I don't think DeleD handles animation, so I'll be needed a cheap or Free alternative for character work.
As darkheart says, our time is short, so throw the computer in the bin and get laid.
"Am I the only person who prints a hard copy of there code?"
No your not. I also keep a hard copy of code ( as well as 3 different backup methods.. USB PEN/NAS Drive and CD/DVD-R media). I use it to see if can make improvements when I'm not near a computer.
"As darkheart says, our time is short, so throw the computer in the bin and get laid."
Been trying that for years now with still no sucsses ( thowing the computer in the bin that is)