Making java games

Status
Not open for further replies.
So far the game makings been going well, I have a good structure.

The game gui talks to the game engine, the game engine talks to the text interpreter and the current room.

I'll make it better once I can actually get the text interpreter working better. So far the only word it recognizes is "look", thats easy to change though, I'll just make an array of recognizable words to check.

However I am noticing how much work actually goes on behind the scenes of even a text based game. I mean just to get one command going through I have to break up the command into an arraylist of substrings (making sure i take out spaces and convert to lower case). Then I have to individually check every string to see if it matches a word.

It'll be cool once I get this better and better, so far the guis just a piece of crap with an input and output field, and a button to send text.

I need to think of somebetter way then individually making every room object, but I cant think of any way around it since some rooms will have different code then others.

I mean some rooms have some of the same commands so I made an abstract class which all other rooms will extend, to cut down code and make it more eligant. But regardless each room will have its own string of words on top of the universal string of words.
 
Status
Not open for further replies.
Back
Top Bottom