PlaySubGraphAnim and PlaySyncAnim

Post » Mon Jun 18, 2012 2:52 am

Hello fellow modders !

I am trying to control the animation graph myself but I can't seem to do it with what I was able to find.

I found that PlaySyncAnim allows me to play an anim but I am unable to execute it on other nodes than the player's character.
PlaySubGraphAnim on the other hand did not get me anywhere, I didn't manage to do anything, could you guys give me some hints so that I can find the events that need to be passed to the animation ?

Thanks !
User avatar
Theodore Walling
 
Posts: 3420
Joined: Sat Jun 02, 2007 12:48 pm

Post » Sun Jun 17, 2012 6:33 pm

I think you may need "PlayAnimation/PlayAnimationAndWait" or "PlayIdle"

PlaySubGraphAnimation is for objects attached to actors with their own Behavior Graph -> this mainly refers to animated armors...
PlaySyncAnimationSS/PlaySyncAnimaionAndWaitSS are both for syncing two actors to start playing 2 anims at the same time.
User avatar
Dustin Brown
 
Posts: 3307
Joined: Sun Sep 30, 2007 6:55 am

Post » Sun Jun 17, 2012 7:40 pm

I tried those aswell, didn't get anything working either, do I need to use the HKX's file name as argument ?
User avatar
Oyuki Manson Lavey
 
Posts: 3438
Joined: Mon Aug 28, 2006 2:47 am

Post » Mon Jun 18, 2012 1:11 am

I tried those aswell, didn't get anything working either, do I need to use the HKX's file name as argument ?

You can reference Animations by their Idle Animations ID or by an Event Function Name but the easiest way is by passing the animation through a Property like:

Idle Property MyAnim Auto -> then you set this property to point to the Idle you want to play.

Event OnWhatever()
Self.PlayIdle (MyIdle)
EndEvent
User avatar
.X chantelle .x Smith
 
Posts: 3399
Joined: Thu Jun 15, 2006 6:25 pm

Post » Mon Jun 18, 2012 3:55 am

But how would I play a running animation for example or attacks ?

Thanks for your help :)
User avatar
sam westover
 
Posts: 3420
Joined: Sun Jun 10, 2007 2:00 pm

Post » Sun Jun 17, 2012 9:51 pm

Nobody knows ?
User avatar
Sophh
 
Posts: 3381
Joined: Tue Aug 08, 2006 11:58 pm

Post » Mon Jun 18, 2012 4:46 am

Still no ideas ?
User avatar
Cheryl Rice
 
Posts: 3412
Joined: Sat Aug 11, 2007 7:44 am

Post » Sun Jun 17, 2012 7:22 pm

Still no ideas ?

I'm the same situation as you. I need to play the slash animation but apparently there is no way to play them. Just have to wait until SKSE implements a feature to force an animation.
User avatar
Gill Mackin
 
Posts: 3384
Joined: Sat Dec 16, 2006 9:58 pm

Post » Sun Jun 17, 2012 8:26 pm

Its not so much that no one knows its that SendAnimationEvent(), the function that SHOULD be able to send any anim event to the graph -> does not work for anything other then Idles just like PlayIdle making it kinda worthless overall.
User avatar
R.I.P
 
Posts: 3370
Joined: Sat Dec 01, 2007 8:11 pm

Post » Sun Jun 17, 2012 7:33 pm

Its not so much that no one knows its that SendAnimationEvent(), the function that SHOULD be able to send any anim event to the graph -> does not work for anything other then Idles just like PlayIdle making it kinda worthless overall.

Omg! I just found out how to play any animation at will. In the Idle manager go to any Action and click one of the Action roots (like the ID). Copy the "Anim Event" and there you go! I just used the AttackStart Anim Event and it worked! Yeah! An example script would be:
......Event OnEffectStart(Actor akTarget, Actor akCaster)         Debug.SendAnimationEvent(akTarget, "attackStart")EndEvent;Note: AttackStart must be used while an Actor is in an Alert state.
User avatar
Maeva
 
Posts: 3349
Joined: Mon Mar 26, 2007 11:27 pm

Post » Sun Jun 17, 2012 8:28 pm

Always me.

How do you set an actor to be in alert state ? that's the missing key for me
User avatar
Rhysa Hughes
 
Posts: 3438
Joined: Thu Nov 23, 2006 3:00 pm

Post » Sun Jun 17, 2012 6:04 pm

MyActor.SetAlert(true) ..
User avatar
Killer McCracken
 
Posts: 3456
Joined: Wed Feb 14, 2007 9:57 pm


Return to V - Skyrim