Page 1 of 1

Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 4:02 pm
by oOCaptainCrazyOo
I've been trying for hours to get this to work but it just wont have any... My specular is in the alpha of my base texture...

So this is my .VMT

"VertexLitGeneric"
{

$model "1"
$basetexture "textures/bricks"
$envmap "env_cubemap"
$bumpmap "textures/brickspecular"
$envmapmask "textures/brickspeculars"
$basealphaenvmapmask "1"
}

Here's what i get in-game after building the cubemaps and restarting the game. As you can see there's no shiny parts at all.
https://www.dropbox.com/s/5nuwwmx2rfqn8 ... xample.jpg

What am i doing wrong? I mean it's only a simple box so it's not so frustrating yet but am i missing something from my VMT?

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 4:22 pm
by Stormy
Well you have an envmapmask AND the declaration for putting your envmapmask in your diffuse. That is an issue for sure. Also I haven't made anything for CS:GO but I have only ever used the $model declaration very rarely. I find with source it's easiest to simplify everything as much as possible. Try this:

Code: Select all
Vertexlitgeneric
{
$basetexture textures/bricks
$bumpmap textures/brickspecular

$envmap env_cubemap
$basealphaenvmapmask 1
}


Also putting the mask in the diffuse alpha might cause source to read it inverted. The usual way to do it is to put the mask in the alpha of the normal map and use $normalmapalphaenvmapmask 1 instead. I haven't ever had troubles with this way. Use the diffuse alpha for either selfillum or transparency. And stop using all those damn quote marks, you're wasting precious bits.

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 4:25 pm
by oOCaptainCrazyOo
Thanks I'll try it, i was always instructed to use the quotations but i'll stop using them xD

**EDIT**

Thanks that worked but now it's really shiny, i suppose it's because my alpha channel has a lot of white in it though xD

https://www.dropbox.com/s/zzbrxs8kdulnels/ALPHA.jpg

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 5:10 pm
by Stormy
yeah wow, invert that, sharpen it and up the contrast

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 5:46 pm
by oOCaptainCrazyOo
Black_Stormy wrote:yeah wow, invert that, sharpen it and up the contrast


What do you mean by "invert" exactly? Sorry if it's a stupid question but invert could mean like invert the colours or the image xD

Do you mean like "Image>Adjustments>Invert?" I'm assuming so :D

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 6:16 pm
by Stormy
invert the colours. The grout should be darker than the brick faces because it's less shiny. Unless it's in your basemapalpha, because then it is inverted anyway.

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 8:23 pm
by nub
Unless you're making a rainy map and want that stone wall to look wet, then I don't see why you'd want to use specular in the first place. That's a dry, rough material and the only way it would look shiny is when it's wet.

Re: Envmap(s) not working in CS:GO?

PostPosted: Sat Nov 30, 2013 8:29 pm
by oOCaptainCrazyOo
@Nub, I was just using any random texture to work out how to make envmaps, I have no intention of using it on bricks lol.

Anyhoo slightly newer problem, no matter how dark i make the alpha channel it remains this shiny. Maybe i should put the env_cube in a darker place...

Just so i can try to see how it looks with Phong, what would i replace in here? It's also handy for future reference material so i don't need to ask again, i still wish to use the normal map alpha as the specular of course.

VertexLitGeneric
{

$model 1
$basetexture textures/safe_body
$envmap env_cubemap
$bumpmap textures/safe_body_n
$normalmapalphaenvmapmask 1

}

https://www.dropbox.com/s/pxt1144d81c7nz9/shiny.jpg

Re: Envmap(s) not working in CS:GO?

PostPosted: Sun Dec 01, 2013 3:32 am
by Gary
Um.. are you using VertexLitGeneric on a brush surface? Cause that shader is for models. LightmappedGeneric is for brushes.

And unless something changed in CSGO. Phong only works with models/Vertexlitgeneric

Re: Envmap(s) not working in CS:GO?

PostPosted: Sun Dec 01, 2013 10:03 am
by oOCaptainCrazyOo
I'm using it on a model of a safe I've made but thanks for the info, i do intend to possibly make some slightly reflective textures for brushes in the near future :)

Actually I'm finding that a RGB of 1,1,1 (as the base) seems to be just about right but I'll use 2,2,2 to be on the safe side.

The only problem with this is that, when painting even with values of 12,12,12, i can't even see what I'm painting... I suppose that, as a temporary measure, i make the base value lighter, paint of top of it THEN turn the base back down again that could work.