When to scrap a project?

Started by
6 comments, last by MrMark 16 years ago
Ok so I've been working on this game for the past few weeks, and being a beginner I've run into several problems. 1. Object interfaces are difficult to work with, and doing things like adding a new type of monster takes a lot of extra work and workarounds. 2. Managing game resources has become a nightmare, so far I've been manually loading the textures in the program, so I've got somewhere around 30 and it's cumbersome to add new resources/change resources. My biggest problem here is I think I'm misunderstanding sprite sheets. So far what I've been doing to make the sheets is measuring the widest sprite, and measuring the tallest sprite. Once I have those measurements I use that are the new dimension for every cell, so even if one image was shorter/narrower it would still be in a cell much wider and taller than it. 3. It's also come to the point where there's so much "hack" code that was put in temporarily to get things working. At the time I thought to myself "oh I'll have no problem fixing that later", but now that there's code like that everywhere (and some of the hack code relies on other hack code) it's very difficult to try and fix any of it. So the biggest problem now is that because of all these things it's come to the point where when I work on it I'm not learning things so much as I am fighting the code I've already got. I'd say the game's 60% done, but at this point I'm not sure if I should bother finishing it up, or cut my losses and take the lessons I've learned to try something different knowing that this situation can arise if I don't plan out the interfaces well. Any thoughts onto any of these points?
Advertisement
It's probably psychologically better to finish up what you have, then at least you can say you've completed it. Afterwards, do a postmortem and learn the lessons you need to for your next project.
might be worth rewiting it, BUT not from the ground up. work out how you can object orientate it a bit more, put together a basic framework of classes, then apply all your functionality to that. wont be as tedious as rewiting what you have, and the extra time you spend on it will speed things up as a direct result
http://stowelly.co.uk/
There are generally 3 views on this.

1. When you want to. If it's your hobby and recreation, have fun; that's what matters.

2. Never. Get something done. You'll have accomplished something, and in the end, most problems are just annoyances in the grand scheme of things. Plus you'll get 'past' your problem bits and work on release/packaging stuff which is important.

3. At the point that it's quicker to re-write/factor something than deal with it going forward. Spend time now to save time later is the idea, but can lead to problems for beginners where they just spin their wheels since every implementation is worse than what you could've done once you learned how to do it.


In the end though, programmers need to balance the need to get things done and the desire to get things done well. For beginners, it's important to realize that your code/architecture/design sucks, and will continue to suck for some time. Learn from the suck, and if you have something that's really problematic or easy to solve, make it better. Mostly though, ignore it for now. Focusing on one little bit of code hinders your learning.
Thanks for the replies. I think I'm going to take a break from it for now since it's no longer enjoyable to work on it, though it bugs me to have it unfinished. I think I'll stay away from attempting another game for a while and instead learn some more and make different applications for learning purposes. I think it would be beneficial for me to go around looking at other peoples code for games and see how they dealt with it, because I don't want to get my mind stuck in dealing with the game problems my way, since other implementations could be better.

What I really need to find is an open source 2D sidescroller, so that I can see things like how they dealt with resources, how their sprite sheets are constructed, how they made their levels, etc. I'll go on a google hunt for that later.
Taking a break is a good idea. Also, consider that refactoring is usually better than rewriting.
It sounds like you've got a perfect opportunity to learn how to refactor code.

Richard "Superpig" Fine - saving pigs from untimely fates - Microsoft DirectX MVP 2006/2007/2008/2009
"Shaders are not meant to do everything. Of course you can try to use it for everything, but it's like playing football using cabbage." - MickeyMouse

If the project has lost all fun for you, quit before you get so burned out you never want to touch code again. It happened to me once and I didn't program for a couple of months. For my hobby projects I have usually have a couple going at once and I switch between when one starts getting frustratingly hard. The trick is to make sure you come back again once you've got some more experience working on other project's and can now see a better way of doing things.

It sound's like you are trying to create a game engine for scratch, using low level (DirectX/OpenGL) API's. If I was you I'd put in on the back burner for now, start a game using an existing open source game engine. Do some hunting for something regarded as well designed ( you'll learn a lot just by seeing how they do things ), and easy to use. The Competition's forum has a list of open source libraries and engines you should take a look at.


Once you feel your enthusiasm coming back refactor the code. Hopefully by then you would of learned more about OO design and can see how to make your code more reusable.


Bottom line, keep it fun. You aren't working for anyone, learning more and enjoying yourself at the most important things.

This topic is closed to new replies.

Advertisement