Triggering model animation

Triggering model animation

Re: Triggering model animation Posted by NenadGojkovic on Sat Jul 18th 2009 at 11:48am
NenadGojkovic
1 post
Posted 2009-07-18 11:48am
1 post 0 snarkmarks Registered: Jul 18th 2009
Hi everyone. I'll get to the point right away. Is it possible to make a door model act like lets say, func_door_rotating, a door model that opens and closes just like a brush entity, for Half-life 1? For example, you come near the model, mean door, you press your use key/E, and the door goes 90 degress. You press the use key again, and the door closes (or door closing no matter what). Ofcourse, the opening and closing would be animation done in ms3d or whatever. The question is, can you control/activate that animation? Similar as within the scientist in Half-life1. You press your use key or E, he positions towards you and begins talking. I need something, I need somehow to start model animation when I come near it. Animation > [door opens, stay open for a while, closes]. How to trigger animation, over and over again, that's basicaly my question. In HL2 doors are models. Can the same be done for HL1?

Nenad
Re: Triggering model animation Posted by Riven on Sat Jul 18th 2009 at 5:20pm
Riven
1640 posts
Posted 2009-07-18 5:20pm
Riven
Wuch ya look'n at?
super admin
1640 posts 1266 snarkmarks Registered: May 2nd 2005 Occupation: Architect Location: Austin, Texas, USA
I think so, yes. If I remember right, there are func_doors in Hammer 3.4 right? You could make a simple door model that didn't even have a swing animation, perhaps just a knob jiggle and parent that whole door model to an invisible and collisionless func_door. When players use the func_door it would behave as if the model itself was responding to the player. Set an output so that the func_door causes the door model itself to play its knob animation, and I'd think you'd be good to go!
Blog: www.playingarchitecture.net
LinkedIn: Eric Lancon
Twitter:@Riven202
Re: Triggering model animation Posted by fishy on Tue Jul 21st 2009 at 6:23pm
fishy
2623 posts
Posted 2009-07-21 6:23pm
fishy
member
2623 posts 1476 snarkmarks Registered: Sep 7th 2003 Location: glasgow
Riven said:
You could make a simple door model that didn't even have a swing animation, perhaps just a knob jiggle and parent that whole door model to an invisible and collisionless func_door.
Parenting in HL1, nice. :roll:
Re: Triggering model animation Posted by Le Chief on Wed Jul 22nd 2009 at 1:53am
Le Chief
2605 posts
Posted 2009-07-22 1:53am
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
fishy said:
Riven said:
You could make a simple door model that didn't even have a swing animation, perhaps just a knob jiggle and parent that whole door model to an invisible and collisionless func_door.
Parenting in HL1, nice. :roll:
I don't think Riven has worked much in the GoldSource engine. Plus you can parent in Spirit Of Half-Life. 8-)

As for your question, I'm pretty sure it can be done in Half-Life. It's been so long since I last did anything in Half-Life so I can't remember how you actually trigger animations but I'm sure you can.
Aaron's Stuff
Re: Triggering model animation Posted by Riven on Wed Jul 22nd 2009 at 12:59pm
Riven
1640 posts
Posted 2009-07-22 12:59pm
Riven
Wuch ya look'n at?
super admin
1640 posts 1266 snarkmarks Registered: May 2nd 2005 Occupation: Architect Location: Austin, Texas, USA
Well, I just exposed myself didn't I :oops: Shows how much time I've spent in the goldsource engine :sailor:
Now I remember why I never answer Half-Life Editing questions :scared:
Blog: www.playingarchitecture.net
LinkedIn: Eric Lancon
Twitter:@Riven202
Re: Triggering model animation Posted by fishy on Thu Jul 23rd 2009 at 12:49am
fishy
2623 posts
Posted 2009-07-23 12:49am
fishy
member
2623 posts 1476 snarkmarks Registered: Sep 7th 2003 Location: glasgow
lol, there's a reason that I didn't offer any alternative. :hee:

As far as I remember, the only way to change an animation of a model was by shooting/hitting it, and that only cycled it to the next animation. Also, models had to use the cycler entity, which spurtted green blood when you did hit it. And there was no physics model either, only the bounding box of the model to define it's space.

All in all, the whole business of adding models in goldsource was very primative, and definately not suited to details like door animations.
Re: Triggering model animation Posted by Condus Mundus on Wed May 12th 2010 at 2:07am
Condus Mundus
169 posts
Posted 2010-05-12 2:07am
169 posts 118 snarkmarks Registered: Apr 24th 2010 Occupation: Thinking up random profile details Location: Forty minutes south of Nowhere.
I really don't know if anyone is still watching this thread, but I'll throw my two cents in here anyway.

NOTE this is very complicated if you're making lots of doors like this, but I think it would work this way if tried. (pay no attention to the arrogant man behind the curtain :leper: )

STEP 1
you take 3 scripted_sequences, one for opening anim, one for closing anim and one for a knob jiggle if its locked(this will be left out unless requested later). You then stack all the scripted_sequences so that the door will sit properly for all anims.

STEP 2
you make a func_rot_button about the size of the door model set with the not solid spawnflag, targeting a multi_manager.

STEP 3
you make a multi_manager to be targeted by the func_rot_button, that then targets the first scripted_sequence to open the door, waits mabye 3 or 4 seconds and then activates the closing anim.

STEP 4
you make a func_door_rotating the same size as the door, covered in the NULL texture, and rig it up in the multi_manager to open and close when the model plays its anims.

I wish I had a door model to experiment with to see if this works, but alas all is speculation.
Now remember kids. Asking questions is a good way to get censored by the government.