Portal 2

Portal 2

72 ratings
Changing the singleplayer portal colors in Portal 2
By RGB Productions
This guide is for those of you who want to change the singleplayer portal colors in Portal 2, but have no idea how to. I didn't know how to at first, but with enough luck I found it out without a tutorial.
   
Award
Favorite
Favorited
Unfavorite
Before we start...
NOTICE: I'm not updating this tutorial anymore. Some of the information may be out of date!

Hello! In this guide I will show you how to change the singleplayer portal colors in Portal 2. This is mainly for those of you who want to change the portal colors, but have no clue how to do it.

These are the things you'll need in order to change the colors:
  • GCFScape
  • VTFEdit
  • Image editor (I prefer GIMP, it's free and has the tools you need to change the colors)

Once you have everything, you can continue on with this guide!
Getting the files
To get the vtf files, go to C:\Program Files (x86)\Steam\steamapps\common\Portal 2\portal2 and scroll down until you find a file named pak01_dir.vpk. Open that file in GCFScape.

Once open, you want to right click the materials folder and click Extract. Create a folder on your computer and call it pak01_dir. This is important so that you can pack it back into a vpk after editing. Extract the materials folder into the folder you just made.

Wait until it's done extracting. The models/portals is the only folder you'll need. Now you have all the files you need to start editing!
Getting the images
Go into the models/portals folder in your extracted materials folder. Open the portal-blue-color.vtf file in VTFEdit. Once open, press ctrl+e or go to File > Export. Save it to a folder outside of the pak01_dir folder as portal-blue-color.png. Do the same for portal-orange-color, portal-blue-color-dx8, portal-orange-color-dx8, dummy-blue, and dummy-orange.
Editing the images
After getting the 2 portal color images, open both in your image editor. I will tell you the steps for GIMP. You need to get a black first. Press the arrows at the color selection area to switch the foreground and background colors. Choose a color that you want to be your portal color. Press L for the gradient tool, and go to the far right (>) side of the image. Click and, while holding the left mouse button, drag to the left. Once you get to the end, hold ctrl and move your mouse a little. Release your left mouse button. Export the image (Ctrl+Shift+E) to a PNG. Do the same for the other.

Now for the next step. Go into VTFEdit and import the portal-blue-color or portal-orange-color images. Import them with the alpha format being BGR888 and the normal format being DXT1. Make sure to not generate mipmaps. In the Flags area, click on the box next to the Clamp S, Clamp T, and SRGB flags. Press ctrl+s and save it into pak01_dir/materials/models/portals as portal-color-blue.vtf or portal-color-orange.vtf. Do the same for the other.

Now, the dx8s and the dummies. Export all 4 of the files. After that's done, open them in the image editor. I'm only doing the steps for GIMP. Go to Colors > Colorize and set the saturation to the lowest. Don't touch the hue and the lightness. Repeat, don't touch the hue and the lightness. Now click the image and set the hue and saturation to the hue and saturation of your portal's color. Don't touch the lightness. Again, don't touch the lightness. Now save it to the png. Do the same for the other 3. Same as the portal color gradient files, import the dx8s to VTFEdit with alpha format BGRA8888 and normal format DXT1. Again, don't check generate mipmaps. Save them. For the dummies, the alpha format is BGRA8888 and the normal format is DXT1. This time, check generate mipmaps and enable the flags Clamp S and Clamp T. Save them.
Making the vpk
Now for the fun part. You want to go to C:\Program Files (x86)\Steam\steamapps\common\Portal 2\bin and scroll down to vpk.exe. Make sure you have the directory of your pak01_dir folder shown as well! Drag and drop the pak01_dir folder onto vpk.exe. Once finished, put the pak01_dir.vpk file that shows up into the bin folder. Now go into Portal 2 and go into a singleplayer map and it should work!
Disclaimer
I don't know how to change the color of the ring that comes off the portal when it's placed. From what I know, it's unchangable. You just need to stick with the blue/orange ring. Sorry! :(
Awesome colors
Feel free to tell me what colors you chose for the blue portal and the orange portal in the comments! I will tell you what I chose. For my blue portal, I chose a dark red color. For my orange portal, I chose a sea greenish blueish kind of color. If you are interested in it, then I'll tell you the hue/saturation/value and red/green/blue of my portals.

Blue (Red) Portal:
H: 0, S: 95, V: 67
R: 171, G: 8, B: 8

Orange (Sea Greenish Blueish) Portal:
H: 154, S: 84, V: 72
R: 29, G: 183, B: 115
51 Comments
agonzo320 24 Jul @ 5:54pm 
Future guide:
cl_portal_alternate_colors 1
cl_portal_sp_primary_color "r g b"
cl_portal_sp_seconday_color "r g b"
(joke, but this does work in portal revolution)
Pixxeell___ 2 Mar @ 12:42am 
Anyone having issues with vpk.exe spitting out only two lines, set compatibility mode to "Windows 7", for whatever reason, it worked (despite me using windows 10)
Experience Cookie 29 Jan @ 4:40am 
To those that are having issues where the textures (such as the portal-blue-color). You need to change the normal format to BGR888 and keep alpha format as DXT5. (Switch it for the others and you should be fine)
riblolox 8 Jan @ 2:46pm 
When i go to open "dummy-blue.vtf" and "dummy-orange.vtf" it gives me an error, "Error loading VTF texture:

Error:
File version 7.5 does not match 7.0 to 7.4."
How do i fix this?
Malo 6 Dec, 2023 @ 6:58pm 
Hey, when I import the portal-blue-color.png and portal-orange-color.png into VTFEdit with DXT1 as the normal format and BGR888 as the alpha format, the texture is all weird and has random spots of colour. How do I fix this?
Andromeda 18 Nov, 2023 @ 10:27pm 
I'm also having issues with the last step.
Dropping the pak01_dir folder onto vpk.exe just opens a command prompt with:
CDynamicFunction: Loading library 'Kernel32.dll' (76870000)
CDynamicFunction: Lookup of 'TryEnterCriticalSection' in 'Kernel32.dll': 77380A30

And does nothing else
Everything else worked fine up until this point.
Jasali_Entropiya 16 Oct, 2023 @ 4:08pm 
was doing fine up until the last step which required you to drop the folder onto the vpk.exe file, which didn't do anything but open a command prompt that says
CDynamicFunction: Loading library 'Kernel32.dll' (768A0000)
CDynamicFunction: Lookup of 'TryEnterCriticalSection' in 'Kernel32.dll': 77653D80
RGB Productions  [author] 29 Jun, 2023 @ 9:31am 
@GemCreepy I don't know how to temporarily disable them, but one way to reset them is:
- Right click the game in the library tab
- Click on "Properties"
- Click on "Local Files"
- Click "Verify Integrity of Game Files"
That should reset all the files (including the portal colors) back to the original versions.
GemCreepy 26 Jun, 2023 @ 4:07pm 
Do you know how to reset the portal colours, or like temporarily turn them off? If you do know, it would be great if you could help me out. Thanks
cristian2737 7 Jan, 2023 @ 9:19pm 
I tried dropping a vpk.exe file into the bin folder and doing it. Didn't work. Great tutorial, though! everything else has worked fine, but that's the roadblock right now. I appreciate all the work you did and I'm impressed you figured all of that out on your own! Thank you!