Portal 2/Creating a mod: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
m (Test)
Line 29: Line 29:


=== Step 4 ===
=== Step 4 ===
Use a program like {{gcfscape|4}} to open {{User:THE OWL/Sandbox|Path|Steam/steamapps/common/portal 2/portal2_dlc2/pak01_dir.vpk}} and copy the file called {{Code|resource/ui/basemodui/mainmenu_new.res}} to {{User:THE OWL/Sandbox|Path|(your mod)/resource/ui/basemodui}}. Edit it, then pack it into a new VPK using {{User:THE OWL/Sandbox|Path|portal 2/bin/vpk.exe}} or {{gcfscape|4}}.
Use a program like {{gcfscape|4}} to open {{User:THE OWL/Sandbox|Path|Steam/steamapps/common/portal 2/portal2_dlc2/pak01_dir.vpk}} and copy the file called {{User:THE OWL/Sandbox|Path|resource/ui/basemodui/mainmenu_new.res}} to {{User:THE OWL/Sandbox|Path|(your mod)/resource/ui/basemodui}}. Edit it, then pack it into a new VPK using {{User:THE OWL/Sandbox|Path|portal 2/bin/vpk.exe}} or {{gcfscape|4}}.


=== Step 5 ===
=== Step 5 ===
Restart Steam. If it all worked, your mod should be listed. Congratulations!
Restart Steam. If it all worked, your mod should be listed. Congratulations!

Revision as of 07:35, 30 April 2023

The old tutorial was obsoleted by DLC2. This is the new method, as described by Lpfreaky90 and Felix Griffin.

Step 1

Create a folder for your mod in

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

and rename it to the name of your mod. Open that folder and create two subfolders: "cfg" and "maps".

Step 2

Open the "maps" folder and create a folder called "soundcache" inside it. Copy the file called "_master.cache" from

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

to this new soundcache folder.

Step 3

Create a gameinfo.txt file in your mod's root directory. Use this template:

"GameInfo"
{
    game            "Your Mod's Name"
    GameData        "portal2.fgd"
    FileSystem
    {
        SteamAppId  620 // Portal 2 has ID 620
        SearchPaths
        {
            Game    |gameinfo_path|.
            Game    portal2_dlc2
            Game    portal2_dlc1
            Game    portal2
        }
    }
}

Step 4

Use a program like GCFScape GCFScape to open

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

and copy the file called 

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

to 

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. . Edit it, then pack it into a new VPK using

Sandbox Navigation

Templates Pages

Redesign Preview

Main Page Software docs
Note.pngNote:Documenting VDC Redesign Flaws.

Colors

Article Background (38 38 38) (#262626)
Island (41 41 41)
Link (100 140 200)
Code (150 165 145)

Typography

Typeface

sans-serif (general)

Aa
Regular (400)
Aa
Bold (700)
Aa
Black (900)

monospace (for code)

Aa
Regular (400)

Inline Code (T)

$basetexture

Keyboard Key (T)

Ctrl

Iconography

Navigation

It’s empty here for now.

Buttons

It’s empty here for now.


Selectors & Elements

Checkbox

It’s empty here for now.

Toggle button

It’s empty here for now.

Tabs (T)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

or GCFScape GCFScape.

Step 5

Restart Steam. If it all worked, your mod should be listed. Congratulations!