Source SDK

Source SDK

dr.htibor May 22, 2022 @ 1:57pm
Hammer editor problem with reinstalled Ep.2
For years I have used the Hammer editor to create Half life 2 Ep.2. maps without any problems.
Last November my PC broke down. I bought a new winchester and reinstalled Steam, Half life 2 and Ep.2. The previous Steam is still on another winchester with the same games.
When I launch the Hammer editor from the "new" Half life 2\bin, many textures and models are missing. My old maps(.vmf) are corrupt, no new map can be created.
Anyone have similar problems lately? What is the solution? How do I configure Hammer to work fine like it used to?

Note: I noticed that in the "new" Ep.2 the metrials and modells folders are almost empty!. I copied the model and materials files from the "old" Steam folder to the "new" Ep.2. Then Hammer worked properly, but the maps I created ONLY run on my PC without error. Textures and models are also missing on another PC.
Any ideas?

Translated with www.DeepL.com/Translator (free version)
< >
Showing 1-15 of 18 comments
Materials and models folders are empty because, after the Steampipe big update in 2013, all the game assets are packed into the ep2_pak_dir.vpk in ep2 folder. The editor should look for the assets in that file by default, without any change.
About custom materials, models and sound folders, I don't map for ep2, but at least in HL2dm, they must be placed into a subfolder named my_custom_stuff, inside "custom" folder, and the editor will find them.
Of course, to get your custom assets visible in another PC, and for other players, you must pack them into the bsp by VIDE and/or Pakrat.
dr.htibor May 23, 2022 @ 5:57am 
I don't use custom assets.
My ep2_pak_dir.vpk folder only 461 kb. This is normal?
Last edited by dr.htibor; May 23, 2022 @ 6:17am
Originally posted by dr.htibor:
I don't use custom assets.
My ep2_pak_dir.vpk folder only 461 kb. This is normal?
Yes, mine it's the same, but if you open it by GCFScape you'll see all assets are inside of it.
dr.htibor May 23, 2022 @ 8:09am 
[Yes, mine it's the same, but if you open it by GCFScape you'll see all assets are inside of it.]

I understand and thank you. Now I just need to know why my map is full of errors on another PC?
Last edited by dr.htibor; May 23, 2022 @ 8:11am
Originally posted by dr.htibor:
[Yes, mine it's the same, but if you open it by GCFScape you'll see all assets are inside of it.]

I understand and thank you. Now I just need to know why my map is full of errors on another PC?
That's weird, if the game is properly installed in both PC's, you should see the same, in Hammer and in game.
Did you try to verify the game files integrity?
Last edited by [B.n.B] AlcyToronto; May 23, 2022 @ 8:46am
dr.htibor May 24, 2022 @ 10:20am 
"That's weird, if the game is properly installed in both PC's, you should see the same, in Hammer and in game.
Did you try to verify the game files integrity?"

We are getting closer to a solution!
If you're interested, I'll describe how:

I wrote earlier that I copied the data from my "old" Steam folder to the "materials and models" folder of the "new" Ep.2.
I did this because even though I configured the "new" Hammer Editor correctly, my old maps were displayed incorrectly and I couldn't create a new map.

Turns out that the copied data is considered custom content!

Last night I used the VIDE program to package this data into my incomplete .bsp file. The old .bsp was about 10 MB, the new one was 60 MB!

I sent it to my son and there are only a few bugs left, which I hope we can fix.
I mean you were right, I still use custum content! :)))

I think the updates have changed the structure of the Ep.2. folders. For me, in my old Ep.2. folder installed in 2017, the "materials" and "models" folders were not empty (that's why I was able to copy them)

Another problem: my son recently downloaded Half life 2 and Ep.2 from Steam. The Hammer Editor is started by E:\Games\Steam\steamapps\common\Half-Life2\bin\hammer.exe. He has configured the editor correctly( he has worked with the editor several times before) but he still can't create a new map because for some reason Hammer can't find many textures and models.
I hope we can find a solution for this too!

Translated with www.DeepL.com/Translator (free version)
[B.n.B] AlcyToronto May 24, 2022 @ 10:40am 
Originally posted by dr.htibor:
"That's weird, if the game is properly installed in both PC's, you should see the same, in Hammer and in game.
Did you try to verify the game files integrity?"


I sent it to my son and there are only a few bugs left, which I hope we can fix.
I mean you were right, I still use custum content! :)))
If the few bugs on your son's PC are missing textures and decals, I strongly suggest you to use also Pakrat (after VIDE), because both these tools may loose something. VIDE sometimes misses the custom decals, and Pakrat can loose some model's textures.
Here, if you want, a short video showing how I pack my maps to have everything packed. It's for HL2dm, but it's the same for all games, just changing the path.

https://www.dropbox.com/s/bz45euecvlu3sm0/How%20to%20use%20VIDE.mp4?dl=0
dr.htibor May 24, 2022 @ 12:28pm 
I watched the video, your advice was very helpful!

Thank you very much!
I will report back if the maps work.
dr.htibor May 24, 2022 @ 1:40pm 
There is a new problem:

I use env_cubemap on some maps. For this I used Pakrat.
- open .bsp
- delete all "texture" files
- copy the map directory
- save
- launch Ep.2.
- console: "mat_specular 0"
"buildcubemaps"
"mat_specular 1"
"mat_reloadallmaterials"
"map mapname" enter
This has always worked fine.
However, now when I pack the .bsp with VIDE and Pakrat and then do the cubemaps, I also delete a lot of custom content. The map then shows a lot of red "ERROR".
How can I create the cubemaps if there is custom content in the .bsp file?

Translated with www.DeepL.com/Translator (free version)
Originally posted by dr.htibor:
There is a new problem:

I use env_cubemap on some maps. For this I used Pakrat.
- open .bsp
- delete all "texture" files
- copy the map directory
- save
- launch Ep.2.
- console: "mat_specular 0"
"buildcubemaps"
"mat_specular 1"
"mat_reloadallmaterials"
"map mapname" enter
This has always worked fine.
However, now when I pack the .bsp with VIDE and Pakrat and then do the cubemaps, I also delete a lot of custom content. The map then shows a lot of red "ERROR".
How can I create the cubemaps if there is custom content in the .bsp file?
No mate, you don't have to use pakrat to build the cubemaps. That was a trick useful many years ago, after the steampipe update, because there was a bug. Then it was finally fixed.
Now you have just to pack your map, run it and buildcubemaps in game. Build them for both HDR and LDR. Set hdr on and build cubemaps, restart the game, set hdr off and build again the cubemaps, to get good reflections in both the modes.
Last edited by [B.n.B] AlcyToronto; May 24, 2022 @ 2:33pm
dr.htibor May 25, 2022 @ 6:58am 
Thank you, I did not know that. Everyone on the forums suggests different solutions for cubemap. I have tried many methods and this Pakrat method worked for me.
In the meantime I read that the solution is to build the cubemap on the map first and then pack the custom content. I tried it and it works!

One more thing! I sent the "buggy" map to another friend who installed Ep.2 on his PC a long time ago and found no bug... It's a mystery. :)

Translated with www.DeepL.com/Translator (free version)
Originally posted by dr.htibor:
Thank you, I did not know that. Everyone on the forums suggests different solutions for cubemap. I have tried many methods and this Pakrat method worked for me.
In the meantime I read that the solution is to build the cubemap on the map first and then pack the custom content. I tried it and it works!

One more thing! I sent the "buggy" map to another friend who installed Ep.2 on his PC a long time ago and found no bug... It's a mystery. :)

Translated with www.DeepL.com/Translator (free version)
Probably your bugged map works with old version of the game.
Anyway it's strange that your system needs to pack the original stock assets as they were custom. Probably there's something else to fix in your installation.
By the way, did you verify the game files integrity as I suggested in a previous reply?
(Steam Library - Scroll the game list - riight click on Hallf Life 2 ep2 - properties - local files - veriify integrity).
Last edited by [B.n.B] AlcyToronto; May 25, 2022 @ 9:49am
dr.htibor May 25, 2022 @ 12:42pm 
Yes, several times, that's fine with me.
There are already some overlays and decals missing from the map, I'll have a look with Pakrat scan, hopefully it will fix it.

...
Unfortunately, no results. I started the Pakrat scan but for minutes nothing happened, nothing found, as if it had frozen. I quit.
Trying to manually insert the missing files with VIDE.
Last edited by dr.htibor; May 25, 2022 @ 1:32pm
Originally posted by dr.htibor:
Yes, several times, that's fine with me.
There are already some overlays and decals missing from the map, I'll have a look with Pakrat scan, hopefully it will fix it.

...
Unfortunately, no results. I started the Pakrat scan but for minutes nothing happened, nothing found, as if it had frozen. I quit.
Trying to manually insert the missing files with VIDE.
Did you set the riight path in pakrat? (Gamedir in Pakrat window)? Pakrat is very faster than VIDE, when I run Pakrat after VIDE, as in the video, it take few seconds.
dr.htibor May 26, 2022 @ 10:50am 
Yes, the path is:
J:/Games/Steam/steamapps/common/Half-Life 2/ep2
When I click on Scan, a small window appears with text "Textures...", a blue "stripe" inside, and then nothing happens, even though the map is still missing about 10-15 decals.
< >
Showing 1-15 of 18 comments
Per page: 1530 50

Date Posted: May 22, 2022 @ 1:57pm
Posts: 18