The Stanley Parable mod creation
		
		
		
		Jump to navigation
		Jump to search
		

 
Base Information
If you want to start creating mods for The Stanley Parable, there are a few things you need to know:
- Not all Portal 2 entities are available in The Stanley Parable.
- Not all restrictions from Portal 2 apply to The Stanley Parable.
- The Stanley Parable has the "SMG2" weapon from The Beginner's Guide. If you want to add weapons to your mod, then make it based on SMG2.
 Note:You can check this weapon if you copy the models, textures, sounds and scripts of this weapon from The Beginner's Guide and paste them into The Stanley Parable, and write "give weapon_smg2" in the console.
Note:You can check this weapon if you copy the models, textures, sounds and scripts of this weapon from The Beginner's Guide and paste them into The Stanley Parable, and write "give weapon_smg2" in the console.[Todo]
Requirements
You need to install The Stanley Parable, Portal 2 and Portal 2 Authoring Tools.
Ways to create a mod
We have three ways to create a mod:
- We just want to create just one map without adding new content (textures, sounds, scripts and models) to the game folder.
- We want to create a sourcemod that will be added to the Steam library and will include all the features of the mod from the sourcemod folder.
- We want to create a mod, to install which all its content will need to be put into the folder with the original game.
Creating just a map for The Stanley Parable
- Go to the Portal 2 root and go to bin folder (default location is C:\Program Files (x86)\Steam\steamapps\common\Portal 2\bin) and copybase.fgd,portal.fgdandhalflife2.fgdfrom there to the folder wherestanley.fgdis located, that is, to The Stanley Parable root.
- Go to The Stanley Parable\thestanleyparable\mapsand createmapsrcfolder (Optional: you can also create aPrefabsfolder inmapsrcfor prefabs).
Setting up Hammer editor
- Open Portal 2 Authoring Tools and open Hammer Editor
- Go to tools->options and edit the Portal 2 configuration: change Game Directory from $SteamUserDir\Portal 2\portal2to$SteamUserDir\Portal 2\portal2_dlc2so that if Hammer World Editor finds a configuration with the originalportal2folder, then it will automatically select it.
- Create a new configuration and name it after your mod.
- Add stanley.fgdto the Game Data files field.
- Optional: Select Default PointEntity class as info_player_startand Default SolidEntity class asfunc_detail, set Cordon texture totools\toolsskybox, set Prefab Directory to$SteamUserDir\The Stanley Parable\thestanleyparable\maps\mapsrc\Prefabs.
- Set Game Executable Directory to $SteamUserDir\The Stanley Parable, Game Directory to$SteamUserDir\The Stanley Parable\thestanleyparableand Hammer VMF directory to$SteamUserDir\The Stanley Parable\thestanleyparable\maps\mapsrc.
- Go to the Build Programs
- Set Game Executable to $SteamUserDir\The Stanley Parable\stanley.exe, BSP executable to$SteamUserDir\Portal 2\bin\vbsp.exe, VIS executable to$SteamUserDir\Portal 2\bin\vvis.exe, RAD executable to$SteamUserDir\Portal 2\bin\vrad.exeand Place compiled maps to$SteamUserDir\The Stanley Parable\thestanleyparable\maps.
Creating a sourcemod for The Stanley Parable
- Go to the Portal 2 root and go to bin folder (default location is C:\Program Files (x86)\Steam\steamapps\common\Portal 2\bin) and copybase.fgd,portal.fgdandhalflife2.fgdfrom there to the folder wherestanley.fgdis located, that is, to The Stanley Parable root.
- Create a folder in the sourcemods (default location is C:\Program Files (x86)\Steam\steamapps\sourcemods) folder and name it after your mod.
- In your newly created folder, create a gameinfo.txt file and put this in it (read more here: gameinfo.txt):
"GameInfo"
{
	game 		"TSP Mod"
	GameData	"stanley.fgd"
	FileSystem
	{
		SteamAppId				221910
		ToolsAppId				211
		SearchPaths
		{
			Game				|gameinfo_path|.
			Game				|All_Source_Engine_Paths|thestanleyparable
		}
	}
}- In the same place create a folder called maps, and in it create amapsrcfolder (Optional: you can create aPrefabsfolder for prefabs in themapsrcfolder).
- Go to the The Stanley Parable root. In order for Hammer Editor for Portal 2 to work correctly, you need to create a folder, named the same as your mod in The Stanley Parable root and place gameinfo.txtthere with the following content:
"GameInfo"
{
	game 		"TSP Mod"
	title 	 	"TSP Mod"
	GameData	"stanley.fgd"
	FileSystem
	{
		SteamAppId				221910
		ToolsAppId				211
		
		SearchPaths
		{
			Game				|gameinfo_path|.
			Game				"YOUR\REAL\WAY\TO\SOURCEMODS\sourcemods\TSP Mod"
			Game				"YOUR\REAL\WAY\TO\THE STANLEY PARABLE\The Stanley Parable\thestanleyparable"
		}
	}
}
}Setting up Hammer editor
- Open Portal 2 Authoring Tools and open Hammer Editor
- Go to tools->options and edit the Portal 2 configuration: change Game Directory from $SteamUserDir\Portal 2\portal2to$SteamUserDir\Portal 2\portal2_dlc2so that if Hammer World Editor finds a configuration with the originalportal2folder, then it will automatically select it.
- Create a new configuration and name it after your mod.
- Add stanley.fgdto the Game Data files field.
- Optional: Select Default PointEntity class as info_player_startand Default SolidEntity class asfunc_detail, set Cordon texture totools\toolsskybox, set Prefab Directory toSteamDir\steamapps\sourcemods\TSP Mod\maps\mapsrc\Prefabs.
- Set Game Executable Directory to $SteamUserDir\The Stanley Parable, Game Directory to$SteamUserDir\The Stanley Parable\TSP Modand Hammer VMF directory to$SteamDir\steamapps\sourcemods\TSP Mod\maps\mapsrc.
- Go to the Build Programs
- Set Game Executable to $SteamUserDir\The Stanley Parable\stanley.exe, BSP executable to$SteamUserDir\Portal 2\bin\vbsp.exe, VIS executable to$SteamUserDir\Portal 2\bin\vvis.exe, RAD executable to$SteamUserDir\Portal 2\bin\vrad.exeand Place compiled maps to$SteamDir\steamapps\sourcemods\TSP Mod\maps.
Creating a mod that all content files will be in original game folder
You just need to complete all the steps that were shown in the "Creating just a map for The Stanley Parable" chapter, only all the new content will need to be put into the folders with the original game.
External links
See also
[Todo]

























