I want to create a point-and-click adventure in the style of Zak McKracken. Not in an artistic way but with the same game mechanics. Well, maybe a little in the same artistic way.
At this point I don’t have any idea about a story or a character or a situation. I don’t have a sketch or something like that. There is only the wish to create this kind of game.
This is my first computer game ever and that means I couldn’t add any feature I could think of. Instead I add only those features which development I could handle. That doesn’t mean it will be a boring game though it has only a few features. It will just tell a good story and I think that this is much more important than big explosions, guys with guns that kill everything with a heartbeat or the next MMORPG … MOMRPG … MROMGP … I don’t know … one of those letter combinations.
THE GAME MECHANICS
A point-and-click adventure is nothing more than a collection of scenes. The intro is a scene, a cutscene is a scene, a playable scene is a scene, the outro is a scene. Whenever something happens on the screen, it happens in a scene.
Hey, that rhymes.
Because of Defolds system of collections and game objects, a scene will be a collection and vice versa. Every hotspot in a scene will be a game object with a unique id and a collision component. By using a collection for a scene, I can test every scene I want just by setting it as the bootstrap collection in the project settings. I don’t have to play all scenes just to get to the one I want.
Within the scene there are hotspots. An item or a NPC the (human) player can interact with is a hotspot. When the pointer hovers over a hotspot, the (human) player can see a description of it. This way the (human) player knows there is “something”. Once the (human) player clicks on the hotspot, one or more actions will be executed, e.g. move the player to a given position, say something, pick up an item. The actions will be executed one after another. First the player walks to the given position, THEN he says something, THEN he picks up the object.
For the actions I would like to use an action list. This is just a stack. The last action to be executed will be at the bottom and the first action will be at the top. Or in another words: last in, first out. Something like this:
walk to given position (top of stack)
pick up object (bottom of stack)
A controller script handles only the first (top) action. There will be a variable called action_done, which is False. As long as the current action doesn’t set action_done to True (e.g. the player hasn’t arrived at the given position), the action will be executed in the next frame of the game loop. As soon as the current action is done (e.g. the player has arrived), action_done will be set to True. The controller script now removes the top action from the stack and sets action_done back to False. At the next frame of the game loop the new top action will be “say something”. And everything starts all over again.
Because I don’t know how to do pathfinding, the player can only walk sideways. To add a little more variety, the line of walk will be on a different height when it is necessary. A high line of walk indicates … well … a high location. It’s a long way down. A low line of walk on the other hand is good for a landscape scene and emphasizes the vastness of the nature. Take a look at the following examples:
I have watched many longplays of point-and-click adventures. The player always walked sideways in about 80% of all scenes the games consist of. If lateral walking is good enough for crabs, then it’s good enough for my game.
There will be no dialog system where a player can choose the next answer. Like pathfinding I don’t know how to handle this at this stage. Instead every dialog between the player and a NPC will be just a little cutscene where the (human) player sits reverently in front of his monitor and witnesses the greatest conversation since the Almighty spoke to Moses.
There should be an inventory system. I am fascinated by the idea that the player can carry around a maximum number of items at a time, let’s say … sixteen. That doesn’t mean there will be only sixteen items in the whole game. There will be a lot more but it’s a kind of strategic placement of items within the game so that the player will not carry around more than sixteen items at a time.
One important feature are game flags. Whenever the (human) player finishes a necessary action, the corresponding game flag will be set to True. With the flags I can create dependencies. The (human) player can only do action X if he has done action Y before. Both actions don’t have to be happen in the same scene. Action X can happen in scene 14 and action Y can happen in scene 27. All the engine has to do in scene 27 is this: check if action X has been done, if not then let the player say “I can’t do that”, but if action X has been done, allow the player to pick up the item or something else.
Game flags could also be very helpful on saving the game. All I have to do is just save the list of game flags. If the (human) player resumes the game, the engine sets the current scene to the last visited scene and by processing the game flags, the scene will be prepared accordingly.
For now I would like to end this post and work on a structure for the collections, the game objects, the components. I hope that this long text isn’t as boring as watching rain drops falling into the ocean. Although I like rain. And the ocean. I was born at the ocean. Nevermind, that’s another story.
P.S.: English is not my native language. If I used a wrong word or a wrong phrase, please let me know. I know this is a forum about a game engine and not an english class but … hey … that doesn’t mean we have to be sloppy about the way we talk and write.