Combine Door Kick

Tutorial collection, comprehensive listings on main site.

Combine Door Kick

Postby Tutorial on Sun Jul 31, 2005 8:57 pm

category
General Half-Life 2/Scripting

description
Have a metrocop kick open a door and start firing at you.

keywords
combine, door, doors, kick, metro, cop, metrocop, npc_metrocop.

In this tutorial we will be making a Combine MetroCop kick open a door. You will need the following entities with names:
  • npc_metropolice - booter1
  • ambient_generic - door_spank
  • scripted_sequence - kick_door1
  • prop_door_rotating - door_exit1
  • trigger_once
The first thing to do is create the door way and add a prop_door_rotating to it. Give it the name door_exit1 and if you don't want the player to open the door first, then tick Starts Locked in the Flags. (You will need to unlock it with a seperate output that isn't listed in this tutorial, adding it to the initial trigger is fine)

Now we need to position an npc_metropolice in front of the door, to make sure he aligns correctly go to the Model tab in his properties and change it to kickdoorbaton. This will enable you to line up his foot with the door. Don't forget to name him booter1 as listed above.

Now, we need the scripted sequence. There are two ways to place it, either on the npc_metropolice with MoveToPosition set to No, or move the metrocop back a bit and leave the sequence in his place and the set MoveToPosition to Instantaneous. Either way is fine, but I have used the latter, harking back to my HL1 habits. Again name it as listed above.

Finally add an ambient_generic above it all, and name that as above. And pop a trigger_once some distance from the door.

So far everything should be named as listed, and looking like the below:

Image

Now that everything is in place it is time to set it all up.

The npc_metropolice is fine with just a name, feel free to dabble with weapons etc but it's not necessary.

Moving on to the scripted_sequence, there are a few things to add here.
  • Name: kick_door1
  • Target NPC: booter1
  • Action Animation: kickdoorbaton
  • MoveToPosition: Instantaneous
Flags:
  • No Interruptions
  • Override AI
  • No Script Movement
And finally add the following outputs:

Image

Ok, the door should be fine with just a name, but also crank up the speed to about 250 so it looks like it has taken a good kicking. Let's address the ambient_generic next:
  • Name: door_spank1
  • Sound Name: ambient/materials/door_hit1.wav

Tick all 3 Flags as well.

Ok we're almost there. What will happen is the combine will play out his animation, and then the door will fly open with a loud banging noise. We've added a slight delay so that his foot has time to connect and it doesn't look out of time.

Now we just need to trigger it.

Take your trigger_once and add the following output:

Image

Now, as soon as you walk into the trigger it will set off the scripted_sequence which then takes care of the rest of the sequence with it's outputs:

Image

There you go!

Blink
- Don't send PM's to this user -
Tutorial
Not A Real User
 
Joined: Sun Mar 06, 2005 11:00 pm

Postby wiggle987 on Sun Jul 31, 2005 9:11 pm

Gah I was too late. :(
Image
User avatar
wiggle987
Veteran
Veteran
 
Joined: Mon Nov 22, 2004 8:54 pm
Location: O RLY?

Postby Spas12 on Sun Jul 31, 2005 10:31 pm

yummy new npc tutorial.
Past Treyarch Level Designer

Portfolio
Spas12
Veteran
Veteran
 
Joined: Thu Mar 31, 2005 3:21 pm
Location: trapped in level-design factory, send help

Postby nickmade on Mon Aug 01, 2005 3:49 am

excelent!
nickmade
Been Here A While
Been Here A While
 
Joined: Fri May 20, 2005 1:58 am
Location: The internetsss

Postby YokaI on Mon Aug 01, 2005 5:44 am

Will work nicely for my sc2 map :)
YokaI
Forum Goer Elite™
Forum Goer Elite™
 
Joined: Fri Dec 03, 2004 12:38 am

Postby ki11in6_5pr33!!!!!!! on Tue Nov 29, 2005 9:59 pm

Worked great. Thnx! :D :D :D
User avatar
ki11in6_5pr33!!!!!!!
Dumpling
Dumpling
 
Joined: Sun Nov 27, 2005 3:50 am
Location: Ottawa Ontario

Postby Mathieu on Tue Jan 31, 2006 3:53 am

I'am confused on this part.

Now, we need the scripted sequence. There are two ways to place it, either on the npc_metropolice with MoveToPosition set to No, or move the metrocop back a bit and leave the sequence in his place and the set MoveToPosition to Instantaneous. Either way is fine, but I have used the latter, harking back to my HL1 habits. Again name it as listed above.

Where do i put the MoveToPostion??? Output, input, flags.etc???
Mathieu
Regular
Regular
 
Joined: Sun Jan 29, 2006 6:20 pm
Location: United States of America

Postby Grantax on Thu Mar 16, 2006 2:11 pm

MoveToPosition is in General (or whatever the First tab is called) in the scripted_sequence.
Grantax
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Tue Mar 14, 2006 1:33 pm
Location: Norway

Postby Kodox on Sat Aug 05, 2006 4:26 pm

Try to figure this one out: The player is spied by a combine camera which flahses red and sets off an alarm, triggering a metrocop to kick open a nearby door and allow a wave of combine trooops to storm in. The door could also explode. Im serious if anyone knows how to do this please help me out! THnx.-kodox
User avatar
Kodox
May Contain Skills
May Contain Skills
 
Joined: Fri Jul 21, 2006 7:54 pm
Location: Ohio

Postby SoulReaper on Sat Aug 05, 2006 4:39 pm

Thanks for the tut man, good job :)

And btw kodox, if you have Half-Life 2: Episode one i think you will see exactly what you want. I have it, and there is a combine device used to blow open doors, and you hear it beep a few times then boom!! It blows the doors open and combine floor in. All that you need extra is for the Combine camera to have a output of finding the player to activate the bomb to explode.

But because this is episode one, and your using Half Life 2, thsi will have to be slightly different.

Sorry for going off topic
SoulReaper
Been Here A While
Been Here A While
 
Joined: Wed Aug 02, 2006 11:50 am

Postby Kodox on Sat Aug 05, 2006 5:40 pm

exactly what i wanted to do but thats ok. I'll need to start using the HDR if I want to impress the community though lol!
User avatar
Kodox
May Contain Skills
May Contain Skills
 
Joined: Fri Jul 21, 2006 7:54 pm
Location: Ohio

Postby InternalRage on Sun Aug 06, 2006 10:28 am

Is there anyway to get him bang on the door first? Like in the apartments of HL2, where they break the dudes door down.
Damn ProZak is... sexy!
Image
User avatar
InternalRage
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Tue Jan 10, 2006 8:41 pm

Postby Kodox on Sun Aug 06, 2006 10:56 am

Heh, that would rock. For explosion thouhg just add an env_explosion and an output like onfoundplayer>explosion1>explode
User avatar
Kodox
May Contain Skills
May Contain Skills
 
Joined: Fri Jul 21, 2006 7:54 pm
Location: Ohio

Postby MrCaleb on Sat Nov 04, 2006 1:50 pm

Worked Perfect. Thnx
Wish to see more and more of those scripted sequences.
Makes the game so much more interactive and alive
LooK ALiVe!
User avatar
MrCaleb
Member
Member
 
Joined: Thu Nov 02, 2006 9:30 pm
Location: Amsterdam

Postby Kodox on Sun Nov 05, 2006 2:36 am

Unfortunately school and laziness has consumed my motivation to get back to working on my maps.I also have a question: I restored my pc to june about a month ago. What are the files types that i need for my map (example: .bsp .ain ) and what does each do?
User avatar
Kodox
May Contain Skills
May Contain Skills
 
Joined: Fri Jul 21, 2006 7:54 pm
Location: Ohio
Next

Return to Tutorials

Who is online

Users browsing this forum: No registered users