Advertisement Jump to content
Sign in to follow this  
Master thief

In what ways can a text adventure have combat?

This topic is 1858 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've been planning a text adventure for a long time now, and combat is the part that's been giving me some trouble. I'm trying to avoid "dice rolls" in my game, which makes matters worse, and I don't know if I can actually avoid it.

 

To give you a better idea of what I'm trying to achieve, this is not your ordinary text adventure but rather a more... graphical one, with actual buttons and maps, inventory, item icons, etc, and I'm even considering having some sort of NPC graphics for encounters and dialogues. Otherwise every feedback the player gets is text as usual.

 

In essence, my goal with the combat system would be, ideally, to provide the player with a chance to be skillful at it. But... again, I'm a bit at a loss on how to do such a thing in this type of game. So for now I'm trying to figure out in what ways can a text based game have combat, so that I can take as much into consideration as I can, and hopefully come up with something. Or if someone has any great ideas I'd be happy with that too. :)

 

Any help or insights would be greatly appreciated.

Edited by Master thief

Share this post


Link to post
Share on other sites
Advertisement

Do you have any thoughts on what sort of experience you want your player to have while engaged in combat? Do you see your player carefully contemplating decisions based on reports of numbers or is he maybe reading an exciting blow by blow account of the action? Do you want the player interacting such that he controls every blow, every block or do you want the player to just decide whether to begin combat at all?

 

Avoiding dice rolls is entirely possible. If you really take a look at combat and boil it down to its basics, you pretty much know, as the designer, what the outcome should be. Assuming the player is making typical decisions, you'll probably want combat to last X rounds leaving the player at Y health. He will encounter Z instances of combat between points A and B that will provide him enough experience and money needed to proceed to C.

In all honesty, adding in bits of randomization only modifies this result slightly because you still actually want your player to get from A to B and all the way to the end. What you're trying to do with combat is provide an entertaining challenge between those points. Adding randomness does provide a bit of suspense, but it isn't really fun to be at the mercy of a dice roll. It can however be fun to try and work out a strategy to survive getting from A to B, especially if there are several options available to do it.

Share this post


Link to post
Share on other sites

Here's a simple and a complex way to do it. I think you want the complex.

Simple, damage based entirely on stats. Essentially you can limit the options as much as possible, and the options are context sensitive and uniform.

 

you see a pig as tall as a house

the pig sees you

the pig snorts at you

select action: attack, run away

attack

you hit the pig 0 damage

the pig snorts at you

(the player may have about 10 hp and the pig has 30 hp)

 

Complex, damage based partially on decision. You can assign context sensitive options like push button, as well as allow the player to many standard actions like move or look:

you see tiger

the tiger sees you

the tiger lunges at you

you have time to react

select action: dodge, parry, take, look, drop item

take

list of things you can take: tiger, self

tiger

list of things on the tiger: optionally automatic [, list of body parts[, list of detectable items tiger carries]

front left leg

you reach for the tiger's front left leg

the tiger bites your right hand

your hand is bleeding

report: (status ailments of some kind show up when available)

your right hand is being held by the tiger

you are holding the tiger's front left leg

select action: attack, run away, take, look, drop item

attack

list of things you can attack: tiger, self

self

... I'm skipping the dialogue ...

right hand

you release the tiger's front left leg and strike your right hand

the tiger throttles you

report:

right hand is dismembered

 

... skipping more since I can't keep it uniform anyway ...

take

self

inventory knife

you equip a knife

the tiger is eating

report:

right hand is dismembered (since it always will be maybe the message should be optionally filtered out)

 

attack

tiger

automatic

you stab the tiger

the tiger thrashes (unintentionally)

the tiger reacts

the tiger drops something

report:

the tiger's neck is bleeding heavily

you dropped your knife

 

 

A player with more experience would have dodged, pulled out their knife, and attacked a specific part of the tiger's body.

 

This is an example similar to Dwarf Fortress which is not entirely text but it relies heavily on text, each character has limbs and vital organs. The game itself is not entirely combat oriented.

Share this post


Link to post
Share on other sites

Skill in games is largely about resource management. Randomisation does not change this, it only means you have to integrate over a probability distribution. So, allow the player to say (for example) "I hit the monster with 10 mana". This does a deterministic, not stochastic, amount of damage, ranging from blowing a goblin to Jupiter up to scratching the hide of a dragon. The challenge is to maintain your limited mana (and other resources) until you get a chance to stock up; so skill consists of not using 10 mana on a goblin, because that's a waste, but recognising that the dragon must be hit with 100 mana, or it will hit you back and that will not be nice. Add other resources to make the management more multidimensional (also, maybe mana is scarce and even one point is overkill on a goblin - hit it with your sword, instead, thus only expending rapidly-replenishable stamina points). This also allows monsters to have different vulnerabilities, thus allowing the player to acquire "lore skill", that is, skill that consists of knowing water elementals are vulnerable to fire mana, but not to edged-weapon attacks, and deploying their resources optimally accordingly. Of course, all this is basically just bog-standard RPG combat; the only difference is that it doesn't have to be stochastic. Make the damage algorithm deterministic and be done. 

Share this post


Link to post
Share on other sites

Do you want a "system" that is reusable for each encounter, or are you okay tailoring each encounter specifically?

Share this post


Link to post
Share on other sites

The problem with eliminating dice rolls is you remove variability from the combat.  Say in the course of your game, you'll be fighting multiple goblins.  If the player learns that punching twice and kicking once kills a goblin, they will do that to every goblin they see.  Dice rolls give the goblin a chance to dodge, parry, take more or less damage from punch to punch.  With this kind of combat system, having static values and results to every action gets boring quickly.

 

One alternative is what a few people have mentioned already: tailor each encounter differently.  It creates more of a puzzle solving aspect to the combat.  Punching twice and kicking once killed that first goblin, but this one has a shield.  What are the actions and sequence I need to use to get around that?  It makes winning each battle more akin to solving a puzzle.

 

Another alternative (that I've only half baked just now) might be to create some variability with selecting the actions themselves.  Rather than typing punch every time to punch, maybe there is some code or pattern you need to crack to figure out what to type to throw a punch.  Maybe the more damaging actions (a fire spell) are behind more complicated codes.  I may not be explaining this very well, but the root of the idea comes from games like Puzzle Quest.  A punch will always do the same amount of damage, but the difficulty is in managing to pull it off.

Share this post


Link to post
Share on other sites

There are a lot of great ways to handle combat in a text-based game. Here are some free MUDs with combat for you to experiment with..

  • Godwars 2 - This game has an interesting and complicated combat system that involves a queue of commands for your limbs.
  • Star Wars: Knights of Darkness - This Star Wars themed MUD uses the SWR codebase which has pretty basic combat, but with some interesting additions. The game has ranged combat with blasters which allow players to snipe at enemies in adjacent rooms, as well as space travel and space combat.
  • Iron Realms - Iron Realms isn't a game, it's a company that makes a lot of good MUDs with different themes. Pick the concept that interests you most and experiment with their combat.

Share this post


Link to post
Share on other sites
Thanks for all the feedback. You've all given me quite a lot to think about.

Dwarf Fortress' combat system is actually one of my inspirations. I like the blow by blow approach. Is DF's combat based on dice rolls? (I don't play the game in quite some time, I can't recall much of it)

Share this post


Link to post
Share on other sites

If you can get the The Riddle of Steel Combat Simulator from their support page http://www.driftwoodpublishing.com/support/ to work, then that gives a an overview of how text-based combat can work. It's certainly skill based but with a whole bunch of dice involved so it's random as well. Like Poker.

 

What kind of  "dice rolls" are you trying to avoid? For example, is rock-paper-scissor ok? I choose attack A, enemy (randomly!) chooses attack B. A beats B so I win. As an extra bonus, with markov chains you cam make an AI for it if you want tougher opponents. http://www.nytimes.com/interactive/science/rock-paper-scissors.html?_r=0

 

I like the King of Men's talk of resource management. Let's say a swashbuckler has stamina, health, durability of his sword, four hidden daggers and two pistol shots. Stamina regenerates quickly, health slowly, sword not at all until you find a new one. Health loss in swordfights is inversely proportional to the amount of stamina expended. Throwing a dagger gives you the opportunity to run away. Pistol shots are instakill but rare obviously.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!