Tuesday, September 29, 2009

See Dungeon Runner Run

Man, I really should have saved that little ditty from my past post for titles, there's a lot to talk about for dungeon runner.

Not only does dungeon runner generate dungeons, Dungeon Runner also randomly generates all the items in the game. And I mean all the items. There are, of course, upsides and downsides to this.

WHen you're randomly generating items, you don't have to worry about keeping things level appropriate. Every item has a stat that is simply multiplied by the level of the item, and the player can only equip items that are their level or lower. Great. In dungeon runner, items typically grant a +1 bonus per level, or twice that for your weapon. This is divided evenly amongst up to three attributes (of your four). It then also gets a secondary bonus for each rarity level it is (common, uncommon, rare, or mythic) that is applied randomly across a score of lesser attributes (like attack speed, elemental resistance, damage reflection, spell damage increases...). The item is then given a random name based on it`s stats (or possibly, the name is generated first and the stats are given afterwards.)

There`s one enormous problem not immdiately evident from this description - what do you call it? Dungeon Runner sticks with it's whimsical roots and gives things names like "overweight greatsword of the angry termite". Great, but what does that mean? You can take a quick glance at items to see their names, but that's now useless. How are players to know without research and memorization that termite is a bonus to intellect and dexterity? At least if it were called, say, clever greatsword it would be more useful. It's even worse when you get into more rare items, because they get more suffixes and prefixes added onto the end. "(warning may cause rash)" or "(size 17)" are funny, but utterly useless and ultimately degridating to gameplay.

Okay, so you finally decide that you want to buy a termite sword now. You walk to the shop, and open up the weapons tab.

Oh look, more random weapons. The weapons shop is not just weapons for you though, each of teh three equipment stores in the game holds random items for thirty levels of characters, meaning if you're level fifteen and walk into the shop, half the items won't even be usable to you, even before you exclude the fact that items only paid users can use about half the items, too. You wind up with a selection of items, probably two or three of which are near your level enough to be useful. Now, you have to cross your fingers that: -One of the items is what you're looking for and that -the shop doesn't refresh before you buy that item, because it refreshes every seven minutes regardless if you're looking at it or not. Sure, that gets rid of some of that poor selection problem, but it can just as easily exacerbate it by taking that item away at the last moment!

And to add onto all that, there are random item shops, where you get to either pay a small amount and get a random item near your level, or pay a large amount and get a random (typically useful) item for exactly your level, primary stat and slot. You still don't get to choose the look though, which can be frustrating for people trying to keep with a theme. Oh, and you can't choose if you're looking for a ranged or melee weapon either. You could just as easily get a bow as a longsword.

Did I mention that on top of all that there's about a dozen different armor sets? Most players take what they get and are satisfied with their character changing in appearance entirely each time they log in and play. Some people, I'm sure, will give preference to one type of armor over another, despite the fact that in the end, everyone should be in heavy armor because it has no penalties and a much higher defence. Sure it looks stupid to be carrying a staff while wearing it, but that's a small price to pay for improved DPS right?

Sunday, September 27, 2009

This is Dungeon Runner

See dungeon runner run.
run dungeon runner, run.

Dungeon runner is an MMO that I've been playing lately. I purchased it about a week before it released the news that it was going out of business. That's unfortunate, but I think I'll survive. I mean, I paid five dollars for the game *and* six month's subscription. I wish I could see how they went out of business with a business plan like that. Oh, and did I mention their server only holds 500 people, total? That's like, five thousand dollars of profit a year, man! Except that more than half their players subscribe to the free version of the game. That means their items are about 10% worse than paid customers. Boy, what value for that money, huh?

Obvious business plan flaws aside, Dungeon Runners is a pretty fun game. It's light-hearted, erring on the side of ridiculous, and looks nice, plays inteutively and so on. Did I mention that the dungeons are (kinda) randomly generated, too? All the better.

Dungeons in dungeon runner follow a few simple rules. There are eight floors, divided into three sections. Upper, lower and boss. There are also six sub-areas off of varying floors, two off the upper and four off the lower. Each group (upper, upper-sub, lower and lower-sub) has a different theme. Undead, blizzard, fire, standard dungeon and so on. Each theme has several variations, and overall it's not too sore on the eyes. They're then mapped out by taking a number of puzzle-piece like pre-generated areas and randomly sticking them beside one another until it's about half an hour to cross from one end to the other. It works out well for them.

There are four different classifications of monsters I've come across so far. Whiskers (rat-men), Oroks (orcs and ogres), Fade (undead) and mutants. Each of those groups comes in about six units (discounting bosses) and each unit comes in one of the six major elements. Typically a particular floor in a dungeon will contain either one type of enemy, or one element of enemy. There's a few problems with this, namely that you will either see hundreds of the same enemy on a given floor, or you will have to have many different elemental attacks ready making your play rather like a game of simon-says involving far too many healing potions.

You play through the game, completing quests for the various silly NPCs around the main area, unlocking a new dungeon every ten levels or so. It's a fairly good system. If not for the silly quests though, the game would get old fast. Now that the game is ending, you get five times the experience you would have otherwise. That means you can blow through a half-dozen levels in an afternoon, rather than one. Not that it matters. All levels matter is what skills you have available to you, and which enemies give you experience points. I'm now thirty levels too high to gain experience points in the first dungeon, but I still encounter swarms of enemies that force me to use healing potions, and enemies I can't kill in one hit. What's the point of being so powerful if you don't actually get stronger?

Despite all my nitpicks of the game, it does have a je-ne-sai-quas that makes it fun. Or, fun most of the time at least.

Monday, September 21, 2009

Randomly written story

Some undetermined length of time ago, in some undetermined place, some undetermined entity did some undetermined thing which ended up creating a dungeon.

Generating a story out of nothing is something that is easy to do at a most base level, but very difficult to do at a complex level that the player is likely to care about. Anyone can throw together a random plot generator with a few set paameters. After all, attacked the king, and fled into the . That makes a compelling story, right?

On the king's corination two years ago, your father built a great vast dungeon. The dungeon was built on the other side of the river, to keep for himself the alchemists stone. Unfortunately, for him, your evil twin located the dungeon, just yesterday.

With more variables, like my opening line, you can wind up with some interesting permutations of plot. But what does the player care if it's not going to affect the game? You could add in random snippets of plot and paste them all together, perhaps even generating a great fantastic tale. But the player is there to play a game, not to read a book. If they skip the story sections will it affect the gamepla any? It should, if only in little ways.

Long before you were born, a long ago king built a great vast dungeon. The dungeon was built just over the mountains, to seal away a terrible evil. Unfortunately, for them, a disloyal knight located the dungeon, just A few days ago.

Obviously, the villian I noted has to show up somewhere in the dungeon. How long ago determines how deep in the dungeon he should be. The builders of the dungeon should affect what the dungeon looks like, archetecture wise. How old the dungeon itself is should affect what sort of monsters have moved in. Newer dungeons should have less of a veriety of monsters than an older one that's had time for different monsters to move in and out, lock more doors and so on. And most importantly - the purpose for the dungeon should be what gets discovered on the last floor.

A few months ago, a lost civilization built a great vast dungeon. The dungeon was built not far from the castle, to seal away the fountain of youth. Unfortunately, for them, a murderer from a thousand years in the future located the dungeon, just as you are reading this.

Furthermore, each important randomly generated aspect of the dungeon should have *things* in the dungeon to relate to. Crumbling rooms for old dungeons versus unfinished ones for really new ones. Alchemical labratories show up in a dungeon designed to hold the alchemists stone. Magic circles show up in dungeons holding back a terrible evil. You get the idea.

Some short time ago, an evil DM wrote an article on randomly generating stories. The article was posted on a blogging site to open it to the public. Fortunately for you, you just read this article.

Wednesday, September 16, 2009

Havok and Chaos

So, I mentioned that I had started a new campaign on this website I'm part of. It's just gotten off the ground a few days ago, and so far it's going well. The characters are already out of their cells and it's only been what, thirty seconds since the guard slipped and hit his head? They're very resourceful.

Which is encouraging, because I don't actually have a plot for this game beyond the first castle. I have a plot for some good guys to come chasing them after, but at the moment they have to make their own goals. Some players are good with this, some aren't. Many players simply wait for a prompt from the DM before they take *any* action, let alone one that progresses the story.

In Havok and Chaos, I'm going to have to get creative, because at least at first they won't have any NPCs friendly to them. I'll have to dig through the character's backgrounds, find their motives, and build their story around it. How exciting.

Saturday, September 12, 2009

Real Dungeon Design

In order to properly build random dungeons, you have to understand the way that real dungeons are built up. And in order to understand how real dungeons are built up, you have to know what they were before they got filled with monsters.

Probably the most obvious one is the abandoned temple. However, the contrast between a real-life temple (or even one not yet abandoned), and one where monsters are crawling about is pretty staggering.

Real temples (take a church for instance) have one main area of worship. This is typically almost as soon as you come in, funnels as much traffic from the entranceway into it as possible. There are a few side passageways that occasionally connect and have a few small side-rooms off of each of them. That's about it. If you look at one designed to be a dungeon, you have to climb down three ladders, and walk down a hundred feet of corridor to get to the main altar way in the back. On the way there are dozens of branch-off passages each with one or more rooms, but none of them have obvious "main altar this way" signs. Most of the passages are even the same size!

Okay, it's more interesting like that, but less realistic. Is there a middle-ground? Of course, and while it requires just a little bit more work, it also produces far better results. Take a look at the map below.


This map could have been a real temple. One main entranceway, one main passage to the main altar, several smaller walkways to side rooms. Perfect. How does it make a good dungeon then, if you could just walk in and get to the biggest room undoubtedly holding the baddest guy? That dark grey circle in the middle. That represents a cave-in, and the main passageway is blocked from all sides, so you can't just stroll straight in. You have to take a side passage around the main walkway, entering about half the rooms in the dungeon and work your way to the other side of the rubble. It looks like a real place, it acts like a real place and it took one single grey circle to make it a good level, rather than just a real place.

Now that you have a basic design, you determine room use by location. Those mid-sized rooms right before the end? One's a bunk, the other's a mess. The small ones near the front? storage. The funny shaped ones around the side, library and kitchen. The more used and desirable a room is, the more it goes near the other desirable and used rooms. Thus, the food and the sleep go beside the worship, but the place to put all the extra mats for the ceremonies is further away (although you could put a closet nearby, containing treasure...). And the basic design is done. You can fill it with whatever you want, be it orcs and wizards, to a dragon and dopplegangers. What it was is set and now it just has to be a place for players to go and kill monsters.

Tuesday, September 8, 2009

PC of the living dead

So, I'm working on a new DnD campaign. It's a mid-level evil campaign where the characters are starting by breaking out from prison. That's not quite so important, but one of the characters applying to join the game has the ultimate goal of becoming a lich, which is a great goal for an evil campaign, right?

But what about the other characters? Liches are strong creatures, and when one becomes a lich, there's essentially a four level increase in power all at once. The other players alongside this character have to either get a similar increase in power or deal with an inferiority complex for a few levels. Both have some serious issues.

Becoming a Lich takes some time in-game, so let's say that the character goes off for one adventure to do this, while the other characters adventure. What does the player for that character do? Does he go away while the other characters gain *four* levels? That could be months! So, that's not really a plausable option. Does he play with nerfed powers? That's probably a good idea, although it won't be as fun for the player who now has to wait through even more time in order to complete their transformation. Why spend so much money to have to wait so long to actually get the bang for your buck.

So, we give the player all their powers after, say, one missed session. Now, the other players are four levels behind, give or take. Everything everyone does is incomparable to what the lich can do. He outcasts the casters, he soaks up more damage than the meatshield, he is more effective sneaking around than the rogue. So the other players need to gain power to match. Do they gain four levels to catch up? Then the lich suddenly feels gipped - he just sold his soul to gain power, and now everyone else auto-magically catches up to him for free. Same issue with items, either the Lich has to get a share of some way-overpowered treasure (making him even more powerful), or he'll be gipped. You could potentially squeeze it in while he's off becoming a lich but that'll still be taking from him one of the best bits of becoming the lich in the first place - power.

The best solutions I can come up with are these: Either the player has to spend levels as he approaches lichdom and slowly gain the power it would bestow. It requires building a several-step lich class, but that's a small amount of work for the pain you would otherwise be inflicting upon yourself. The other option is that lichdom requires a sacrifice of several class levels to do so. The player would have to take the option: lich power, or class power. It's not a bad option but it cuts down a lot of things the player's worked for for a good while.

Anyone else have an opinions?

Thursday, September 3, 2009

Four walls

Clearly I had no idea what I was talking about when I said starting a blog was the hardest thing to do. Coming up with things to talk about in a development blog when development is sluggish - that's what's hard.

Recently I've added roofs to the rooms in my dungeon. Before a player enters them, they are dark. After a player enters them, they're bright. Hurrah! Right?

There's a few issues this raises that aren't immediately obvious. Items in the rooms are drawn after the rooms themselves (that is, the room is drawn on the map, then the items are drawn in the room). Since the roof is part of the room, and not an item in the room - what do you do with all the items? Do they dissapear? Do they only generate when you enter the door? How about things that move other than the player entering a darkened room? The best solution I can see with the engine I have is to simple not draw any item that's in a room that hasn't been discovered yet. It'll be a little more computationally intensive than, say, keeping each room as it's own object and going from there. (rooms are collections of coordinates, see.)

The outside, of course, will have to count as a room too. Otherwise there might become strange logic as to things not being in a room - although with my code the way it is, things don't care about rooms or not, yet. Hell, they don't really even care about walls. But the outside has to be made a room just for carefulness's sake.

But now is the big question: walls.

Why are walls such a big issue when I'm drawing the rooms? Because you shouldn't be able to see them when you're walking around outside the building - you should only be able to see the walls once you've got inside. So, walls don't appear until you've entered the room. Great, the building will look like a big black shape on the map, because we now aren't drawing *exterior* walls. And If I start to keep them in their own buffer, what about when I draw a funny shaped building? What if I want to change the code to add more rooms on?

Sigh, times are tough...

Wednesday, September 2, 2009

Non-Player-Characters

No matter how much effort you put into your world, the player will only see what is on the surface without some method of relaying information to them. Sure, you could provide the player with a library of documentation, but that gets dull, and there's little way of guiding the player away from things they don't need to know until later, and things they might want to know now.

Enter the NPC, or non-player-character. This title officially covers anything in the game that can think, but isn't controlled by the player, although it's come to be a term for only friendly characters the player meets along their route. Evil characters are villians, anything that attacks you is a monster - or perhaps a boss. They're not considered an NPC until they shake your hand and say something to you.

In a video game, most NPCs typically have one, and exactly one, peice of information to give the player when prompted. You have to wonder what the player asks to get such varied responses from people all over the world, "What's going on?" perhaps? Regardless, the information almost always remains static throughout the game unless something signifigant happens in the area, at which time the information changes to that NPCs comment about the event.

NPCs are usually used to say something about the current point in the story and the current area the player is in. An NPC in the castle might say "Sigh, times are tough." An NPC in the forest might say "The green snails are plentiful this year." They provide you with a little window into the setting that the player wouldn't otherwise get a chance to know. Most of the information isn't useful, but it's interesting for the player to know. Sometimes what they say is important, but that's not quite what I'm talking about here.

While this is an essential window into the world, there is a problem with it. Once an NPC says the same thing twice, most players won't talk to them ever again. To make the NPCs more lifelike, more dynamic in the world, there needs to be a list of things for them to say. This can be drawn from a pool of tidbits about the current point in the story "I hear the volcano in Maxitone errupted", information about the area the NPC is in "granny makes so many pies now that the apples are ripe, anyone can get one", and a few that could be used for any NPC across the world, "My feet are sore". This lets the NPC, with little extra effort, suddenly becomes interesting for the player to listen to more than once. But, there has to be a balancing act between interesting and repeating. If the NPCs always have something new and interesting to say, the player's never going to go and save the world, they'll spend all day chatting in town!