Some of the recent videos about getting portal gun in HL2 is actually the portal engine using the HL2 maps (requires Portal & HL2). Below is how to do it:
* First off, backup up your entire Portal directory in a safe place.
>> It’s the folder marked “portal” in ..\Steam\steamapps\(your_steam_id)\
* Next, download and install GCFScape. This will allow you to access the cached game files for any Source-powered game, in addition to several other Steam games you may have downloaded.
* Once that’s done, browse to the directory ..\Steam\steamapps\. There, you’ll see all the available GCF archives. We’ll start with Half-Life 2.
* Open the GCF marked “half-life 2 content.gcf” You’ll see a directory tree in the left pane. Click the box to the left of the folder marked “hl2″ to see the directory listing contained within it. Then, right-click “maps,” select ‘Extract’ and extract the entire folder into the directory \Steam\steamapps\(your_steam_id)\portal\portal. This will merge it with the existing Portal map folder.
* Do the same with the ’scenes’ folder
* Fire up Steam and run Portal. When it’s done, open up the developer console with ‘~’ (you may need to enable it under your keyboard options).
* At the console, type “maps” to list all the available maps. Now that you’ve imported the Half-Life 2 maps, this will be a fairly lengthy list and some of the names, like citadel and canals, should seem familiar.
* Type “map” and then the map name to open that map. For instance, map d1_canals_01
* When the map has loaded, open the console again and enable cheats by entering “sv_cheats 1
* To give yourself all weapons, including the portal gun, enter impulse 101
* Depending on how far you got in Portal, you may need to upgrade the portal gun to fire both portals. Enter “upgrade_portalgun” to do so
Technically similar setups should work for teamfortress, css and more importantly... Left 4 Dead
[EDIT: Note; This definitely works for Half life2, I've not tested it on L4D, will maybe do this tonight]