Super happy NPC spawning guide

Status
Not open for further replies.
wut about giving combine soldiers nades and guns

you know the combines that are already set on the map have nades, is there any way to give your combine NPCs nades as well?
 
I also wonder how you remove dead things. I tried ent_remove, but it doesnt help, so i guess its not an entity. :x
 
Sweet info. Going to play around with this for a while.
 
vegeta897 said:
That is impossible. What you saw was a vortigaunt standing in the skybox. (Located in some remote aread of the map)
sorry for the noob question, but what exactly is skybox?
 
How about the creatures that hang from the ceilings with the long tongues?

would be fun to watch a load of citizens running away from zombies into them :D
 
DeSetuede said:
How about the creatures that hang from the ceilings with the long tongues?

would be fun to watch a load of citizens running away from zombies into them :D

You can spawn them but they're horribly buggy, they float a bit above the ground and the tongues go sideways
 
nX1 said:
you know the combines that are already set on the map have nades, is there any way to give your combine NPCs nades as well?

Yea how do you spawn a combine/ally with an explotion grenade???
 
umm... you guys DO realize that you don't have to enter "npc_create_equipment weapon_X" before every entity? Just enter "npc_create_equipment weapon_X", and after that, every humanoid entity you create will have whichever weapon you specified.
 
You can't, the AI doesn't do anything with the gravity gun. I can't seem to get cl_ragdoll_collide to work or g_ragdoll_maxcount. Hmm... Has anyone been able to reset the limit for the number of ragdolls?
 
Any ideas to spawn those friendly positionable turrets yet ?
I wanna place a bunch of them up on the pier where you first get your sand buggy /vehicle /car /wheeled transportation device (or whatever it's called) and then run around in the sand watching the turrets pick off the antlions...
 
These two should be combined

iluyshin said:
Heres a little config i knocked up for peeps.

Of course you don't need all of it, Just take the binds if you like.

The Creation Config v 0.1 by iluyshin.

Readme:

Vehicles: Helicopters and Gunships will hover about in a cicrle then find a fixed spot to stay, this is due to no way points on the
map for them to follow. Striders will attack anything hostile that gets close to it, If attacked by an antliongaurd the strider
will take off.

Snipers: Sniper model do not move/react/have a weapon model, They can only be killed by grenades, rockets , Secondary fire from ar2.

Turrets: Turrets are always hostile, To get them to stand up, place them on a flat surface have the Rocket launcher in hand or
grav gun when placing them (dunno why but seems to work better with these weapons) Be close to the ground. Moving them: Pick up
from directly behind with grav gun or use button, Then crouch and place.

Barnacles: Rarely work, They normally end up getting stuck on the floor.

Weapons: Stunsticks only work with metrocops. I didn't bother putting in weapons which do not work. RPG's will work with combine
troops but there is no firing and reloading animation.

FAQS:

Q: Why no main NPC's like alyx.
A: Coz i don't like them.

Q: These keys are funny why did you put them like this?
A: I have used this setup for every FPS for the last 10 years, I won't change now.

Q: How do you spawn a medic class with resistance citizens?
A: That will come when it works fully.

Q: Where are the elite combine troops?
A: On holiday.

// Combine NPC

Overwatch //

bind "a" "npc_create npc_metropolice"
bind "s" "npc_create npc_combine_s"
bind "d" "npc_create npc_manhack"
bind "f" "npc_create npc_cscanner"
bind "g" "npc_create npc_rollermine"

Turrets //

bind "h" "npc_create npc_turret_floor"

Vehicles //

bind "j" "npc_create npc_helicopter"
bind "k" "npc_create npc_combinegunship"
bind "l" "npc_create npc_combinedropship"
bind ";" "give npc_strider"

Other //

bind "'" "npc_create npc_sniper"

// Xen

Zombies //

bind "\" "npc_create npc_zombie_torso"
bind "z" "npc_create npc_zombie"
bind "x" "npc_create npc_fastzombie"
bind "c" "npc_create npc_poisonzombie"

Head crabs //

bind "v" "npc_create_aimed npc_headcrab"
bind "b" "npc_create npc_headcrab_fast"
bind "n" "npc_create npc_headcrab_poison"
bind "m" "npc_create npc_headcrab_black"

Other //

bind "," "npc_create npc_barnacle"

// Antlion

bind "p" "npc_create npc_antlion"
bind "o" "npc_create npc_antlionguard"

// Resistance

citizens //

bind "1" "npc_citizen_auto_player_squad 1"
bind "2" "npc_create npc_citizen"

// Weapons

bind "q" "npc_create_equipment weapon_pistol"
bind "w" "npc_create_equipment weapon_357"
bind "e" "npc_create_equipment weapon_shotgun"
bind "r" "npc_create_equipment weapon_smg1"
bind "t" "npc_create_equipment weapon_ar2"
bind "y" "npc_create_equipment weapon_crossbow"
bind "u" "npc_create_equipment weapon_rpg"
bind "i" "npc_create_equipment weapon_stunstick"

// Health and Amour

bind "[" "item_healthkit"
bind "]" "item_battery"

// Ai Settings

bind "=" "ai_disable 0"

// Remove ENT

bind "-" "ent_remove"

// Cheats

bind "8" "god"
bind "7" "impulse 101"
bind "6" "notarget"
bind "5" "noclip"
sv_cheats "1"

// Keys

bind "ENTER" "+reload"
bind "ESCAPE" "cancelselect"
bind "`" "toggleconsole"
bind "UPARROW" "+jump"
bind "DOWNARROW" "+back"
bind "LEFTARROW" "+moveleft"
bind "RIGHTARROW" "+moveright"
bind "CTRL" "+duck"
bind "SHIFT" "+walk"
bind "F5" "jpeg"
bind "F6" "save quick"
bind "F9" "load quick"
bind "DEL" "phys_swap"
bind "PGDN" "impulse 50"
bind "END" "+use"
bind "KP_HOME" "+zoom"
bind "KP_LEFTARROW" "slot1"
bind "KP_END" "impulse 100"
bind "KP_DOWNARROW" "slot6"
bind "KP_INS" "+speed"
bind "MWHEELDOWN" "slot3"
bind "MWHEELUP" "slot2"
bind "MOUSE1" "+attack"
bind "MOUSE2" "+forward"
bind "MOUSE3" "+attack2"
bind "PAUSE" "pause"

// CL + other net cmd settings. - These are for online play.

cl_team "default"
cl_class "default"
cl_observercrosshair "1"
cl_upspeed "320"
cl_forwardspeed "400"
cl_backspeed "400"
cl_idealpitchscale "0.8"
cl_allowdownload "1"
cl_forcepreload "0"
cl_soundfile "sound/player/jingle.wav"
cl_logofile "materials/decals/spraylogo.vtf"
cl_timeout "30"
cl_cmdbackup "2"
cl_updaterate "20"
cl_cmdrate "30"

Net //

net_graph "0"
net_scale "5"
net_graphpos "1"
net_graphsolid "1"

name "enter"

// Mouse

Mouse Sens //

sensitivity "3"

m_side "0.8"
m_yaw "0.022"
m_forward "1"
m_customaccel "0"
m_customaccel_scale "0.04"
m_customaccel_max "0"
m_customaccel_exponent "1"
m_mouseaccel1 "0"
m_mouseaccel2 "0"
m_mousespeed "1"
m_pitch "0.022"
m_filter "1"

// Cam

cam_command "0"
cam_snapto "0"
cam_idealyaw "90"
cam_idealpitch "0"
cam_idealdist "64"

// C_ + CC_

c_maxpitch "90"
c_minpitch "0"
c_maxyaw "135"
c_minyaw "-135"
c_maxdistance "200"
c_mindistance "30"
c_orthowidth "100"
c_orthoheight "100"

CC //

cc_linger_time "1.0"
cc_predisplay_time "0.25"
cc_subtitles "0"
cc_lang ""

// Others


g_antlion_maxgibs "16"
hud_quickinfo "0"
muzzleflash_light "1"
spec_scoreboard "0"

closecaption "0"

crosshair "1"




// Joystick cmds

joy_name "joystick"
joy_forwardthreshold "0.15"
joy_sidethreshold "0.15"
joy_pitchthreshold "0.15"
joy_yawthreshold "0.15"
joy_forwardsensitivity "-1"
joy_sidesensitivity "-1"
joy_pitchsensitivity "1"
joy_yawsensitivity "-1"
joy_wingmanwarrier_centerhack "0"
joy_wingmanwarrier_turnhack "0"
joy_diagonalpov "0"

// Skill

skill "3"


lookspring "0"
lookstrafe "0"
joystick "0"
hud_fastswitch "1"
g_test_new_antlion_jump "1"
scene_showfaceto "0"
ai_report_task_timings_on_limit "0"
ai_think_limit_label "0"
npc_height_adjust "1"
scene_showlook "0"
scene_showmoveto "0"
func_break_max_pieces "15"
suitvolume "0.25"
sv_noclipaccelerate "5"
sv_noclipspeed "3"
sv_specaccelerate "5"
sv_specspeed "3"
sv_specnoclip "1"
sv_skyname "sky_day02_06"
sv_backspeed "0.6"
voice_forcemicrecord "1"
voice_enable "1"
voice_scale "1"
snd_duckerthreshold "0.15"
snd_duckerreleasetime "2.5"
snd_duckerattacktime "0.5"
snd_ducktovolume "0.55"
adsp_debug "0"
dsp_dist_max "1440.0"
dsp_dist_min "0.0"
snd_mixahead "0.1"
snd_musicvolume "1.0"
volume "1.0"
snd_pitchquality "1"
sv_forcepreload "0"
sv_voiceenable "1"
dsp_enhance_stereo "1"
dsp_volume "1.0"
dsp_slow_cpu "0"
cl_allowupload "1"
mp_decals "200"
r_drawmodelstatsoverlaymax "1.5"
r_drawmodelstatsoverlaymin "0.1"
r_eyesize "0"
r_eyeshift_z "0"
r_eyeshift_y "0"
r_eyeshift_x "0"
r_eyemove "1"
r_eyegloss "1"
r_aspectratio "0"
con_enable "1"
sv_unlockedchapters "14"
password ""
bgmvolume "1"
vprof_unaccounted_limit "0.3"
vprof_verbose "1"
vprof_graphheight "256"
vprof_graphwidth "512"
texture_budget_background_alpha "128"
texture_budget_panel_bottom_of_history_fraction ".25"
texture_budget_panel_height "284"
texture_budget_panel_width "512"
texture_budget_panel_y "450"
texture_budget_panel_x "0"
budget_panel_height "384"
budget_panel_width "512"
budget_panel_y "50"
budget_panel_x "0"
budget_background_alpha "128"
budget_bargraph_range_ms "16.6666666667"
budget_panel_bottom_of_history_fraction ".25"
budget_history_range_ms "66.666666667"
budget_history_numsamplesvisible "100"
budget_show_history "1"
budget_show_averages "0"
budget_show_peaks "1"
budget_averages_window "30"
budget_peaks_window "30"
budget_bargraph_background_alpha "128"

http://www.halflife2.net/forums/showthread.php?t=57742&highlight=bind
 
Hey all, I think ive made a small break through. The ent_fire command, as previously discussed in this thread, has a multitude of properties. To see the lists (they are NPC specific), spawn an npc. For example, "npc_create npc_metropolice" (spawning a metro cop where your reticle is). Then, name him using "ent_setname" command. In my case, I named my metro cop Bob. So I used the command (ATTENTION: the crossairs must be over the npc your naming) ent_setname Bob. Now, most everyone is aware at this point that you can ignite your npc, or Bob, by using the command "ent_fire Bob ignite" or "ent_fire [your npc's name] ignite". But, to see a list of all available commands, move your crossairs over your npc and type, in the console, "ent_fire bob " with a space at the end, which should bring up all the available commands. They are specific to the npc, as metioned earlier. For instance, the metro cop has commands such as "Activatebaton" and the like.

For an example of one universal command (so I think, I didnt test it much) the attachment shows the "ent_fire Bob color [x]" command. I tried messing around with this, and it seems you can set the command by using "Blue" and other colors. But it may also be possible to use it with the RGB scale, in terms of red blue and yellow mixtures such as in paint.

Anyway, I hope this helps everyone and they have fun. Something I also found, when I spawned an antlion guard, one of its "ent_fire" commands was "ragdoll", which causes it to die on the spot and, well, ragdoll.

If anyone has any comments or questions, be sure to speak up.

Thanks to MagicalMonkey for making this possible :thumbs:
 

Attachments

  • d2_coast_070001.jpg
    d2_coast_070001.jpg
    94.2 KB · Views: 650
There are 2 threads that add a flare to gameplay
Slow down time
Set things on fire

I dont want to seek them out, could someone compile the binds onto the list please? They are very very fun
 
AFAIK the combine APC is a map object, with the wheels physically attatched. I don't think it's actually a spawnable entity.
 
My observations from messing around in Nova Prospekt:

Alyx can use Annabelle (Grigori's Winchester rifle) and the Crowbar, both with correct anims.

She CAN'T use the Gravity Gun or the Magnum, for some reason :/

Stalkers: Not completely removed. As previously stated, they DO crash the game after dying. Also, their laser appears to fire from their feet.
Valve did a rather crappy job of removing the monster completely from the game, it appears. Oh well. Once the SDK is out, i'm sure someone can fix it up and make it an interesting addition to their mod. Although, you could just say the Combine gave the Stalker's legs some kind of fowled up Jock Itch, or somehting.


I'd like to try some tests with Civvies and Bugbait/Grenades, or some experiments with the Flares.
 
Heh, you can't complain that Valve didn't remove something properly. If you mess around with things outside the scope of the game, it's entirely at your own risk.
 
Pi Mu Rho said:
Heh, you can't complain that Valve didn't remove something properly. If you mess around with things outside the scope of the game, it's entirely at your own risk.

I wasn't complaning.
 
Hey all, I found another cool command. Much like the "host_timescale [x]" command, you can enter "phys_timescale [x]" (x being 1, normal, 2 twice as fast, .5 half as fast, and any other number) and it only pertains to physics objects. So chairs and grenades and everything will go in slow motion, but you wont. Its pretty fun.
 
now i have few ?s, first how do you set floor turrets so they fire at enemys, the toggle | enable | disable, they dont do that.

second how do you get the white gravity gun, whats the command for that, and how about thouse white elite combine later in the game how do you get thouse?

I've been trying to figure out all of these but so far no luck, does anyone know about any of these that would be great. Great forum!
 
Heres the guide i created the 22nd.
I delete this post when you post what you need in you post at the top :D

---------
Appendix:


1. About this FAQ
2. Creating NPCS
2A. Creating Weapons for NPC's
3. Weapons List
4. NPCS
4A. Character NPC'S (Non attacking)
4B. Enemy NPC'S (Attacking)
5. NPC's that cant be created
6. Pictures of created NPC's
7. Thanks



=================================================
1. About this FAQ
=================================================


Seeing as how there is no guide out and most people cant find any list or info on creating NPCS or how this all works I did some research and make a list and found out some thingss This FAQ shows you what to do to create a NPC and what NPC are creatable!




=================================================
2. Creating NPCS
=================================================

All console commands will be in quotation marks "".

First off when you start Half Life 2 go into your console before you do anything and type "sv_cheats 1".

Then load a game save or load a custom map. To load a map go to your console ~ key) and type "MAP" and the map name "MAP xxxxx". Once your in a map go to your console again type "notarget" and hit enter. NOTARGET makes the enemies NOT attack you when they spawn. After this type "noclip" in the console. Thismakes you fly.

There's another command called "ai_disable" which turns off the AI so you can create good NPC's and bad NPC's and they wont attack each other. But lets stick to the basics! Now wherever you create a NPC at it will be wherever your cursor is pointed.

Lets say you wanted to spawn a Zombie. Point to the ground where you want him and go to your console and type "npc_create npc_zombie" then hit enter. You'll see the Zombie appear!

For a Combine it would be go to your console and type
"npc_create npc_combine_s" and he'll appear.

Basically your just changing the last line after the NPC_CREATE NPC_ to whatever you want to spawn. Its really easy.

Even though youll need to read the rest of this guide make sure when your done with creating your NPC's and you want to face them you go to your console and you turn off the commands from earlier again by typing "notarget" and "noclip" so you can walk around and so they can see you. But of course turn them on somewhere safe so you can have fun!


---------
2A. Creating Weapons for NPC's
---------


Now when you create a Combine or most any unit that NPC that can fight they don't have anything. So you have to give them something before you createthem. This is REAL easy too.

Before you create a NPC think about what weapon you want to give it. Say you want to create a Citizen and you want him to have a Shotgun. Go to your console and type "npc_create_equipment weapon_shotgun" and hit enter. This command lets the game know you want to give the NPC's a shotgun when its made. This will be the default weapon for every NPC you create until you change the weapon to something else.

Next you'd type in "npc_create npc_citizen". A citizen will now appear with a shotgun.

Just make sure to type in the command with a different weapon if you want something else for a different NPC or youll have the same gun.

Like creating NPC's not all weapons work for them. Some don't spawn and some will but then the NPC cant move. So read my weapons list below!



=================================================
3. Weapons List
=================================================

These are weapons you can create for the NPC's. Its really all about testing. I'm only showing the most stable ones. And some of the ones that do work but have side effects. Anything else not listed may crash your pc and/or not work at all.

The command is always "npc_create_equipment weapon_" You just add the weapon you want after the "_".

pistol (Side effect on some units are they wont move)
shotgun
smg1


Heres the other items but I suggest you test these at your own risk:
cubemap
cguard
physgun
ml
hmg1
immolator
irifle
sniperrifle
crowbar
extinguisher
frag
rollerwand
slam
brickbat
gauss
binoculars
alyxgun
hopwire
Molotov
physcannon
ar2
bugbait
ar1
rpg
smg2
stickylauncher
stunstick
thumper
iceaxe

=================================================
4. NPCS
=================================================

This is a list of characters you can spawn. Its split up into two lists.The first list is characters that are people you talk to and interact with and the second list are ones you fight.

Once again the command to create an NPC is "npc_create npc_". You just add the
name after the "_".


--------
4A. Character NPC'S (Non attacking you)
--------


gman (Doesn't actually do anything. Sits still)
barney (lives really long and sometimes follows you)
alyx (lives about as long as you and sometimes follows you)
citizen (lives not to long and does whatever you say)
monk (fun listening to him talk in battle lol)
dog (useless but cool looking)
kleiner (sits still)
eli (sits still)
Mossman (sits still)
Breen (sits still)
Vortigaunt (REALLY COOL! You can talk to him and he fights!)


--------
4B. Enemy NPC'S (Attacking)
--------


sniper
crow (useless)
headcrab
headcrabfast
helicopter (doesn't seem to work often)
zombie
strider (tends to get stuck under ground)
combine_s
headcrab_black
metropolice
manhack
poisinzombie
turret_floor (Thanks to my friend for this one)
fastzombie
gunship
rollermine
headcrab_poison
barnacle (starts on floor)
antlion
antlionguard
zombie_torso
combinedropship (seems to fly off)




=================================================
5. NPC's that cant be created
=================================================

This is a lost of the NPC's that cant be created. This is either because the game crashes or mostly because there just isn't a command.

Combine Elite
Combine APC
Scanner
Lamar

There are also other NPC's that's seem to have names in the game but don't apeear to have models or even work like Assassin and Bullsquid.



=================================================
6. Pictures of created NPC's
=================================================

Just for fun here is some pictures of some created NPCs!

http://img122.exs.cx/img122/2876/dfhsmc.jpg

http://img113.exs.cx/img113/4466/zdkrjmkr.jpg




=================================================
7. Thanks
=================================================

Id like to thank Valve for making a AWSOME game that was better then the hype! Even though it had a rough release I cant complain this is the best game I've played since Half Life!

PLEASE no emails about hosting this FAQ on others sites unless you're a HL2 site.
 
If host_timescale is set low, you can still move fast. I think the commands are cl_forwardspeed and sv_normalspeed (it's something like that, type find speed, they'll be there somewhere), if you raise those you'll be able to move normally while absolutely everything else moves in slowmo. The movement is sort of like skating on ice, I think, but it's fast.
 
Creating npc's seems to work in HL2: DM also. Some of the ent_fire commands also work. You can also kill friendly npc's. I tried using the ent_fire setexpressionoverride on gman but no effect. I didn't get an error, but he spoke nothing. We had tons of fun with gravity 0 and sv_cheats 0 and npc spawning with my friends...
 
Hey, I tried this but when I spawned npcs I couldn't see them but I could hear and see their bullets etc.

Any idea?
 
Is there a way to get them working on the HL² dm maps, or does it only work in HL² singleplayer? When I spawn NPC in dm, they just stand there motionless.
 
Something interesting to notice :

in the console type "developer 1" to enable developer mode.

now pointing at an ent and typing in the console (or simply bind it to a key) "ent_name" and you will see a name tag on the model.
now you can use ent_dump <name that's on the tag> to see the info of it in the console.
 
I've been mucking around with this all day. But one thing that is annoying, the Resistance soldiers seem to ALWAYS win against the combine, unless the combine has far superior numbers. I'll give you an example, I spawned 3 Resistance SMG soldiers, 2 with shotguns, and 2 with the AR. I then spawned the same for Combine and the Resistance killed the combine with one casualty. Tried it again, only this time the Resistance didn't lose anyone. I thought this was wierd so I spawned 10 Combine and 5 Resistance elsewhere, so 10 vs 5. The Combine won, but had 4 casualties. It's wierd. The Resistance do have better fights though, like when you spawn a bunch of zombies nearby, they shout "Zombies! Everyone fire!" or when Antlions are near this guy shouted "Get down! Antlions!"
 
Assassin X said:
Heres the guide i created the 22nd.
I delete this post when you post what you need in you post at the top :D
Good job at using the weapons from the leak.
 
Hey, i spawned some citizens with smgs on coast and spawned some combine with smgs as well. Combine and citizens just stood there doing nothing. Only thing they attacked were the ant lions.

Any ideas as to what is going on?
 
Space Cowboy said:
Hey, i spawned some citizens with smgs on coast and spawned some combine with smgs as well. Combine and citizens just stood there doing nothing. Only thing they attacked were the ant lions.

Any ideas as to what is going on?

If you don't spawn them near each other they may not attack. Just chuck a grenade at them and they will react. They must know eachother exist before they start fighting.
 
Status
Not open for further replies.
Back
Top