VGUI HTML Screen In Orange Box

From Valve Developer Community
Jump to: navigation, search

This tutorial is an add-on to the VGUI HTML Screen and VGUI HTML Screen In Multiplayer articles, providing details on implementing the VGUI HTML Screens in the Orange Box.

Please read either of the above articles in full, as this article simply provides replacements for a few areas.


Several files need to be added to existing projects.

If you have completed either of the above articles, you will probably be replacing these files.

Everything_SDK - Building the HTML entity

1. Add the following files to the vgui_controls project:

Note: If you have followed either of the original articles, this file merely needs to be moved.

2. Right click the vgui_controls project, and select Build.

Warning: Do not select Build Solution, as not all the projects build, and this would leave your mod in an uncompilable state.

Game Project

Open the Game_HL-200x project, and add the following files to the project:

Client (HL2 or HL2MP) Project


Server (HL2 or HL2MP) Project


Finishing Up

One of the game files needs to be modified.

  • In the Client (HL2 or HL2MP) project, find and open the vgui_int.cpp file.
  • Near the top of the file, locate the line: #include "FileSystem.h"
  • Add a line below this: #include "IHTMLView.h"
  • Go to line 159
  • Add the following lines:
 VPANEL gameParent = enginevgui->GetPanel( PANEL_INGAMESCREENS );
  • Go down to the next function, and find the line: VGUI_DestroyClientDLLRootPanel();
  • Add the following line:
  • Build your solution, and if everything goes fine, you should be able to use the HTML VGUI Screens in the Orange Box.
  • Post any issues on the Discussion page, or email me.