Creating a security camera: Difference between revisions
m (Added size to portal trigger block) |
No edit summary |
||
Line 46: | Line 46: | ||
== See also == | == See also == | ||
* [[Portal Level Creation]] | * [[Portal Level Creation]] | ||
== External links == | |||
* [http://forums.thinkingwithportals.com/downloads.php?view=detail&df_id=179 Example map] Example map using this tutorial. VMF included. | |||
[[Category:Level Design Tutorials]] | [[Category:Level Design Tutorials]] | ||
[[Category:Portal]] | [[Category:Portal]] |
Revision as of 00:25, 29 August 2010
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
- 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.
- Give it a name like "rm1_camera1" and set the World Model to models/props/security_camera.mdl.
Making it fall
Using portals
The following is only necessary if you have placed the camera on a wall where portals can be created.
- Create a 30H x 33W x 5L 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.)
- Make this brush a func_portal_detector.
- Under Output add the following:
Outputs Placed in the trigger:
My Output | Target Entity | Target Input | Parameter | Delay | Only Once | |
---|---|---|---|---|---|---|
![]() |
OnStartTouchLinkedPortal | (name you gave npc_security_camera) | Ragdoll | <none> | 0.00 | Yes |
By standing on it
There is also another method that allows you to make the camera fall if someone tries to stand on top of it. Sometimes, when you design a Portal level, you may not want the player to be able to use the cameras as a derived way to solve the room. To achieve that, you can create a little trigger_once on top of the camera and add the following output to it :
My Output | Target Entity | Target Input | Parameter | Delay | Only Once | |
---|---|---|---|---|---|---|
![]() |
OnTrigger | (name you gave npc_security_camera) | Ragdoll | <none> | 0.00 | No/Yes |
This way, when a player will try to stand on top of the camera, it will detach itself from the wall. You can add sounds and sparks effects if you'd like to give it a more realistic feel. You can even combine this method with the one mentioned above if you wish to.
Conclusion
The camera will automatically follow the player around and when a portal is put behind it, fall to the ground. It also automatically leaves a mark on the wall where it was. You can also have it trigger a scene by GlaDOS if you follow this tutorial.
See also
External links
- Example map Example map using this tutorial. VMF included.