Snarkpit Articles


So you want to create a battle between yourself and a particular type of enemy? Oh and you say you want the battle to never end? Maybe your after some kind of endurance map? Well, if it's something like that then you've come to the right place!

It's very simple to do this once you know how, and it only took me ten minutes to figure out! Just follow the steps and you'll be on your way to never-ending battle heaven!

  1. Start by creating a large room, with enough space for yourself and the enemy to fire at eachother from a distance and such like. Create an info_player_start entity at one end of the room, and place an item_suit and a weapon_SMG1 entity somewhere where the player will be able to get them as soon as you run the map.



  2. Now create a bunch of obstacles for yourself and the enemy to navigate around and hide behind etc.. Use the brush tool to create some medium-sized walls and such like around the battlefield. By doing this, you're giving yourself and the enemy a more strategic interest in the battle, and will make things more fun!



  3. Before we make it possible to spawn enemies, we also need to place some info_node entities around the room, to give your future adversaries a way to move around to different strategic positions in the middle of the firefight. Place the nodes around key locations in the room. Make the level with the floor. The best place to have them is one on either side of your obstacles, so the enemy knows where they can hide and take cover to reload etc.



  4. Now that the battlefield is ready for its battle, we need to create the spawn point for the enemy. Place an npc_maker entity at the opposite end of the room to your info_player_start entity, so that when you run the map, you won't start beside your enemy! Place it at the same height as the info_node entities, so the enemies don't spawn from too high off the ground and die from the fall. Also, make sure that the angle of the entity points toward the info_player_start entity, or the enemy might be facing the wall when you run the map.



  5. Select the npc_maker entity and open the Properties. Change only the following settings to what is shown below (the settings are self explanatory in the editor):

    Name - npc_maker_1
    Start Disabled - No
    Frequency - 5
    Max Live NPCs - 5
    Class Name of Spawned NPC - npc_combine_s
    Children's Name - combine_1
    Children's Squad Name - combine_squad_1
    Weapons - SMG1

    (Feel free to change the settings to however you want the npc_maker tp act. These settings are simply guidelines for the specific battlescene I am trying to help you create!)

  6. Once you have done this, open the Flags tab in the properties window, and check the following.

    Fade Corpse
    Infinite Children
    Do Not Drop

    Right, the settings have been configured for an unlimited stream of Combine Soldiers to come and whoop your ass! But there's still only one problem...

  7. If you run the map now, you might notice that if you crouch and hide, the enemy won't even come looking for you. That's because there's only one guy standing there, he's blocking the way for the other spawners, and he's not going to move from his little spot just to come and get you on his own. So what you need to do, is copy the npc_maker entity, and paste it, so that you have two npc_maker entities, as apose to just one. Now, place the second entity in the same position as the first, just at a different wall (preferably at the same end of the room as the first npc_maker). Once you have done this, go into the Properties for the second npc_maker, and change the Name to npc_maker_2. If you want even more of a challenge, repeat this process for a third npc_maker entity, if you really must.



    Now that you have two (or three) spawn points for the enemy, if one of them notices you, he won't be afraid to come and get you, because he will have the backup of his other Combine buddy. Also, when he moves from his spot, another soldier will spawn there, and when that one moves, another one will spawn in his place, and so on. This should give you a never ending cycle of Combine slaughtering, (unless you run out of health and die!).



So there you have it! Sorry if it was a bit complicated, (though I tried my best to make everything clear), and I hope this tutorial has served you will in the art of HL2 map-making! Download the 'npc_maker - example map' if you want to get a more in-depth idea of how to use the entity. Read on for some additional ideas that might inspire you.



Why not...

  • Check out the other settings in the npc_maker properties, you might have already noticed that you can select from a number of different NPCs to spawn from it, the amount of NPCs that can be alive from it at one time, and how long it takes before it spawns another NPC.

  • By changing the settings in the npc_maker properties, try creating a never-ending battle between Combine Soldiers and Rebel Forces.

  • Or, try creating a large room, placing an info_player_start entity in the middle, and putting npc_maker entities in all four corners of the room, with the Zombie NPC spawning from each of them. Zombie Attack!!!


  • Post ReplyView Topic
    Discussion
    [author]
    Posted by greensinge on Sat Oct 28th 2006 at 1:55pm

    Maybe you're choosing the wrong combine model? :/
    0 starsPosted by Sandalman3000 on Sat Jun 10th 2006 at 8:05pm

    I did everything you said but combine are in ragdoll mode when they start and don't move this has happend with many other npc tutorials but otherwise awesome joib :P
    0 starsPosted by HazardGameR^ on Thu Dec 1st 2005 at 5:42pm

    Ryath you have to either run it from hammer or put it in the map folder for the mod you're playing.
    Can you spawn NPC's in multiplayer? (I know It's going to cause lagg if you do, so please don't mention that!)
    [author]
    Posted by greensinge on Thu Dec 1st 2005 at 4:36pm

    Maybe you need to copy the map file into the steam half life 2 folder for maps, nistead of just having it in the hammer editor folder?
    0 starsPosted by Ryath on Sun Sep 11th 2005 at 5:33pm

    Very nice tutorial.. i actually understands what it sais :P

    only wen i run the map steam can't open it due to this error


    CModelLoader::Map_IsValid: No such map 'enemy'
    map load failed: enemy not found or invalid
    material "vgui/steam/games/icon_cs" not found

    what can i do about it ?

    (dno if this is the place for this question :$)
    0 starsPosted by Dark Tree on Thu Apr 21st 2005 at 6:15am

    Very nice and simple tutorial. A bit overlong as there is no real need to include how to make a room and how to insert a player. the entity part was nice and easy to understand.
    0 starsPosted by coge balas on Mon Mar 14th 2005 at 4:41am

    Good writing, nice pictures. You made it very easy to understand.
    0 starsPosted by half-dude on Fri Mar 11th 2005 at 10:02pm

    Couldent you also do this type of thing with the monster_maker entity in the origenal HL?
    0 starsPosted by Guessmyname on Thu Feb 24th 2005 at 10:02pm

    Using npc_template_maker and templated npcs, you could make swarms of white combine etc and different civillians instead of the same one/type every time.
    0 starsPosted by Static88 on Wed Feb 23rd 2005 at 8:48pm

    Nice one! I may experiment with this since my latest map is pretty much finished. Good for blowing off some steam. smiley
    Post ReplyView Topic