A variant on turn-based combat

 
Post new topic   Reply to topic    mudlab.org Forum Index -> Design
View previous topic :: View next topic  
Author Message
KaVir



Joined: 11 May 2005
Posts: 565
Location: Munich

PostPosted: Tue Oct 16, 2007 12:01 pm    Post subject: A variant on turn-based combat Reply with quote

In turn-based combat there are usually two ways to represent the execution of attacks:

1. The attacks are executed at the end of the turn. The drawback with this is that you end up with a whole bunch of attacks being launched simultaneously and non-interactively, without taking into account the relative speed of the fighters.

2. The attacks are executed as entered, until you've used up your quota for the turn. The drawback with this is that fast players can spam their attacks at the start of the fight (or, if it's an advantage to wait until last, people can set triggers to launch their attacks at the last possible second).

I've been thinking of alternatives, and here's an idea I came up with:

Combat consists of 60 second turns, each split into two 30 second halves. You gain 20 action points each turn, and may also retain up to 10 unused action points from the previous turn (excess points are lost).

In the first half of the turn you can spend action points on anything you wish, including offensive techniques. Different actions cost a different number of points. No blows are exchanged during this time - this is the preparation half.

In the second half of the turn, the attacks are executed, spread out throughout the turn depending based on their action point cost (1 action point takes 1 second to execute). During this time you can only spend action points on very specific non-attack actions.

Example: Bubba vs Boffo.

Bubba chooses to thrust with his longsword (speed 5), then whirl it around his body (speed 3) and swing at Boffo's head (speed 8). This uses 16 action points.

Boffo chooses to duck (speed 4) then perform a cleave with his greataxe (speed 10). This uses 14 action points.

After the 30 seconds preparation are complete, we enter the second half of the turn, second by second:

1:
2:
3:
4: Boffo ducks (increasing his defence).
5: Bubba thrusts at Boffo, stabbing him with his longsword.
6:
7:
8: Bubba whirls his longsword around his body.
9:
10: (Boffo spends 2 action points to steady himself, recovering his defence)
11:
12:
13:
14: Bubba swings at Boffo's head, while Boffo cleaves Bubba.

(continues up to 30, although there are no more attacks after this point - perhaps skip to the end when all players are finished)

The end result is a combination of turn-based and speed-based. You get to plan out and prioritise your actions for the turn, with each action executed in order, and each taking a specific amount of time to perform. But you also have to be ready to patch up your defences on-the-fly when necessary, perhaps even giving up an attack to turn it into a much-needed block, or a recovery from a leg-sweep.



Another variant on the above that I considered was to have 30 second turns, whereby you could spend action points for immediate defensive techniques, but any attacks you entered would be executed in the next turn. Thus you'd be throwing up defences to counter attacks which your opponent had initiated the previous turn, while preparing attacks for your opponent to deal with next turn.

The drawback of this variant is that it could get spammy, and attacks might feel sluggish - you'd need to plan the attacks in advance, and couldn't respond quickly to an opening. Of course if the combat represented something like clashing armies or ocean-based ship battles (where orders should take time to be carried out), that could perhaps be an advantage.
Back to top
View user's profile Send private message Visit poster's website
Author Message
ide



Joined: 21 Feb 2006
Posts: 105
Location: Seattle

PostPosted: Sun Oct 21, 2007 10:37 pm    Post subject: Re: A variant on turn-based combat Reply with quote

KaVir wrote:
In turn-based combat there are usually two ways to represent the execution of attacks:

1. The attacks are executed at the end of the turn. The drawback with this is that you end up with a whole bunch of attacks being launched simultaneously and non-interactively, without taking into account the relative speed of the fighters.

2. The attacks are executed as entered, until you've used up your quota for the turn. The drawback with this is that fast players can spam their attacks at the start of the fight (or, if it's an advantage to wait until last, people can set triggers to launch their attacks at the last possible second).


Why would (1) above not take into account relative speed? Sure, the combat would be non-interactive, but the system could account for combat results in some kind of branching fashion on the fly based on what happens first, right?

Anyway I like the alternative. You could combine the alternative and the variant, where attacks you entered in the preparation phase didn't go off until several turns later. You could even neatly combine one-on-one, squad-level, and company-level tactics in this way, with larger-scale movements needing a couple of turns to complete, while you hack it out on a turn by turn basis. Also some spells (calling thunderstorms, flocks of skeletal ravens, locusts, etc.) could take several turns to fire. For example:

Turn 1:

Preparation:

1. Lunge with my spear.
2. Invoke Shadow Plane demon horde gate.
3. Send Pikemen in flanking maneuver.

Execution:

1. Lunging attack.

Turn 2:

Preparation:

(etc.)

Execution:

1. Gate opened.
2. Pikemen flank.


Players might intentionally save over points for defense, if they notice a big attack might be coming in a subsequent turn.
Back to top
View user's profile Send private message Send e-mail
Author Message
KaVir



Joined: 11 May 2005
Posts: 565
Location: Munich

PostPosted: Mon Oct 22, 2007 7:22 am    Post subject: Reply with quote

Quote:
Why would (1) above not take into account relative speed? Sure, the combat would be non-interactive, but the system could account for combat results in some kind of branching fashion on the fly based on what happens first, right?


Well you could certainly execute the attacks in a specific order based on the speed of the attackers. But what I meant was that all of those attacks will be executed at the same time, which doesn't give the player any chance to change their tactics or adjust their defences between attacks, even if their character is far faster than that of their opponent.


Quote:
Anyway I like the alternative. You could combine the alternative and the variant, where attacks you entered in the preparation phase didn't go off until several turns later. You could even neatly combine one-on-one, squad-level, and company-level tactics in this way, with larger-scale movements needing a couple of turns to complete, while you hack it out on a turn by turn basis.


Hmmm nice idea, particularly for large-scale battles. Perhaps the number of turns required could even depend on the quality of the troops? Elite troops might attack the next turn, while conscripted peasants might always be three turns behind, representing the ability of well-trained troops to quickly respond to orders.
Back to top
View user's profile Send private message Visit poster's website
Author Message
shasarak



Joined: 29 Jun 2005
Posts: 134
Location: Emily's Shop

PostPosted: Mon Oct 22, 2007 11:46 am    Post subject: Reply with quote

KaVir wrote:
Well you could certainly execute the attacks in a specific order based on the speed of the attackers. But what I meant was that all of those attacks will be executed at the same time, which doesn't give the player any chance to change their tactics or adjust their defences between attacks, even if their character is far faster than that of their opponent.

Isn't it rather in the nature of turn-based combat that it is... well, turn-based? Smile That is, you carry out a set of actions during your turn, then your opponent carries out a set of actions during his turn, and so on? When I think of "turn-based" I think of a game like "Civilisation", with a whole series of moves and attacks during one side's turn, and a whole series of moves and counter-attacks in response; you don't get to change your tactics until your opponent's turn is finished. If you can, then it isn't really turn-based any more.

The way you model one character being faster than the other in a turn-based system is by allowing the faster character a larger number of attacks during the course of his turn.

In my distant youth I used to play a pen-and-paper RPG called "Golden Heroes" in which your character was a comic-book-style super-hero. The combat system it used was quite interesting, and I've often wondered if it could work in a MUD.

Each combat round is divided up into "frames", which correspond to a single comic-book picture. Any given action typically takes either one or two frames - a punch takes one, use of an energy or psychic attack takes two. Super-powered characters get 4 frames per round, while normal humans get 2. Certain minor super-characters might get 3.

At the beginning of each round there is an initiative roll which determines the order in which characters can use their frames. So, for example, in one round the frame sequence might be:

Shasarak frame 1.
Shasarak frame 2.
KaVir frame 1.
KaVir frame 2.
KaVir frame 3.
KaVir frame 4.
Shasarak frame 3.
Shasarak frame 4.

In a different round KaVir might get all four frames in a row at the start of the round followed by all four of Shasarak's. (Possible options, IIRC, were 4/4/0, 3/4/1, 2/4/2, 1/4/3, 0/4/4).

Let's suppose we're in an S1, S2, K1, K2, K3, K4, S3, S4 sequence, as above. Shasarak throws a punch at KaVir and hits. KaVir now has a choice: he can either stand there and take full damage from the blow, or he can try some form of defence such as a dodge or parry which (if successful) will reduce or eliminate the damage. However, if KaVir opts for a defensive strategy, this will also use up frames: a dodge will use up one frame, use of a power might use up two.

So, suppose Shasarak uses his first two frames to launch an energy attack at KaVir, and KaVir responds by using one of his own energy attacks to parry Shasarak's, that will use up two of KaVir's frames for that round, so he will only have two frames remaining to counter-attack.

To make things a little more even, it is possible to "steal" frames from the next round in order to defend against attacks in this one; but you can't attack during stolen frames, only defend, and that obviously reduces the amount of attacking you can do in the next round.

The feel of combat that uses this system is rather appropriate for a superhero fight: you tend to get a sequence of two or three rounds in a row where one character is launching attack after attack, then finally the other character gets the initiative and counter-attacks; think of Spider-Man frantically dodging repeated incoming bullets, then finally getting the chance to counter with a spray of web fluid.
Back to top
View user's profile Send private message
Author Message
KaVir



Joined: 11 May 2005
Posts: 565
Location: Munich

PostPosted: Mon Oct 22, 2007 2:02 pm    Post subject: Reply with quote

shasarak wrote:
Isn't it rather in the nature of turn-based combat that it is... well, turn-based? :) That is, you carry out a set of actions during your turn, then your opponent carries out a set of actions during his turn, and so on?


Not necessarily - turns can be taken either in sequence or simultaneously (Diplomacy is a good example of the latter). In my opinion, the defining characteristic of a turn-based game is that each player has the time to think and plan their move/s (as opposed to real-time, where time spent thinking is a wasted opportunity to act).

I don't think turn-based in sequence is a very effective approach for combat systems in multiplayer games, as you can end up waiting around for a long time for the other people to make their moves.
Back to top
View user's profile Send private message Visit poster's website
Author Message
Zephen_Descartes



Joined: 21 Sep 2007
Posts: 20

PostPosted: Wed Oct 31, 2007 7:12 am    Post subject: Reply with quote

Here's a gamasutra article on designing AI for turn-based strategy games. I found it insightful when applying it to turn-based combat as well. Your mileage may vary.

http://www.gamasutra.com/view/feature/1535/designing_ai_algorithms_for_.php
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    mudlab.org Forum Index -> Design All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2001, 2002 phpBB Group
BBTech Template by © 2003-04 MDesign