VERC: Creating A Retinal Scanner Last edited 19 years ago2003-03-11 23:09:00 UTC

You are viewing an older revision of this wiki page. The current revision may be more detailed and up-to-date. Click here to see the current revision of this page.

This article was recovered from an archive and needs to be reviewed

  1. The formatting may be incorrect as it was automatically converted to WikiCode from HTML, it needs to be revised and reformatted
  2. Some information may be out of date as it was written before Half-Life was available on Steam
  3. After the article is re-formatted and updated for Steam HL, remove this notice
  4. Please do not remove the archive notice from the bottom of the article.
  5. Some archive articles are no longer useful, or they duplicate information from other tutorials and entity guides. In this case, delete the page after merging any relevant information into other pages. Contact an admin to delete a page.


One of the interesting effects from Half-Life that people want to use is that of barney opening a door by using a retinal scanner. The effect is broken down into a number of smaller parts -


The Door and Scanner

First things first, lets setup the basic components. Make the door. It can be simple or complex. Whatever. That's up to you. Give it a Name ( targetname ) - the example map uses door1 . Also, set its Delay before close ( wait ) to -1 so it stays open.

For the scanner, insert one of the prefab retinal scanners which are located in the Usable Objects prefab library (included with the editor). The bottom of the scanner should be 28 units above the ground so that its at the right height to interact with barney's scripted_sequence (Link: index.php?ent=scripted_sequence) animation. Once you've got it in your map, select it and press Alt+Enter to bring up its entity properties (it's a func_button (Link: index.php?ent=func_button) ). Set its Name ( targetname ) to something (for this example, i've used scanner1 )

We'll also create the sounds that the scanner will appear to make. Create two ambient_generic (Link: index.php?ent=ambient_generic) entities. Place one over the scanner and one over the door. Select the one over the scanner and press Alt+Enter to bring up its properties. Give it a Name ( targetname ) of blip1 . Set the Path/filename.wav of WAV ( message ) to buttons/blip1.wav . In the flags properties, set the Medium Radius , Starts Silent , and Is NOT Looped flags. Setup the ambient_generic over the door exactly the same but name it kachunk1 and set its Path/filename.wav of WAV ( message ) to buttons/button4.wav .

While were at it, place a barney ( monster_barney (Link: index.php?ent=monster_barney) ) beside the scanner. In his flag properties, enable the Pre-Disaster flag to stop his annoying chatter. :) You should now have something similar to what is pictured below.

The Retinal Scanner Animation

Now we'll setup the the scripted_sequence that makes barney perform the animation to make him operate the retinal scanner. Place a scripted_sequence enity right up against the scanner object. Set its angle so it is facing the scanner. Give it a Name ( targetname ) - this example uses ss_retina1 . Set the Target Monster ( m_iszEntity ) to monster_barney . Set the Action Animation ( m_iszPlay ) to retina - this is the animation that will be played. Set Move to Position ( m_fMoveTo ) to Walk (1) . When the scripted_sequence is activated, Barney will walk over to its location before performing the animation.

We'll also throw in a scripted_sentence so barney says something appropriate. The location of the scripted_sentence isn't really important. Set its Name ( targetname ) to something - this example uses hevyes . Set the Sentence Name ( sentence ) to !BA_HEVYES . The ! causes the sentence to be streamed in rather than stored in memory. The BA_HEVYES calls the sentence "Go right on through sir, looks like you're in the barrel today." Set the Speaker Type ( entity ) to monster_barney . Set the Listener Type ( listener ) to player . This will make barney focus on the player as he speaks.

Your scene should now look something like this -


Ok, now we need to coordinate everything we've just created. This can be accomplished quite simply with a trigger_once (Link: index.php?ent=trigger_once) and a multi_manager (Link: index.php?ent=multi_manager) . First, place the trigger_once brush entity just before the barney (see the picture below for reference). Set the Target ( target ) of the trigger_once to opendoor1 (this will be the name of the multi_manager which we're also about to define.) The whole sequence of events will be triggered when the player walks into this trigger_multiple.

Place a multi_manager somewhere in the general vicinity, and give it a Name ( targetname ) of opendoor1 . Turn off SmartEdit mode and add the following key/value pairs -
That's all there is to it. It's not all that complicated.


For a more concrete illustration, check out the example map linked below.
This article was originally published on the Valve Editing Resource Collective (VERC).
TWHL only archives articles from defunct websites. For more information on TWHL's archiving efforts, please visit the TWHL Archiving Project page.


You must log in to post a comment. You can login or register a new account.