Saturday, June 29, 2013

Sneaking: well, it's technically a game now...

There are a lot of important points in the life of a game. One point is when you stop working on it. One point is when you ship it. These may not be the same, especially if you're working on an online game.

One important point is when the team actually has fun playing the game, and stays at work playing the game instead of going home. Not all games get to that point. Most don't, I'd wager.

One point that I know I always was searching for on previous projects is the point when the game is "fun". It's hard to know what that means, and pieces of the game might be fun early on, but making the whole game fun is tricky.

Well before any of these points is a point where the player was some in-game recognized notion of success and failure. In some games, these may be vague - for arcade games, failure is the "GAME OVER" screen that tells you to put another quarter in. For console games, you may not have as clear a failure mode - just get knocked down and start over. Maybe you go back to the beginning of the level. Console games often have a clear ending point - defeat the final boss, the credits roll, and you walk out to the kitchen because who reads the credits?

Even though I know that my little sneaking game isn't going to have a lot going for it by the end of the month (still got 27 hours), but it's got success and failure finally.

What you see here is a maze (green boxes) and a guard (green dot) as well as the player character (pinkish dot) and an exit square (pink box). Get your guy down to the lower right hand corner of the screen, and you win. But the guard might see you, as he does in this picture (blue line). When the guard sees you, he runs faster than you do, so you don't want to let him see you too often.

There are several things I want to get in to the game before I call it quits:
  • Proper "game over" logic, and probably a title screen. I know how to do this stuff, it's easy, it's just getting around to doing it, which may mean refactoring the code I've written. (It's a mess.)
  • Multiple levels. I was thinking of doing 10 levels. I might get 3 written. They're not hard to make, really, so 3 should totally be doable. Maybe even 10, if I get everything else squared away. Heh, squared. Like boxes. Ehhh, maybe I've spent too much time at the computer already.
  • Multiple guards. Again, a little bit of refactoring will be necessary - right now the guard is a mess of global variables. (Bad!) Having multiple guards to contend with will make the game harder.
  • Limited visibility arcs for the guards. Right now, the guard has 360 degrees of visibility, so you can't really sneak up behind him. If I narrow this down to, say, 120 degrees, it'll make the game easier, so this should go in along with having multiple guards.
  • Turning speed for the guards. The guard currently has no notion of "forward", he just gets pulled toward his destination. That destination can jump across the level, and does - for instance, when the guard sees you; he immediately heads in your direction. I'll need to give the guard a heading in order to have visibility arcs, and shortly after that, I'll add in a turning rate.
  • Lookie-loos. Right now, the guard's patrol route is a little boring - he just plods along in a straight line toward his next waypoint. I have this idea of inserting points where the guard stops and turns around and looks behind himself, which would be a good thing for a guard to do, but would make following a guard a really dangerous thing to do. I can insert this as explicit turns in the patrol path, or I could give the guard a random fuse that he'll occasionally stop and check his six. Maybe I ought to call that the "Crazy Ivan".
  • Cleanup? Those grey dots you see in the screenshot - those are waypoints for the guard. Handy for me as a developer, maybe useful for the player... maybe too useful. Maybe confusing. I think I ought to take them out. You know, when I'm done with everything else.
  • Smarter / Lazier guards. That sounds weird. Right now, if a guard loses the player, he'll head to the last place that he saw the player, which means he's got a limited ability to chase around corners. One corner, really. As soon as he loses the player, he goes back to patrolling, starting with the "next" waypoint that he can see. This may be way back across the level - which seems weird in some circumstances, like if the guard breaks off chase with the player, then returns to a waypoint to the south, but the next waypoint is north of the break-off point; the guard executes a weird 180 degree turn, retracing his steps. Probably makes sense to check what the "last" waypoint in view is, and then maybe consider the closest waypoint, or something that looks smarter.
There are a few things I won't be getting to, I'm sure:
  • Pretty graphics. Sorry, not happening in time. Maybe the player and the guards will become stick figures. Don't get excited.
  • Sound, Music, Score. Feel free to hum and make your own sounds. And award yourself points.
  • Dynamic Levels. Yeesh. Procedurally generated levels would be nice. 
  • Dynamic Patrol Routes. This would kind of need to happen with dynamic levels.
  • Pickups / Powerups / Rich Environment. One thing that I thought of doing early on was to give the player two things to do on the level before getting to the exit. Like picking up a rope and opening a window. There will be no ropes and no windows. I also thought that maybe you could pick up gold, or somehow get points for traversing the whole of the level. I don't see that happening, either. A long time ago, I had an idea for a similar game, and in that game, there would be things like squeaky floorboards, which would bring the guards running. Not in this game, though. Maybe later. If I were to return, maybe I'd create some powerups to help the player out. Super sneaky limited use shoes. Or smoke bombs. I'm not sure.
  • Level Countdown Timer. Actually, maybe I can get that in. That'd really ramp up the difficulty. But it also kind of pushes against the sneaky feeling of the game. Maybe I award bonus points for the timer, and let it go to zero without killing the player, just don't award any points past a certain time. That could be OK.
  • Guards coordinating their patrol routes. Imagine a randomly generated map, with randomly generated patrol waypoints. It'd be good if the guards covered these in a somewhat intelligent (appearing) fashion. Several years ago, I fiddled with a similar system where the guards would seek out waypoints that hadn't been visited recently. There was nothing keeping the guards from clumping up and patrolling in a gang, which wasn't what I had in mind.

No comments:

Post a Comment