Modeling fighting stances in medieval swordsmanship

Madoc

Project Lead
As it is our efforts would go into generally improving movement and footwork to make it appear more balanced and deliberate. It's important to understand that none of the functionality can be expressed with some if/else statements, there may be 4 base input directions from the player but there's no such thing as a forward step or backward step. The input directions are relative to a facing direction which may not be forward or whatever relative to the character's current pose and during that step the character can turn by large amounts, often determined by physics and inertia as much as inputs. Not even the starting conditions are known. The feet are always moving in unpredictable ways to keep the character in balance and are subject to many conditions. It can't be compared to an IK system where things are given explicit inputs and behave deterministically, any number of things could affect the outcome. It's hard to explain but the actual movement of the feet is the result of interaction by a surprisingly large amount of things and ultimately at the mercy of physics. Achieving the right balance between physics interaction and explicit control is very tricky. We can't even use standard angle based IK because there's some unquantifiable magic that needs to deal with physical forces, the simulation is just too complex and unpredictable to approach the problem deterministically. It's a system built on intuitive approximation and trial and error, very little is actually known in terms of conditions and goals.

Hopefully that makes some sense. I know for a fact that some of the core concepts are quite similar to those used in modern robotics but in practice it's quite different because we're not dealing with robots performing known tasks in the real world. The rules are less specific and also more mutable.

Regardless, I'm not at all convinced that constantly shuffling the feet when striking would make for an improvement. A character just standing there chaining attacks would be constantly shifting their feet which I imagine looking quite silly. In many action games attacks involve some movement (or silly stuff like 360 spins), I can't think of any games where the character is stationary during attack chains where each attack causes the feet to move into new positions. Moving the feet without moving the body (at all) is just not really a thing. Also to consider is how in our game you can cancel an attack any point. I can only imagine something like this working if certain combinations of movements and attacks would result in holding a different stance if only temporarily, which again sounds quite complicated considering how freeform the movement is and how the feet are actually planted on the ground and don't slide.
 

Blackbeard

Member
@calithlin thank you for reply and support. You understood it like I conceived it -- yes, it would resemble some node based AI. Thank you @Madoc for clarifications and guidelines about footwork. Therefore, allow me to suggest more feasible solution. The approach is changed, but the concept stays the same, and also opens new possibilities (again no IK and no precanned actions).



I wrote a lot before, so to cut to the chase, I'll use this video as an illustration. After your clarifications Madoc, that is approximately how I see/ imagine what's happening inside physics algorithm. In other words, you showed me a black box, clarified the input and presented the output. The WASD input ("input directions, relative to a facing direction") during weapon swinging is analog to the moving platform in the above video, and the output is similar.


I'll list all facts you stated for the clarity of the upcoming ideas:
  • none of the functionality can be expressed with some if/else statements
  • no such thing as a forward step or backward step
  • the input directions are relative to a facing direction
  • not even the starting conditions are known
  • the feet are always moving in unpredictable ways to keep the character in balance
  • DON'T behave deterministically
  • the actual movement of the feet is the result of interaction by a surprisingly large amount of things and ultimately at the mercy of physics
  • we can't even use standard angle based IK because there's some unquantifiable magic that needs to deal with physical forces
  • it's a system built on intuitive approximation and trial and error, very little is actually known in terms of conditions and goals.
Solution?

Everything that you described Madoc sheds light away from messing with well optimized physics system to changing the input... Could solution be NOT to allow player to put demands on a model system (i.e. character) that are not realistic or manageable? As I see it, the system is behaving as expected (I would also be unstable if I am swinging a weapon, which has a momentum, on "unstable terrain", or if someone pushes/pulls me).

In other words, could the solution be to augment the input from the user and to convert continuous input to discrete one? Here is what I mean -- after pressing and holding LMB you probably know how long does it take for the character to launch the attack (i.e. chamber the attack and swing the weapon) -- maybe there could be some flag to tell you or it could just be some empirical approximation.

So let's say you can determine when 2/3 of the strike passed and when the strike ends -- that's a time window we observe. Would it be possible, in that time window, to diminish the WASD input and to reduce the intensity of vectors (forces) that influence the stability? Demanding such input from the player would be too stressful and messy (press, release, press, release...), but underlying filter/ algorithm could make necessary adjustments instead of the player.

That would drastically reduce "tennis player horizontal dive" movements of the center of gravity. If that's possible, then I would go with decreasing sigmoid function, since it is imo the most "natural" function you could use. Of course -- after the strike ends (or is interrupted) there should be a recovery of movement input. Everything that I said before applies here -- stability (no external forces messing with the balance) should be synchronized with the very end of the strike!

That's the idea. What are the consequences (results)?

No feet shuffling necessary, natural stepping movement during combat, upright combat stance when finishing the strike, no unnecessary stepping due to lack of balance, better implementation of character development (no probability; visible improvement in balance during combat), more possibilities for feints...


------------------------------
@Vold thank you for your understanding. I am glad you replied.
 
Last edited:

Madoc

Project Lead
I'm a little more clear on what the perceived problem is now. This mostly results from prioritising player control over realism, it's a matter of not correcting the character's balance when this would cause involuntary movement that would not be desired by the player and might prevent intentional movement from working. Interfering with user inputs is definitely not a solution we would adopt.

Situations in which the character is poorly balanced arise because every part of the body actually has inertia and the input system is designed to give you some control over that, you can throw your character's weight around with the mouse and keyboard (which is pretty cool btw). You can specifically control your character in such a way to make their movements look much more elegant and balanced. We've gotten pretty good with this in the latest version, it's effective as well as more elegant. It's mostly a matter of giving well timed and measured inputs, allowing the character to cleanly perform actions rather than constantly throwing them into unnecessary motion which ultimately gives you more precise control. Sometimes though you need to be able to make that desperate move and it might look clumsy but you want it to work!

In the latest version you can also go pretty wild with the controls with some very exaggerated motions (as I did in the latest development video) and while it doesn't always look neat it remains very functional and you still feel in control. This is a huge improvement over earlier versions.

I actually have a specific solution in mind to improve both balance and responsiveness but I'm too busy with other aspects of the game to implement it now. There's a lot of other specific things that could be improved and I've been doing this almost constantly since the Kickstarter. That's the whole problem really, there's so many components and variables and interaction between them that tweaking any part of the system needs to involve the others and requires extensive testing, it's extremely time consuming work. I've actually taken into serious consideration something that could automate this process, that is capable of benchmarking methods and parameters so I could just leave it running for hours and get something useful from it. Unfortunately that would be quite difficult to set up, especially the benchmarking part. A lot of time has gone into testing promising ideas that just didn't work out for reasons that were basically impossible to foresee, and that's with having designed every aspect of the system myself. Watching old videos isn't going to provide the best insights, you should at least play the game and get a feel for what is actually happening and possible. Most importantly pretty animation is secondary to everything gameplay, the problem needs to be analysed with that in mind, we want to find ways to improve both and definitely never sacrifice gameplay. Some people may enjoy looks or apparent control over actual control and better video footage may sell more but we're not going to compromise what we want from the game for that.
 

Blackbeard

Member
  • interfering with user inputs is definitely not a solution we would adopt
  • every part of the body actually has inertia
  • you can throw your character's weight around with the mouse and keyboard (which is pretty cool btw)
  • it's mostly a matter of giving well timed and measured inputs
  • sometimes though you need to be able to make that desperate move and it might look clumsy but you want it to work!
Oh well... I speak about one thing and you (and majority of people here) speak about the other. At least we had interesting discussion about it. Thank you.

Conclusion is that user input with keyboard and mouse buttons is binary --- pressed (1) or released (0).

One could directly convert that input to vector intensity (force) (i.e. 0% or 100%, nothing in-between) or model some natural rise and decay times.

Idea was to stabilize the balance at the last 1/3 (or 1/5) of the strike which would not interfere with (or ruin) any of the five points quoted above.​

I respect your development plan and ideas for Sui Generis. And once again -- it is really fantastic work you are doing! I hope I'll have the means for testing the game soon.

Good luck
 

blobface

Insider
I think one of the issues this game faces in regards to combat is that it's much more realistic than any other combat games we have ever seen, the comment on it being "off balance" / "drunk" is mostly because it's treading so close to the uncanny valley that we instantly pick up any small un-natural detail, while we would shrug off any crazy physically impossible moves while looking at other games where everything is pre-animated. But as pointed out, it is entirely possible for players to play in a way that makes your character appear much more controlled / elegant, it's largely dependant on the player / situation. They still have a whole game to make, what we've had so far in the demo has been really amazing compared to any game I've experienced.
 
Last edited:

Blackbeard

Member
@blobface you missed the point...
  1. it's much more realistic than any other combat games we have ever seen
  2. it is entirely possible for players to play in a way that makes your character appear much more controlled / elegant, it's largely dependant on the player / situation
1) that's the reason why I wrote so much here -- because I prefer how Sui Generis looks like over pre-animated games -- I agree with that!
2) and I am sure there are "workarounds"...

However, I pinpointed one aspect that might be corrected (or modeled differently) in order to improve gameplay --- translation of keyboard input (press/ release) into physical force. Since game is based on physics, my common sense was to make gradual (fine) increase of the force instead of instantaneous (robust).

Consider this example: any flying/ driving game --- it is difficult to play with keyboard because there is no graduality in force. If you have joystick or gaming wheel then it is completely different story, do you agree? Of course you can play it in such way that the aircraft/ car movement is less jerky. It's only a "workaround" and it will always be jerky in some degree. It can be fun in arcade games...

So my question to you @blobface is this:
If you are making driving game what would be dynamics of steering?
How much would steering wheel turn if I press right for 1, 2 or 3 seconds?
Would you make my car drift and spin around (steering wheel comes the full circle with "pedal to the metal")?
But what if there would be something to assist you with playing on keyboard so it feels the same as playing with joystick/ gaming wheel?
 
Last edited:
Nevermind, I reread the thread and my statement was pointless. Though I don't like a game like blade symphony among those dodge/counter spam games.


Anyway though, this thread is a very interesting read and agree with your points whole heartedly.
 

Blackbeard

Member
I made a quick check about steering (example I wrote above) and found some interesting terms like: steering ratio, understeer and oversteer, and speed-sensitive power steering.

Here is the definition of the latter and imagine it's not about steering but about combat maneuvers (namely keyboard inputs):
With speed-sensitive power steering, also known as variable-assist steering, the amount of power assist increases at low vehicle speeds and decreases at higher speeds.

Providing more power assist at low speeds makes the steering lighter and easier to turn, a benefit when squeezing into a parking space or maneuvering in tight quarters that requires quickly turning the wheel lock-to-lock. Conversely, at highway speeds, steering that is too light would make it easy to overcorrect with abrupt steering changes. Instead, variable-assist steering dials back on the power assist to make the steering firmer at highway speeds with more on-center feel.

Variable-assist steering is common, yet many drivers may not know they have it. They only know that the steering is light and responsive at parking speeds but not too light at highway speeds.
 

blobface

Insider
I agree to some extend that it shouldn't require practice to just act in a way to look "natural", but then again, most people trying to play a flight sim would crash on their first few goes while they could effortlessly fly a fighter jet on GTA5, and in the world of combat games, I think SG would be closer to a simulator.

Anyway, to your question, I might have misunderstood you, but I don't personally believe the attack / parry is "binary". While it is true that it is checking whether we are clicking or not clicking, we use the cursor position to decide the direction we face, you can control how hard you strike by how much you swing your body behind the strike, it feels very fluid despite the simple control. As for WASD, I think increase in force by holding it for longer (like you do in most simple games with cars as your steering analogy) is somewhat doing the opposite of what you are trying to get your character to do. If you want to make a sudden wide step, the intention is an immediate one, you'd want the character to initiate the move as quickly as he can, so perhaps if I press D and let go immediately, the character would try to take the widest possible step his stance / stats would allow him to as quickly as his can, but if I were to hold it for a little longer and let go, one could then control how small a step to take with each input, so holding D without letting go would actually make the character "strafe" slowly to his right. That said, reversing it and doing it that way would make the control harder, as it adds more pressing and letting go, and in some odd ways a bit like how Apple OS reversed the scroll bar direction which "makes sense" but confuse the hell out of everyone. Besides, what I just described there is close what they have already in a much more simplified way, but instead with double tap input for wider steps.

My point in the post above was that having played the combat demo for a while, I'm finding it very enjoyable and able to control the character without much effort (after practice), I'm now mainly focused on fighting the opponent (or sometimes, deciding how to finish them off) instead of making my character look balanced. As with everything, I'm sure there's room for improvement, however, a relatively drastic (we can disagree on what the word mean in this context) review of the combat system at this point might not be appropriate any more as they have a whole game ahead of them to make which I believe they should prioritise on, but I'm sure they welcome as much well constructed suggestions and feedbacks such as yours as possible.
 
Last edited:

Blackbeard

Member
@blobface, your reasoning is correct and here comes the hardest part for me -- to show you that I am saying the exact same thing. Nothing opposite to what you are saying. Therefore, it was interesting for me to answer to almost every sentence :)

  1. in the world of combat games, I think SG would be closer to a simulator
  2. ...while they could effortlessly fly a fighter jet on GTA5
  3. ...most people trying to play a flight sim would crash on their first few goes...
  4. I don't personally believe the attack / parry is "binary" [...] we use the cursor position to decide the direction we face
  5. I think increase in force by holding it for longer (like you do in most simple games with cars as your steering analogy) is somewhat doing the opposite of what you are trying to get your character to do.
  6. If you want to make a sudden wide step, the intention is an immediate one, you'd want the character to initiate the move as quickly as he can [...] so holding D without letting go would actually make the character "strafe" slowly to his right. [...] with double tap input for wider steps.
  7. [...] very enjoyable [...] control the character without much effort [...] I'm now mainly focused on fighting the opponent (or sometimes, deciding how to finish them off) instead of making my character look balanced
  1. And that's how I see SG too. Therefore, I draw an analogy with a flying/ driving simulator and precision of the input via keyboard vs. gaming wheel.
  2. The question is: why can they effortlessly fly a fighter jet in GTA5 ? Answer: it is not a simulation. Physics are different and there is high threshold for vehicle damage -- it's made for casual arcade players. Subconsciously (imagination, pretending) players accepted the framework (possibilities and restrictions) because -- it is a game (i.e. they don't care about physics, 'cause that's the whole fun of it). However, there are mods for realistic car damage -- what's the result? -- higher player's awareness that controlling is jerky and stressful.
  3. And I would add: if they are playing flight sim with keyboard and (most important) if they are playing in the same way as they play GTA. The approach to the game is also a factor.
  4. Yes, that's misunderstanding. I am not talking about mouse control, that's completely fine. I am focusing only at controlling the body movement via WASD keyboard input.
  5. We will stay with the analogy, so the question is: what does one expect from a car steering system ? If one is driving fast one would expect fine steering and if one is standing still full steering range would be fine. Keyword: dynamically changing. Example: my friend got AC: Black flag, so I tried it and I was surprised with ship steering. Different speeds had different maneuverability which was both pleasant for playing and believable. It also made many tactics possible, which would be difficult to pull out with conventional steering.
  6. And I know this confuses a lot of people here - but I never suggested anything that would change that. My suggestions evolved from checking on which foot is the character (and Madoc explained it is not possible) to dynamically altering players input. So what you wrote stays! As the title of the thread says "Modeling fighting stances..." -- it's not intended to decrease gameplay possibilities.
  7. And we finally come to the point -- idea was that player doesn't have to make character look balanced, but that character is balanced without compromising joy of playing, degree of control or the effort needed to master it.
Here is the idea from above, presented as diagram
That is only a model and of course I couldn't determine the timeline. However, if I use driving analogy again, explanation is this (also see point no. 5 above): in the moment when strike should connect you expect fine control of body movements and while you are preparing a strike a full movement control (i.e. highway speed vs. parking speed = speed-sensitive steering).
Of course, the workaround is this: as a player, when you are driving fast you should make bursts of short button presses and when you are driving slowly bursts of longer ones.

Madoc said that all physical parts have inertia and that made me think about forces that are influencing the movement. It became apparent to me that WASD input is maybe not adequate (because it is binary per se all the time) and that analog example of such issue is arcade driving vs. driving simulation. So I gave a thought to a net force (and wave interference) and asked myself what if player could be on the constant move while body steering is adjusting dynamically according to the striking rhythm.

I have no better way to explain it... :( maybe it seems like a fantasy... With this speed-sensitive steering analogy I tried to present an example how this solution is implemented in cars both in real life and in video games to make controls more precise.

----------------------------------------------------------------------
EDIT:
Here is the real life example - a commercial done by Volvo about Volvo Dynamic Steering, along with live demo. So the model system is the same as before -- we have a driver and a truck -- but in-between there is an assisting system that opens new possibilities for the user.

So in SG, this would be Strike-Sensitive Body Steering Assistance :cool:
[...] you can throw your character's weight around with the mouse and keyboard (which is pretty cool btw) [...] sometimes though you need to be able to make that desperate move and it might look clumsy but you want it to work!
And regarding a quick tap or a double tap (that you mentioned) -- they could override this assistance!! I found information that some button taps in fighting games (namely Just Guard in SC5) must be no more than 4 frames long (1/15th of the second! [ref]). The whole window is 6 frames, starting on the release of the guard. Players are using it even to counter-just-guard! That's really fast!

Why am I writing this? Because such quick tap (or double tap) could override any assistance and still give you what Madoc wrote above -- that one clumsy desperate movement that you need occasionally. Which means player would have more possibilities in the gameplay.
 
Last edited:
Top

Home|Games|Media|Store|Account|Forums|Contact




© Copyright 2019 Bare Mettle Entertainment Ltd. All rights reserved.