Creating a security camera: Difference between revisions
(More formatting) |
(Added a table.) |
||
Line 8: | Line 8: | ||
==Making it fall== | ==Making it fall== | ||
[[image:Portal camera tutorial1.jpg|thumb|right|200px|Create the brush just at the base.]] | [[image:Portal camera tutorial1.jpg|thumb|right|200px|Create the brush just at the base.]] | ||
1. Create a brush using the | 1. Create a brush using the '''tools/toolstrigger''' material. This brush should just cover the base of the camera where it connects to the wall. (Making it too large will cause your camera to fall off even when the portal doesn't touch it.) | ||
2. Make this brush a {{ent|func_portal_detector}}. | 2. Make this brush a {{ent|func_portal_detector}}. | ||
3. Under Output add the following: | 3. Under Output add the following: | ||
Outputs Placed in the trigger: | |||
<table> | |||
<tr> | |||
<th>Prefix</th> | |||
<th>Location</th> | |||
</tr> | |||
<tr> | |||
<td><code>Name</code></td> | |||
<td>OnStartTouchLinkedPortal</td> | |||
</tr> | |||
<tr> | |||
<td><code>Target Entity</code></td> | |||
<td>(whatever you named the {{ent|npc_security_camera}})</td> | |||
</tr> | |||
<tr> | |||
<td><code>Target Input</code></td> | |||
<td>Ragdoll</td> | |||
</tr> | |||
<tr> | |||
<td><code>Delay</code></td> | |||
<td>0.00</td> | |||
</tr> | |||
<tr> | |||
<td><code>Fire Only Once</code></td> | |||
<td>Yes</td> | |||
</tr> | |||
</table> | |||
==That's all!== | ==That's all!== | ||
The camera will automatically follow the player around and when a portal it put behind it, fall to the ground. It also automatically leaves a mark on the wall where it was. You can also have the {{ent|func_portal_detector}} trigger an {{ent|ambient_generic}} to have GLaDOS make one of her witty remarks. | The camera will automatically follow the player around and when a portal it put behind it, fall to the ground. It also automatically leaves a mark on the wall where it was. You can also have the {{ent|func_portal_detector}} trigger an {{ent|ambient_generic}} to have GLaDOS make one of her witty remarks. |
Revision as of 08:20, 9 November 2007
As you have most likely noticed, scattered about the Aperture Science facility are cameras which follow you and are detachable from the wall by placing a portal behind them. Using this tutorial you can put them in your map.
Creating the model
1. Choose the Entity Tool (Shift + E) and in the dropdown box, select npc_security_camera. Then simply place the camera where you want it placed on the map.
2. Give it a name like "rm1_camera1" and set the World Model to models/props/security_camera.mdl.
Making it fall
1. Create a brush using the tools/toolstrigger material. This brush should just cover the base of the camera where it connects to the wall. (Making it too large will cause your camera to fall off even when the portal doesn't touch it.)
2. Make this brush a func_portal_detector.
3. Under Output add the following:
Outputs Placed in the trigger:
Prefix | Location |
---|---|
Name |
OnStartTouchLinkedPortal |
Target Entity |
(whatever you named the npc_security_camera) |
Target Input |
Ragdoll |
Delay |
0.00 |
Fire Only Once |
Yes |
That's all!
The camera will automatically follow the player around and when a portal it put behind it, fall to the ground. It also automatically leaves a mark on the wall where it was. You can also have the func_portal_detector trigger an ambient_generic to have GLaDOS make one of her witty remarks.