Buildcubemap confusion

Avatar
Tigger
100 Posts
Posted Mar 02, 2008
Ok, so I have reflective surfaces.

I build my map with full settings.

I go into my map and run buildcubemaps from the console. Reflections look fine.

But everytime I rebuild the map I lose the reflections.

Does this mean if I release a map I must rebuild cubemaps without saving again from Hammer if I want my reflections to look right when I release?

And is there any way to rebuild cubemaps from outside HL2/Portal? Something I could set up in a batch file?

Thanks.

Advertisement
Registered users don't see ads! Register now!
Avatar
taco
504 Posts
Posted Mar 02, 2008
Replied 20 minutes later

Tigger wrote:
Does this mean if I release a map I must rebuild cubemaps without saving again from Hammer if I want my reflections to look right when I release?

Yes; each time your compile, you lose previously built cubemaps.

Tigger wrote:
And is there any way to rebuild cubemaps from outside HL2/Portal? Something I could set up in a batch file?

No; cubemaps must be built in-game.

Avatar
Hurricaaane
189 Posts
Posted Mar 02, 2008
Replied 4 hours later
Everytime you compile, you loose the cubemaps.
Cubemaps are like included in the BSP. Watch its size, it grows up when building cubemaps.

If you change a map directory wich have been already compiled cubemaps, the cubemaps won't work on this direcotry (BUT the cubemaps wont be lost!). That means if the cubemaps are built again, the BSP will grow even more.

Also, if you play in windowed mode, and you compile, play the map, buildcubemaps, and compile again without closing the game, when you start the map, the cubemaps will still be active BUT IT'S AN ILLUSION, because your cubemaps have already been cached in the game. You still have to rebuild the cubemaps.

I think that's all I can say about cubemaps.

Avatar
rellikpd
1,053 Posts
Posted Mar 02, 2008
Replied 2 hours later

Hurricaaane wrote:

firstly thanks for the info Hurricaaane, i've always wondered about cubemaps and that pretty much sums it up.

2ndly... cubemaps are retarded (sounding) i mean. if its a function of the bsp or anything. hammer should do it. thats llame, it should (in theory) be able to build/compile/release a map. without EVER running hl2.exe shrug
stupid cubemaps.

Avatar
NykO18
183 Posts
Posted Mar 02, 2008
Replied 1 hour later

rellikpd wrote:
hammer should do it.

It does, but it gives a very poor result.
(because Hammer uses the sky as a reference for every cubemap. not really useful in Portal)

Avatar
Aldéz
221 Posts
Posted Mar 02, 2008
Replied 1 hour later
In order to build cubemaps that give reflections of how the map looks in-game, the map has to be rendered as it would be in-game. That means that a compiled map must be loaded in a renderer of some kind, so why not in the game?
Avatar
Tigger
100 Posts
Posted Mar 02, 2008
Replied 2 hours later
Yes, thanks for the answers. This is very useful information.

Hurricaaane wrote:
If you change a map directory wich have been already compiled cubemaps, the cubemaps won't work on this direcotry (BUT the cubemaps wont be lost!). That means if the cubemaps are built again, the BSP will grow even more.

So does that mean I can rename a map and it won't grow the file with additional cubemaps? It's only moving the file into a new directory that does that?

Avatar
NykO18
183 Posts
Posted Mar 02, 2008
Replied 1 hour later
Renaming and moving files is exactly the same thing
Avatar
Tigger
100 Posts
Posted Mar 02, 2008
Replied 15 minutes later

NykO18 wrote:
Renaming and moving files is exactly the same thing

So if I rename my file I get cubemap bloat? Is there a way to purge cubemap info from a map?

Advertisement
Registered users don't see ads! Register now!
Avatar
NykO18
183 Posts
Posted Mar 02, 2008
Replied 14 minutes later
Yes, you can open your BSP file with Pakrat and delete every cubemap in it.
But I can't garantee the result because cubemaps must have a reflection. You could end up with black and purple checkerboard reflections.