Author Topic: TWOK Bridge anim problem  (Read 2242 times)

Offline Lurok91

  • Posts: 1309
  • Cookies: 2062
  • SPMod Developer (Retired)
    • Lurok91 Mods
TWOK Bridge anim problem
« on: May 13, 2010, 10:34:34 AM »
Animated chair ingame but not synching up with crew move.  Anyone know solution?  (If it involves Character Studio/biped, then screwed  :) )


Offline JimmyB76

  • Posts: 6423
  • Cookies: 421
Re: TWOK Bridge anim problem
« Reply #1 on: May 13, 2010, 10:49:08 AM »
hmmmm   i think it does involve Character Studio...
i am not certain tho...  you may want to fire off another PM to Mark (or LC, who goes by "Legacy" there) and annoy them until they respond...

Offline Kirk

  • Posts: 1438
  • Cookies: 139
    • My Released Mods
Re: TWOK Bridge anim problem
« Reply #2 on: May 13, 2010, 05:22:13 PM »
What about Viper and his damn "disk?"

Offline teleguy

  • Posts: 363
  • Cookies: 53
Re: TWOK Bridge anim problem
« Reply #3 on: May 14, 2010, 09:25:23 AM »
I don't know how animations are done but maybe you could try attaching the crewman to the chair like this:

pObject1.AttachObject(pObject2)

Offline Lurok91

  • Posts: 1309
  • Cookies: 2062
  • SPMod Developer (Retired)
    • Lurok91 Mods
Re: TWOK Bridge anim problem
« Reply #4 on: May 14, 2010, 10:13:41 AM »
I don't know how animations are done but maybe you could try attaching the crewman to the chair like this:

pObject1.AttachObject(pObject2)

thanks for tip.   Where would that go in scripts, and which one(s) ?

Offline teleguy

  • Posts: 363
  • Cookies: 53
Re: TWOK Bridge anim problem
« Reply #5 on: May 14, 2010, 10:24:48 AM »
As I said I don't how the animations are done.
Could you post the scripts for that bridge?

Offline Lurok91

  • Posts: 1309
  • Cookies: 2062
  • SPMod Developer (Retired)
    • Lurok91 Mods
Re: TWOK Bridge anim problem
« Reply #6 on: May 14, 2010, 11:15:01 AM »
This is my understanding of how animations are called:
Bridge script lists all animations used by all crew on that specific bridge
Character script lists specific animations used by specific crew member, and links to:

(bridge)Medium/Small/LargeAnimation script...

I think this is the key script, as it 'calls' the specific animation movement... i.e., triggers open/close door,  and links crewmember movement to specific chair animation.  I know this because I've got anim doors to work. and as can see from above, have chair and crew anims - just not synched together  :).  It might be the frame timing of my animation is wrong, and all I need to do is lengthen it. Will try that, but in the meantime....

Example from ENAMediumAnimations:

Code: [Select]
def ENATurnAtCTowardsCaptain(pCharacter):
kAM = App.g_kAnimationManager
kAM.LoadAnimation ("data/animations/ENA_face_capt_C.nif", "ENA_face_capt_C")
kAM.LoadAnimation ("data/animations/ENA_chair_C_face_capt.nif", "ENA_chair_C_face_capt")
pSet = App.g_kSetManager.GetSet("bridge")
pBridge = pSet.GetObject("bridge")
pBridgeNode = pBridge.GetAnimNode()
pCharacter = App.CharacterClass_Cast(pCharacter)
pSequence = App.TGSequence_Create()
pOpenEyes = Bridge.Characters.CommonAnimations.EyesOpenMouthClosed(pCharacter)
pSequence.AddAction(pOpenEyes)
pAction = App.TGAnimAction_Create(pCharacter.GetAnimNode(), "ENA_face_capt_C", 0, 0, 1)
pSequence.AddAction(pAction, pOpenEyes)
pAction = App.TGAnimAction_Create(pBridgeNode, "ENA_chair_C_face_capt", 0, 0)
pSequence.AddAction(pAction, pOpenEyes)
return pSequence

where 'face' is the character anim move and 'chair' is the chair (doh) anim.  There are usually two separate Turn codes, one towards captain, and a reverse.

Hope that helps  :)

Offline teleguy

  • Posts: 363
  • Cookies: 53
Re: TWOK Bridge anim problem
« Reply #7 on: May 14, 2010, 11:56:27 AM »
After checking several scripts it looks like even though each character exists as a separate object the bridge chairs don't but are instead loaded as part of the larger bridge object. Therefore attaching crewmen to individual chairs won't work.

Offline Lurok91

  • Posts: 1309
  • Cookies: 2062
  • SPMod Developer (Retired)
    • Lurok91 Mods
Re: TWOK Bridge anim problem
« Reply #8 on: May 14, 2010, 11:59:31 AM »
Thanks for trying to help anyway.  Much appreciated.  I'm sure we'll come up with a solution soon somehow  :)

Offline Lurok91

  • Posts: 1309
  • Cookies: 2062
  • SPMod Developer (Retired)
    • Lurok91 Mods
Re: TWOK Bridge anim problem
« Reply #9 on: May 16, 2010, 07:29:59 PM »
Thanks to Sov over at BCS (good call J), got more of an insight into how the animation works.  Unfortunately I still need to learn how to recreate the original bridge anims from the old masters.  Once I learn that I should be able to anim chairs properly.

Offline Viper

  • Retired Administrator
  • Posts: 268
  • Cookies: -65520
  • BC Legend
    • KAG
Re: TWOK Bridge anim problem
« Reply #10 on: July 13, 2010, 09:02:07 PM »
What about Viper and his damn "disk?"

Viper has the DISK, but it only contains working files, bipeds, and the starter scripts.  You still need CS and a working knowledge of how to do anims and scrips to each bridge.  And none of it works on windows 7, so I cant even open the disk anymore.  And I never finished the anim tutorial. 
Viper
"The original Meister der Brucken"

Offline Bren

  • DS9FX Team
  • Posts: 750
  • Cookies: 33
  • 6EQUJ5
Re: TWOK Bridge anim problem
« Reply #11 on: July 14, 2010, 01:45:54 PM »
I don't mean to offend, but the way the chairs tip over before turning back just cracks me up!  :funny
"The sky calls to us, if we do not destroy ourselves, we will, one day, venture to the stars." - Carl Sagan

Klingon Academy now works on XP/Vista/Win 7 thanks to one dude's patches, click here for details. I highly recommend it!