Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Author
Message
Zeus
20
Years of Service
User Offline
Joined: 8th Jul 2006
Location: Atop Mount Olympus
Posted: 24th Nov 2011 21:54
So I am in the process of a new project and I was wondering if it would be a smart idea to make a prototype of the game and then use the source of the prototype (tutorial level will be the prototype) to expand it into it's own engine that'll work for multiple levels?

Thanks,
Zeus

American Warfare is still in development - it is currently postponed until I build up the skill to complete it.
IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 24th Nov 2011 22:58
I'm wondering how else you would code it.

Seriously though, I always work that way - start with a smallish base, write more code and integrate/debug, fix all bugs as they are encountered, repeat as necessary.

The 'write more code' bit can either be direct coding into the main program (for small changes or when refactoring), or write a module that can be tested separately then integrated into the main program later.

The impression I get from what I see around the forums is that most people do something similar (though most would code their changes directly into the main code rather than build a separate module). Of course, I could be mistaken in that impression.

revenant chaos
DBPro Master
19
Years of Service
User Offline
Joined: 21st Mar 2007
Location: Robbinsdale, MN
Posted: 25th Nov 2011 04:25 Edited at: 25th Nov 2011 04:26
I always code new pieces separately, It makes things much easier to debug as well as reducing compile times. Another advantage is that the code can easily be used across multiple projects with little to no modification, and I find the optimization process goes much smoother without all the other pieces to worry about.

Quote: "that'll work for multiple levels?"
It can (and usually does), but you should at least have an idea for your final engine functionality and layout to ensure you don't code yourself into a corner. If you write functions to destroy what each piece creates, then it would be just a matter of re-initializing the things which change from level to level.

The only problem that I've come across is when more than a single 'module' uses the same function. You can wind up with a few different functions which do the same thing, which can lead to some frustration down the road. To solve that, I usually create a "common" source file which includes those cross-module functions, along with comments that specify which modules use each function. It really helps incase you decide to wrip/re-write pieces from your engine later.
EdzUp
23
Years of Service
User Offline
Joined: 8th Sep 2002
Location: UK
Posted: 25th Nov 2011 11:58
One thing to do on these occasions is to make things modular and then use includes to add them to the main file, the reason for this is simple through the life cycle of the program you will learn more 'efficient' ways of doing things and with this you can recode modules.

Back on topic though, I always go prototyping and refining then once its all working I refine some more then dive into creating levels, graphics and sounds for the game. Once you get the base code down then you can move onto adding sections to the game that you want in there.

ONE THING TO TAKE CAREFUL CONSIDERATION ON: Always have a design plan of what you want the whole game to look and play like, break each section down into individual sections and functions. Then code each piece of the code (keeping notes if the code takes more than a day to code etc). Do not deviate from the plan otherwise you will enter the real of 'feature creep' where you never get it finished because you will just add feature x to make it better and once its in there is always something else that you want to add. Those features can be in version 1.1 etc dont put em in the main release but keep a note for adding later, people love new features etc on a product they already bought.

-EdzUp
Graveyard Dogs
Zeus
20
Years of Service
User Offline
Joined: 8th Jul 2006
Location: Atop Mount Olympus
Posted: 25th Nov 2011 17:14
Thanks everyone! I am glad to know that I was going about it the right way.

American Warfare is still in development - it is currently postponed until I build up the skill to complete it.

Login to post a reply

Server time is: 2026-07-10 16:33:51
Your offset time is: 2026-07-10 16:33:51