Thread: game creation questions

  1. #1
    Registered User
    Join Date
    Aug 2005
    Posts
    6

    game creation questions

    I'm makeing a game similiar to a mud and have a few questions, should I create a function that continually checks for input, and should each of my commands be a seperate function as apposed to a single function that does a strcmp to every command inputted.

  2. #2
    Supermassive black hole cboard_member's Avatar
    Join Date
    Jul 2005
    Posts
    1,709
    Game Programming forum
    FH, move away
    Good class architecture is not like a Swiss Army Knife; it should be more like a well balanced throwing knife.

    - Mike McShaffry

  3. #3
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,660
    Moved to game forum
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  4. #4
    vae victus! skorman00's Avatar
    Join Date
    Nov 2003
    Posts
    594
    If you don't continually check input, how else will you know what the player wants to do? For the second question, the first option would call for a menu of sort with the player pressing 1, 2, 3..etc depending on what action they want, while the second would have some sort of text command line like old school sierra games (if I understand what you're asking).

    The question is what will your game require. If all I can do is look, attack, and move, I would be ........ed if I had to type out those words all the dang time. But if I had to "look at box" or "use torch with magic flame to burn face of evil jaberwaki," a menu would have to be pretty extensive.

  5. #5
    Game Developer
    Join Date
    Jul 2005
    Posts
    2
    Quote Originally Posted by skorman00
    If you don't continually check input, how else will you know what the player wants to do? For the second question, the first option would call for a menu of sort with the player pressing 1, 2, 3..etc depending on what action they want, while the second would have some sort of text command line like old school sierra games (if I understand what you're asking).

    The question is what will your game require. If all I can do is look, attack, and move, I would be ........ed if I had to type out those words all the dang time. But if I had to "look at box" or "use torch with magic flame to burn face of evil jaberwaki," a menu would have to be pretty extensive.
    How else are you going to use a lit torch with magical properties to hideously deform a non-righteous jaberwaki?


    Mr. Skorman is right. But if you are doing a graphical adventure game, then you arn't really pushing the forefront of technology. Most of your background are static/pre-rendered so you don't really have to worry about a framerate. It all depends on what your game needs.

    For example, in a complex text game like Mr.Skorman suggested a database would be perfect. You'd basically just create queries like:

    SELECT result FROM Map2Area4 WHERE playerAction='Take Key from Pocket';

    You could then use the result as a look up into a database of result text output ("You took the KEY!"), and use it to see what items the player gained(if any).

    Just my suggestion.
    Last edited by ChaosPhoenix; 08-10-2005 at 06:31 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. A few questions on game programming
    By mramazing in forum Game Programming
    Replies: 7
    Last Post: 01-11-2009, 05:48 AM
  2. 20q game problems
    By Nexus-ZERO in forum C Programming
    Replies: 24
    Last Post: 12-17-2008, 05:48 PM
  3. C# - Building a SCUMM-like game.. questions
    By Iyouboushi in forum Game Programming
    Replies: 0
    Last Post: 05-24-2008, 10:54 PM
  4. 2D Game project requires extra C++ programmers, new or experienced
    By drallstars in forum Projects and Job Recruitment
    Replies: 2
    Last Post: 05-16-2007, 10:46 AM
  5. Someone help me with this game??
    By stehigs321 in forum Game Programming
    Replies: 15
    Last Post: 10-30-2003, 09:42 PM