Showing posts with label Dungeons. Show all posts
Showing posts with label Dungeons. Show all posts

Wednesday, 14 April 2010

Dungeons and Room Types

My next blatant theft of a feature from another roguelike will probably be the room names from Unangband. I've deliberately not looked at the code for this on that game, but am designing my own system. I have the implementation worked out in my head for this already, but as ever I need more lubrication for my creative juices!

So let's imagine, say, a circular room in an undead themed level. What could it be called?
  • The most straightforward would be random selection from a list generic names such as "The Slaughterhouse", "The Crypt", "The Necopolis". This would have to be a large list to avoid reusing names.
  • This could be enhanced by adding one of more random adjectives before and after the name, e.g. "The Hidden Slaughterhouse", "The Crypt of Despair", "The Crypt of Hidden Dreams".
  • And then we can consider the role of uniques. If we generate a unique in the level inside a room, name the room after the unique: "The Crypt of Barney", for example.
  • Now, additionally, depending on the name, selected, we could reverse the traditional way of generating dungeons and let the name drive the dungeon features. For example, consider a room called "The Hidden Slaughterhouse" - use of the term "Hidden" would mean the entrances to this room are sealed up with diggable walls (or doors) - and use of the term "Slaughterhouse" would mean that there would be loads of corpses generated in the room, as well as certain types of monsters.
  • There could also be passive effects tied to the room, for example, with "The Hidden Slaughterhouse" there could be a smell that makes the character nauseous whilst inside it.
Yes, I know I'm probably going through the same thought process that Andrew Doull went through about ten years ago, but I'm increasingly convinced random generic dungeons can't cut it any more in roguelikes.

So yet again, its time to ask: thoughts? ideas? Comments are most welcome.

Sunday, 13 September 2009

Sleeping Monsters & Stairs into Vaults

I've added some code to gray out monsters that aren't aware of the character yet:


The mouse over hint will also tell you that they're not aware of you yet. When they wake up, they return to their natural colours:


Incidentally, this was an instance of stairs from the town level leading directly down into a vault. It's not very common, and can only happen on the first entrance to a dungeon branch. The question is, should I disallow stairs from being located inside vaults?

Thursday, 20 August 2009

Big or small levels?

Big levels or smaller levels? is a question that has come up in the long-running Exploitation and Evasion thread over on r.g.r.d.

So...should Kharne keep its current (IMHO) big levels or move to smaller levels?

(if it helps the discussion, I intend for the shortest path through the dungeon to be forty levels, split over four dungeon branches, and for the maximum character experience level to be XL20).

Monday, 15 June 2009

Dynamically bringing the dungeon alive

Its been a good few years since I played Everquest 2, but one of the gameplay ideas that struck me as easily transferrable into the typical dungeon of a roguelike is that of the infamous (if you've played EQ2 that is) "distressed merchants".

To summarise, a distressed merchant appears near other groups of mobs, begging you to help them. Once you have killed the surrounding groups of mobs, then they change into a "gratified merchant", from which you can now interact with (and buy/sell items as the reward for killing the mobs).

They are an example of what in general terms EQ2 called "dynamic adventure camps":


"Dynamic Adventure Camps (DACs) can be found throughout the lands of Norrath, especially in the large overland zones. They are usually structured around an object in the world such as the gnoll tents in Antonica, or the orc siege towers in the Commonlands. DACs are dynamic because the same camp can have many different types of events happen at the same camp, and new events can be added by designers into the mix of the other events already in place. An event is decided at the spawning of the entire camp and will stay in place until a group has completed all the stages of the chosen event. Upon successfully completing the chosen event, the entire camp will despawn. Some camps choose to respawn in the same spot, while others have multiple spawn areas to choose from."

Implementing such a concept in a typical roguelike shouldn't be too hard - since most roguelikes, unlike some MMOs, don't have to worry about the concept of phasing. It does require, as a minimum, that the map layer is able to store and associate data, and that the map can execute triggers based upon some conditional logic.

The problem comes when you end up making allowances for such events across your entire dungeon, perhaps as a result of adding handling for such events to every map cell, and you end up massively inflating the amount of memory (and hence disc space) required for such functionality. The alternative approach of hand-crafting such logic (so beloved of programmers in the days when 64K was a big deal) is obviously not extensible, but with judicious implementation of null pointers (or rather, nil pointers, to be pedantically correct in terms of Object Pascal syntax) mininum overhead can be achieved.

Friday, 1 May 2009

Vista

After much faffing about trying to remember the procedure for reinstalling components into a fresh copy of Delphi, I've got Kharne up and running on the Vista side of things.

Here is a screenie of the Plane of Fire Dungeon:

Our brave hero is in considerable trouble, being attacked in melee by a Fire Elemental and from distance by a Fire Drake. I think currently, without potions and magic being implemented, the game is much too tough. But we'll see.

One thing I would like to add soon is more features to the dungeons, e.g. the plane of Fire should have molten lakes of lava, rivers of fire, and all sorts of features.

Friday, 20 March 2009

News and Updates Addendum

Of course, no sooner than I said what the next release would contain than I've went and changed a few things. I've managed to find and fix an annoying bug with one of the level generation algorithms I'm using.

This particular algorithm is modeled on the one used in Angband, and previously generated levels that often had curious morasses of tunnels in the corners of the levels (the screen grab is from a standalone dungeon generator utility):

The new one, with the bug fix (which turned out to be because I was trying to connect overlapping rooms to themselves) produces slightly smoother output, without the random tunnel ends:


There are still a few bugs in the tunneling code however (sometimes rooms aren't connected properly), which I will fix at some later point.

In addition, on reflection, the previous cave algorithm produced much too disjointed levels. So I added a smoothing function to remove any isolated points of wall and the result is below:


I'll incorporate these changes into Alpha 1c which will be released in the next few days.

Wednesday, 11 March 2009

Feature: Vaults!

I've just put vault handling into the the dungeon generation routines. Here's a sample:


Anyone fancy generating some vaults?

You can use the following terrain features (this scheme follows an Angband-esque convention):
  • Hard, undiggable wall (#)
  • Soft, diggable wall (%)
  • Closed door (+)
  • Clear floor (.)
  • Clear floor with treasure (,)
  • Clear floor with trap (^)
  • Clear floor with treasure or trap (*) (50% chance)
  • Clear floor with monster (0-9) (1-9 specifies the OODness in levels)
Here's the sample vault from the screenshot above, which is 12x4:

############

+,33+*5#3*,#


#,*3#5*+33,+


############



Treasure and Monsters can be specified OOD as you wish. There are twenty levels of monsters and treasure in Kharne in total.

Any vaults you do submit you will get full credit for, of course.

Monday, 9 March 2009

Feature: Dungeon Zones and Regions

A while back, I speculated about the possibility of introducing sub-zones inside dungeons. I#ve just implemented the first iteration of these this evening. These differ from vaults to a degree in that they don't follow any specific pattern, nor are there any greater rewards. Effectively, they're a little part of another dungeon branch inserted into the current dungeon. Monsters will be scaled to be slightly out-of-depth (but not too much), and I'm considering allowing traversal into a different dungeon branch by means of portals contained within these zones (though those aren't implemented yet).

Here's an example of a section of the Plane of Water intruding into the Plane of Fire. Some denizens that normally frequent the Water Plane have came through as well.

The framework is in place for these zones to be dynamic - perhaps they could shrink and expand over time depending on the actions of the player character.

Tuesday, 3 March 2009

Gameplay Idea#4: Class/Race Mutability

In this r.g.r.d. thread, "Cuboidz" asks:

"Maybe we should drop the notion of preconceived character development and try to allow for maximum adaptability. Your character would be shaped by the Random Number Generator, in a way, because you choose your abilities based on the items you find, and the hurdles you have to overcome."

Much interesting discussion follows. It has also sparked an idea of my own.

Currently, I have planned that Kharne will have a conventional character creation system in which skills and abilities are determined (at least in the beginning) by race and class (albeit with an option to allow for randomly choosing a race and class).

But what about giving the player the chance to change these mid-game? Or even have changes thrust upon them? For example: potions that allow you to swap skills and powers. environmental subsections of dungeons that suppress one skill and boost another temporarily. Monster attacks that change your race (think a super-polymorph spell).

Whilst I do think this would be a worthwhile addition to the completed game, where is the line between giving the player additional gameplay options and driving them mad through too much choice?

Incidentally, later in the thread Ray Dillinger comments:

"There are a lot of ways to handle it, not just shops. I think the preferred way ought to be themed dungeon branches. If you've got three different ways of getting from level 20 to level 30, and one leads through a dragon's nest, one through a goblin city, and one through a Temple to the Great Old Ones, you're effectively giving your players a choice."

That's exactly what I have planned with Kharne. There will always be at least two different dungeons for each level range, with loot tied thematically to each dungeon.

Monday, 19 May 2008

Metaplots and Dungeons

All Roguelikes have metaplots, even if its only to give a thin veneer of reason as to why our little '@' hacks his (or her) way through dungeons. In Angband, the goal is obstensibly to defeat Morgoth. In Crawl, its to recover the Orb of Zot. In Nethack, its to recover and ascend with the Amulet of Yendor. Larn has an unusual plot device - the goal is for the player to traverse a dungeon in search of a potion that will cure his ailing daughter of 'dianthroritis'.

I haven't decided what the metaplot for Kharne will be yet, although I'm very interested in exploring different aspects of Roguelike gameplay during the different phases of the game. To this end, like Crawl, I'm going to implemente themed dungeon branches. Unlike Crawl however, I want all the different dungeon branches to be theoretically accessible from the town level (with one exception I'll come to later).

Each dungeon branch will consist of 10 levels, of increasing difficulty. There are 9 branches, therefore there are a maximum possible 90 levels to delve through.

Before describing each dungeon branch, there are a few important things I'd like to note about the intended gameplay:
  1. The challenge to the player should increase as he/she delves deeper. This isn't just a matter of throwing bigger and tougher monsters at the player (although this will happen), rather, I'd like to throw the player into progressively tougher and tougher situations. I have a few idea for implementing this other than some of the standard Roguelike fare, e.g. Vaults, Mutations and increased Monster AI.

  2. I want to avoid Angband-style grinding (e.g. the so-called "Stat-Gain" phase). It won't be necessary to visit every single dungeon or indeed every single dungeon branch - in fact doing so will increase the chances of a death since levels will be dangerous. Dungeons are semi-persistent - whilst within a dungeon branch, levels are persistent, but as soon as you leave the branch and return to town, they will disappear, Angband-style.

  3. I want to allow multiple paths through most of the game, to increase replayability. This would be as well as the standard roguelike randomness replayability. To achieve this end, all dungeons with the exception of the final ones are completely optional.

Player start out in the town level, called the Nexus:


The two introductory dungeons (suitable for levels 1 to 5), are The Wilderlands and The Fortress.


The Wilderlands is built using the cave-generation algorithm whereas the Keep uses the rooms-and-tunnels approach. The Wilderlands will be very much themed upon an outdoor feeling, with animal-themed foes, whereas the Fortress will have a martial setting and will be filled with goblinoids. It is intended that the player uses these two dungeons to learn the basics of Kharne's gameplay and to start the gearing-up process.

Beyond that, there are two intermediate dungeons (suitable for levels 6 to 10) - The Mausoleum and The Keep:



Both use the Rooms-and-Tunnels approach, and the Mausoleum is an undead-themed dungeon whereas the Keep is filled with magical artifacts and creatures. At the moment, I'm intending to have the first vaults appear in the later levels of these dungeons (although vaults aren't implemented at the moment), and the purpose of these are to equip the character with items that are necessary to venture further in a safe manner.

The Advanced Dungeons are suitable for levels 11 to 15 and are basically the Elemental Planes - the Planes of Air, Fire, Water and Earth:


At the end of each dungeon, on the bottom level, is a heavily guarded Elemental Key. This serves two purposes - one of these must be collected to allow the player to enter the final Dungeon (it doesn't matter which elemental plane it comes from), and also one will allow the player to resurrect once, with some....far-reaching consequences (I'll discuss this in more detail in a later post).

And then we have the endgame dungeon, suitable for levels 16 to 20, and the final part of the game. At the moment, its called the Abyss, and its filled with demons and devils and other similar creatures. There will be a macguffin at the bottom of this dungeon, the obtainment of which will be the game's victory condition.


Although the majority of foes in each dungeon will be specific to that dungeon and themed to fit in with that dungeon's theme, there will be a set of common foes across all non-Abyssal dungeons. Some of these will be in the form of demonic and elemental "invasions", with creatures scaled appropriately to the current dungeon difficultly (effectively these will operate as moving and non-permanent vaults). Other will be in the form of rival adventurers and adventuring parties. I'm especially looking forward immensely implementing these, as I remember fondly in Baldur's Gate the first time I came across a rival adventuring party.

Oh, and there will be one other special dungeon...which is specifically tied to player ressurection. I'm still working out the details, but to give you a bit of a hint, this is one of my favourite tabletop-RPGs of all time.