PDA

View Full Version : help with impulse code


Cheese-Grater
14th December 2004, 22:51
i expect there is an impulse code or other spawn code for the turret that u can pick up and move about, but i was wondering if there was an impulse code for a friendly turret?


-----
C-G

Vorm
15th December 2004, 11:49
i expect there is an impulse code or other spawn code for the turret that u can pick up and move about, but i was wondering if there was an impulse code for a friendly turret?


-----
C-G
Not sure but this may be of assistance.

Here's some info on how to spawn different NPCs and how to have fun with them. I'm pretty much certain it's incomplete so contribute anything I've missed and I'll edit it into this post with credit.

The Basics

To spawn an npc (with a few exceptions), look at the area of ground where you want it to spawn, then open up the console (~ key for most, below esc for all) and type "npc_create [npc name]". You can also spawn them aimed away from you using npc_create_aimed, but I haven't been able to make this command work without having an npc of the same type spawned normally first.

To give your npcs weapons, you have to use the npc_create_equipment command. If you wanted to spawn alyx with a shotgun for instance, you'd type "npc_create_equipment weapon_shotgun; wait; npc_create npc_alyx".

To bind a spawning command to a key, type "bind "[key]" "[command]"".

Now you can create some huge zombies vs antlions vs combine vs alyx clones battles. When positioning troops for battle, type "ai_disable" to stop them fighting until you're done positioning. Type it again to turn ai back on.


Fun

NPCs all have inputs which you can activate using the ent_fire command. Some inputs are common to all NPCs, some are unique to one or two NPCs. To list all the inputs (and outputs, although I don't know if they're much use) of an NPC, type "ent_info [npc name]". As far as I can see, all the inputs listed above setrelationships are specific to certain NPCs.

If you want to actually input something to an NPC, you have to name it first. To do this, type "ent_setname [name]". Once you've named an npc, you can then type "ent_fire [name] " and do cool stuff like set them on fire.

To set things on fire, type "ent_setname [name]; wait; ent_fire [name] ignite". I found that code posted by somebody on another forum and it made me want to find out other similar things I could do, and find out I did.

A couple of other useful global inputs are kill and sethealth. There's also a skin input which I'm guessing changes the model or textures but I have no idea how to use it, so if anybody can help with that it'd be much appreciated.

NPC List

Where inputs are blank I've found nothing useful, but I might have missed something (or I might have omitted something you would have found useful).

Combine

Footsoldiers

Combine Soldier: npc_combine_s

Metrocop: npc_metropolice ____ Inputs: enablemanhacktoss - I haven't been able to get this to work. Maybe you'll have better luck.

Sniper: npc_sniper

Vehicles
[i]All of these remain stationary
For these use give rather than npc_create. They will spawn above you, rather than underground/inside the ground.

Strider: npc_strider ____ Inputs: setcannontarget - kills things - usage "ent_fire [name of strider] setcannontarget [name of target]" | setminiguntarget - useless, aims at feet of target ____ Notes: Targets must be named using ent_setname. On some levels you have to noclip upwards a little to spawn a strider because it will sink into the ground otherwise. If a strider impales an antlion guard it will fly away.

Dropship: npc_combinedropship ____ Notes: Lots of inputs, the ones I tried didn't work. Test out more if you can be bothered.

Gunship: npc_combinegunship ____ Inputs: dogroundattack - shoots a laser at the ground directly beneath it. Will continue to do so as long as enemies of the combine are beneath it.

Helicopter: npc_helicopter ____ Inputs: dropbomb ____ Notes: Lots of inputs, lots crashed the game. Test out more if you can be bothered.

Misc
Scanners and manhacks are spawned on the near side of the wall pointed at

Scanner: npc_cscanner ____ Inputs: equipmine | deploymine | disablespotlight | inspecttargetspotlight - usage "ent_fire [name of scanner] inspecttargetspotlight [name of target] | inspecttargetphoto | <set/clear>followtarget | setflightspeed ____ Notes: Targets must be named using ent_setname.

Manhack: npc_manhack

Rollermine: npc_rollermine ____ Inputs: respondtoexplodechirp - makes it explode

Stalker: npc_stalker ____ Notes: Does nothing but waddle around a bit. Shot me with a laser once in the three times I spawned one. Crashes game when killed. Not recommended.


Wildlife

Antlions

Antlion: npc_antlion ____ Inputs: <hear/ignore>bugbait - buggy. will alternately attack you and love you. | burrow | unburrow

Antlion Guard: npc_antlionguard ____ Inputs: setchargetarget - usage "ent_fire [antlion guard name] setchargetarget [target name]" | clearchargetarget | setshovetarget | ragdoll - makes it die ____ Notes: Targets must be named using ent_setname.

Zombies and Headcrabs

Zombie: npc_zombie

Fast Zombie: npc_fastzombie

Poison Zombie: npc_poisonzombie

Headcrab: npc_headcrab ____ Inputs: burrowimmediate | unburrow

Fast Headcrab: npc_headcrab_fast

Poison Headcrab: npc_headcrab_poison


Allies

Vortigaunt: npc_vortigaunt

Citizen: npc_citizen ____ Inputs: giveweapon - usage "ent_fire [name of citizen] [weapon {eg weapon_shotgun}]" | setmedic<on/off> | setammoresupplier<on/off> | setreadiness<low/medium/high>


Characters
setexpressionoverride is an input which allows you to make a character enact any scene. The usage is "ent_fire [character name] setexpressionoverride [file path of scene]". For example, to make alyx perform the gman's closing speech, you would name alyx alyx and type "ent_fire alyx setexpressionoverride scenes\citadel\gman_out".

Alyx: npc_alyx ____ Inputs: setreadiness<low/medium/high> | outsidetransition - places her in front of you | setexpressionoverride

Barney: npc_barney ____ Inputs: setreadiness<low/medium/high> | outsidetransition - places him in front of you | setexpressionoverride

Breen: npc_breen ____ Inputs: ____ setexpressionoverride

Dog: npc_dog ____ Inputs: setexpressionoverride ____ Notes: There are lots of inputs to do with playing catch that I couldn't get to work properly. Dog's AI without
scripting is "run away".

Eli: npc_eli ____ Inputs: setexpressionoverride ____

Gman: npc_gman ____ Inputs: setexpressionoverride

Kleiner: npc_kleiner ____ Inputs: setexpressionoverride

Father Grigori: npc_monk ____ Inputs: setexpressionoverride | perfectaccuracy<on/off>

Mossman: npc_mossman ____ Inputs: setexpressionoverride


Those are all the npcs I currently know of. To find the name of an npc while playing you can type "ent_show_response_criteria" and it'll come up with their name (along with some other stuff if developer is set to verbose).

There are more things to input to than NPCs. Type "ent_fire " and a list of non-NPC entities with inputs will appear under the console. I think these differ from level to level, and they let you do things like stopping the antlions spawning at the beginning of Highway 17.

I have no idea how to spawn explosive barrels etc or whether it's even possible, but hopefully someone will find a way.

I think that's about it. Hope it's of some use.

Vorm
15th December 2004, 11:55
Spawn friendly turret: npc_create npc_turret_floor_friend

SK
15th December 2004, 12:44
Nice one Vormeh

Meercat
15th December 2004, 12:45
I like spwaning stirders

Cheese-Grater
15th December 2004, 13:14
thanks a lot, i never knew u could spawn ppl with diff weapons like that. cool!

pat_rules
15th December 2004, 16:44
sweet dude

Miz
15th December 2004, 19:08
Vorm is a 'Senior Member'. Heh. :D