• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

Fighting Animations!

What if we exchanged the model for one with a saber in hand as part of the model? However then you could only have one type of saber. This could be used for some sort of "duelling mode", where the opponent chooses weapons (meaning he always gives you the same one), and then only in duels you could use the advanced (`key-controlled`) moves.
But I guess we're getting carried away again ..

Cat: Modding is more difficult because you have to watch out so the blood doesn't get into your keyboard..
 
LOL that's why i have one of those watertight rubberkeyboards. And it also does less damage if I smash it against the monitor in frustration.

Hooray, individual fencing moves seem to be in reach. Can only contribute an observation though: the jump ani for my Very Crude Jumping Move plays only once, and I can define how long it plays like this:
LAi_tmpl_ani_PlayAnimation(pchar, "jump", 0.2)

But I tried to do the same with one of the dying ani, and it repeated endlessly no matter what time I set. Is it possible that there are different types of animation, some looping, some not?
 
<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->Is it possible that there are different types of animation, some looping, some not?<!--QuoteEnd--></div><!--QuoteEEnd-->
Yes- that's set up in the ani file. But you can easily change it there.
 
Oh gosh, you're right... I forgot about that... it's sort of a `bitch-slapping` animation that redcoat does (and then your guy is all, "ungh, please don't hurt me, whine whine waaah," or at least that's how I see Nathan's cowering), and it's called up by some attack name with a number. I never experimented with different numbers... I'd wanted to trigger an event where a guy shoots you instead of slaps. What I'd ended up with was my NPC hitting me repeatedly instead of once, and my guy wouldn't play dead until after he'd received several blows. It's all in the event timing I guess...

NK, you mentioned left/right slashes... aren't those when you're fighting while surrounded, and you kill a guy in front of you and then whip around fast and hit someone else?
 
CCC, when I try your jumping animation and my sword is drawn, my character sheathes his sword after making the jump...?

Maybe this isn't quite in the sphere of these animations, but is there any reason `first-person` `fight-mode` wouldn't be `do-able`? More exact aiming for one, like a crosshair for your pistol (and there's that other crosshair image Akella made and included in the files but never used)?
 
Inez: We can still do individual moves, we just have to hit a move key and then the attack key.

Regarding playing animations. When you use LAi_tmpl_ani_PlayAnimation(), (or LAi_ActorPlayAnimation, which works like that but for actors rather than all types) it resets the character's type, sets stay mode, and _then_ plays the animation, and then returns the character to old type (i.e. if player to player type).

CharacterPlayAction is the thing that actually triggers the animation (and is called by LAi_tmpl_ani_PlayAnimation() at the end before resetting type back to start).

Alan, re: left/right. Ah, yes, I have some flicker of a memory of this. Bet you're right.
 
<!--`QuoteBegin-NathanKell`+--><div class='quotetop'>QUOTE(NathanKell)</div><div class='quotemain'><!--QuoteEBegin-->I have some flicker of a memory of this.[/quote] <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/mybad.gif" style="vertical-align:middle" emoid=":facepalm" border="0" alt="mybad.gif" /> Nathan, you REALLY should play the game more often! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/icon_wink.gif" style="vertical-align:middle" emoid=";)" border="0" alt="icon_wink.gif" />

Alan, I am MOST intrigued by the thought that there are different fighting moves that are accessed by numbers... I wish <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/urgh.gif" style="vertical-align:middle" emoid=":urgh" border="0" alt="urgh.gif" /> I had more time to investigate it myself!!! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/mad.gif" style="vertical-align:middle" emoid=":c" border="0" alt="mad.gif" />

I am fascinated by all of this, and am eager <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/william.gif" style="vertical-align:middle" emoid=":will" border="0" alt="william.gif" /> to see it in the game <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/duel_pa.gif" style="vertical-align:middle" emoid=":ixi" border="0" alt="duel_pa.gif" /> - it is sooo great to see all these advances in figuring out these animations - excellent job, all!!! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/yes.gif" style="vertical-align:middle" emoid=":yes" border="0" alt="yes.gif" /> <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/par-ty.gif" style="vertical-align:middle" emoid=":cheers" border="0" alt="par-ty.gif" />
 
I was looking last night at the text files that define character animations.. for instance, the one for the monkey says, like, that his "walk forward" animation is "walk forward"... so maybe some can be added... but the file for the player doesn't have a list like that, so I dunno if that's the right track for adding new animation options.

Or maybe you guys are already way ahead of me here?
 
Cat: Heh, yeah. But coding is so _fun_! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/icon_mrgreen1.gif" style="vertical-align:middle" emoid=":cheeky" border="0" alt="icon_mrgreen1.gif" />
Alan: Yup. The player does have such a list (list of what's available is in Resanimman.ani, and what to use in Characters.c), and that's what the first post was about (limiting the number of attack animations specified to control which are used). GMTA! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" />
 
List of anims, and what they are:
Attack1 : slash, left high to right low
2: mirror of 1
3: same as 2 but twist at end.
4: slash, rh to lm to rm
5: mirror of 3
6: mirror of 4
7: Identical to 2!
8: thrust, middle

So sadly we have only 1 thrust anim.

But what we can do, while not adding new anim _data_ to the AN, is add different versions of the each attack at different speeds to the AN<b>I</b>.
----

Inez, can you look at frames `3163-3164` of man.an and see if there's _anything_ in them that may say an event is triggered?
Because while the attack anims have
event = "Attack_slash", FRAME, normal ;slash

The block anim doesn't have an event. So either blocking isn't triggered by anim, or it's in the AN.
 
<!--`QuoteBegin-CouchcaptainCharles`+--><div class='quotetop'>QUOTE(CouchcaptainCharles)</div><div class='quotemain'><!--QuoteEBegin-->: the jump ani for my Very Crude Jumping Move plays only once, and I can define how long it plays like this:
LAi_tmpl_ani_PlayAnimation(pchar, "jump", 0.2)

But I tried to do the same with one of the dying ani, and it repeated endlessly no matter what time I set. Is it possible that there are different types of animation, some looping, some not?[/quote]
I must correct myself there:
LAi_tmpl_ani_PlayAnimation(pchar, "jump", 0.3)

plays one jumping animation (or 0.3 sec?? )

CharacterPlayAction(pchar, "jump")
lets you jump forever. Is there any way to stop that?

Alan, if you don't want your sword sheathed during "jumping" delete the line with the animation command. Makes it look only slightly worse
 
<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->Inez, can you look at frames `3163-3164` of man.an and see if there's _anything_ in them that may say an event is triggered?  <!--QuoteEnd--></div><!--QuoteEEnd-->
There's nothing about events in .an files, but I saw some events in .anI files.
 
Right, the attack defs in the ANI have event "slash" or something.
{Hmm, let me try and see what happens if you comment out that event--maybe then it's no longer an attack?}

But the problem is that the _block_ define does not have _any_ events.
So maybe block is an `engine-side` event rather than `ani-side`?

{I can test that with setting another anim to the block anim}
 
Success!
Blocking using Fight Stand_4:
<img src="http://img117.exs.cx/img117/4075/blocking3nx.jpg" border="0" class="linked-image" />

I did this by creating a new anim define in man.ani called "block fight stand_4", copying the fight stand_4 define, and adding loop=true and removing Probability, and changing the blend time to be the same as block (0.2, rather than 0.4).

List of "fight stand_X" anims:
1: stand with sword angled slightly out, mid (what you usually see when in fight mode)
2: same, but swing left arm down and up
3: `figure-eights` with swordarm, `mid-high`
4: swing sword in 2 "`come-on`" gesture, mid.
5: swing sword in one big arcing "`come-on`" gesture, mid->high->mid
6: drop sword down, then bob back up.
7: drop sword, drop left arm slack, look side to side, then bring both back up.

Note that only `1-4` seem used by the game.

Also: "drop saber" drops blade and brings hands up, "hands up" is the hands already up, kinda waving a little.
 
Fixup of the Attack descriptions:
1: slash, left shoulder to right waist
2: slash, right high to left hips
3: slash, right high to left waist (a bit faster)
4: slash arc, right high to left shoulder to right knee
5: slash, head level out to right as far as arm can go, then left waist and back behind.
6: slash, arc, like 4 but to mid chest height.
7: Identical frame numbers as 2!
8: thrust, middle
 
BTW, if in the TOOL's View animation data window you set the start and end frame in the two textboxes to the start and end numbers in the ani file and then push the "cycle animation" button you can with this one movement alone cycling.
 
EXCELLENT, great job!!! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/onya.gif" style="vertical-align:middle" emoid=":onya" border="0" alt="onya.gif" /> I am impressed! This is sooo COOOOOL! <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/yes.gif" style="vertical-align:middle" emoid=":yes" border="0" alt="yes.gif" /> <img src="http://www.piratesahoy.com/forum/style_emoticons/<#EMO_DIR#>/par-ty.gif" style="vertical-align:middle" emoid=":cheers" border="0" alt="par-ty.gif" />
 
Back
Top