Saturday, June 14, 2008

Lesson 7 - Team wall, Flags

Lesson 7
team wall, flags

If this is your first visit to this sight you should start at the beginning.

Just about ready to wrap this up. There will be one more lesson after this. You are doing a great job.

First thing we should do is set up the map for gameplay. Open the entity report. Click on map, select entity report. The entity report shows you everything that you put into your map. It allows you to find things more quickly than trying to fly around and look for them. Now when we flipped our map we copied everything in the map. So now we are going to use the entity report to clean up those extra items that were copied, and that we did not need.



For instance, there should only be one light_environment per map. So select one of them in the entity report. And click delete. Then click OK. (see p18) Also delete all your spawn points, and close the entity report. We deleted them so, we can reinsert them without fear of mixing up the spawns. Also we need to put 16 spawn points for each team. That adds up to 32 players total. That will allow your map to be played on most servers. If you only have five spawn points in your map then only five players can join your game. Pick which spawn you want to be allies and pick which spawn you want to be axis. And add the spawn points.



See the example (see p19), I created my spawn with eight spawn points on the outside, and eight spawn points on the inside. Something you need to remember about placing spawn points on top of displacements. If you just placed them in their and leave them some of your spawn points will not work because displacements are not solid. Some of the spawn points get stuck in the ground. And if they are stuck in the ground hammer will ignore them. So once you placed your spawn points. You should use the entity report, to select all your spawn points and move them up a little bit to ensure that they are not stuck in the ground.



Here's what you do:
Open the entity report.
Select the first info_player_axis. (see p20)
Holddown the shift key and select the last info_player_axis, this will select all spawn points in between the two points. (see p21)
with all the spawn points selected go to your side view viewport and move all the spawns up off of the ground at the same time.



As you can see they are all off the ground and none of them are touching the displacements. (see p22).

Do the same for both sides, both spawns.



Now we need to add spawn protection. Turn the "IG" button off. We will use another "tool" texture. Select the "texture tool", click browse, type tools, select the "trigger texture". Go into the large house, where we created the spare room. Let's block this doorway so that the enemy team cannot enter this spawn. Draw a brush using the trigger texture and completely block the doorway. (see p23).

Here's another one of those really important shortcuts. Ctrl-t. Learn this one. This will be the most important shortcut in your Hammer mapmaking career. Ctrl-t is used to turn brushes into Brush Entities. So we're going to turn this brush into a team wall. So make sure the brush is selected. And hit Ctrl-t.



Select "func_team_wall" from the pulldown menu. (see p24)



Select "team to block" in the "key values" field. Then on the pulldown menu select the team you wish to block. In this case I am working at the Axis spawn so I am going to block the Allied team. Click apply, click cancel
(see p25)




Also place team wall at the fence exit. (see p26) I made this wall extra tall, to prevent people from boosting over the fence.

Add team walls to both sides.

Flags.
Adding Flags.
Select the entity tool.



From the pulldown menu select dod_control_point_master. In placed anywhere in your map. For your flags to work right, you need to have a dod_control_point_master in your map. Just one. And it can be placed anywhere. (see p27)



Then from the pulldown menu select dod_control_point. And place it were you want your flag to appear in your map. (see p28)

To create the capture area, we use a trigger brush. Use the texture tool, click browse, type tools, select the trigger texture. Draw a cube around the flag. This will be the capture area. As soon as someone enters this area they will begin to cap the flag. Make it as big or as small as you want.



After you get it the size you want, Hit Ctrl-t and select dod_capture_area, from the pulldown menu. (see p29) click apply, then cancel.



Double-click on the flag. Bring up the properties dialog box. Click on name in the "key values", and give your flag a name. I named my flag, flag1. Click apply. (see p30)



Select "Localized name to print on the" in the "key values". This is where you put the name that will pop up in the game when someone caps the flag I called mine Axis First. (See p31)



Select "sound made when axis capture" click browse, type voice in the filter. Select "Voice.German_FlagCapture". Click OK, click apply (see p32)

Select "sound made when allies capture" click browse, type voice in the filter. Select "Voice.US_FlagCapture". Click OK, click apply (same as above except for allies.)



Select "index of this point (unique)" and place a 1 in the text field. (See p33) this point number has to be different on each flag. That's why it says unique, duh. And this determines the order that the flags will appear on the HUD (hud stands for heads up display). Since this is our first flag, we are going to put a number 1. On the second flag will put a number 2. On the third flag will put a number 3. See how that works. So those twelve years of high school wasn't wasted after all.



That sets up the flag portion. Now we have to set up the capture area. Double-click on your capture area to bring up the properties dialog box. Click on "name of the control point area". Tie the name of the flag that we want to connect this control area to. In this case it is flag1, because that was the name of my flag.(see p34)


You don't have to change any of the other settings. But you can to make the game play a little different.
The other selections are pretty much self-explanatory. But if you cannot understand them, then don't mess with them. That flag is complete.

Don't forget to save your work often.

You might even want to save a backup copy of the file you're working on, just in case something goes wrong you only have to go back as far as the copy, and not all the way back to the beginning.

OK, that was one flag. Most maps have 5 flags. This is a small map. So it only needs three flags to keep it interesting.

Once you have one flag in the map, there is no need to go through all of that again. Why not just copy and paste. In fact I copy and paste all my flags, for all my maps. I only made one set for my first map. And then I copy and paste from then on. This is only the second time I made a flag from scratch. Just to show you guys how to do it. Like I said, once you have one, all you have to do is copy and paste the rest.



Let's copy this flag and capture area and make another flag. Because this map only has three flags, the next flag is going to be our middle flag. So let's put it in the middle. Make sure the ignore groups button is not on. Select the flag and the capture area. Click ctrl-c to copy. Go to the middle of the map. He Ctrl-v to paste. (see p36)

After copying the flag you need to change a few settings to make this flag unique.
------------------------------------------
Double-click on the flag,
changed the name of the flag to: "flag2"
changed the "localized name to print" to: Middle Flag
change the index of point to: 2
and that is it for the flag.

Double-click on the capture_area
change the "name of the control point this area" to flag2
now this flag and capture area are complete.
-------
Copy the flag one more time put it near the Allied spawn.
-------
Double-click on the flag,
changed the name of the flag to: "flag3"
changed the "localized name to print" to: Allied First
change the index of point to: 3
and that is it for the flag.

Double-click on the capture_area
change the "name of the control point this area" to flag3
now this flag and capture area are complete.
-------------------------------------------
When you're copying flags, never have the IG button on. It should always be in the up position, which is off.
Or it will ignore all the flag settings when you paste it.

Well this map is almost complete. Go ahead and Compile It and check it out. And we will be sure and finish this map up, in our next lesson.

GOTO Lesson 8

1 comment:

Anonymous said...

how i make aa gun fireable?