Jump to content
El_Exodus

CS:GO SDK - Reflective Textures/Brushes

Recommended Posts

I'm trying to create a clean, black floor which should act like a mirror. I'd like to see brushes, lights and props mirrored in it.

I searched on the interwebzz how to do that and i tried a few things. But nothing worked as supposed.

 

-I tried using a selfmade texture with some water refraction lines in it i found somewhere.

-After that i used the cubemaps to add reflections to the surface using:

    "$envmap" "env_cubemap"
    "$envmaptint" "[.6 .6 .6]"
    "$envmapcontrast" ".5"

I then had reflections, but they were unaccurate as hell. So this won't work for me.

 

-Then i found this function "func_reflective_glass" but i think this one wasn't made for CS:GO since the needed textures are missing.

So it doesn't work with CS:GO. And if it does, i have no idea which settings i have to use. And because the textures don't exist here, i'm not able to create them on my own, too.

 

So here i am. I have absolutely no idea, how i'm able to create such accurate reflections. Is it even possible to create them using the CS:GO SDK? And if yes, how?

 

BTW: Where the heck shall i post these small questions in the future? The 3D Forum seems not to be the right place for them..

Share this post


Link to post
Share on other sites

I don't know if reflections is in the video options anymore. But it was None, Cubemap, World i believe. Making it not show at all on low end machines.

 

But, take a look at the water shader. Maybe there's some reflective QC commands there

Edited by cashed

Share this post


Link to post
Share on other sites

Just like crashz said, try add a static water texture brush and 1 unit clip brush above it, however, note that CS:GO water does not reflect props, only the world brushes.

 

Cubemaps would look ugly as they are not parallax corrected.

Share this post


Link to post
Share on other sites

Yep, i meant those reflections like in water. I'm trying to understand the .vmt of those textures, but it's not that easy for me, because i'm still a noob. I found this site on the Source-Wiki, but i still didn't manage it to make it work on non-water-textures.

https://developer.valvesoftware.com/wiki/Water_%28shader%29#Reflection.2FRefraction

 

 

@:Guma: Water is able to reflect props. It's just a matter of settings ;)

 

€: In this video, TopHATTwaffle describes how to create mirrors. Does anybody know where i can find these reflectiveglass textures?

Edited by El_Exodus

Share this post


Link to post
Share on other sites

I hunted my installed games gcf, and could not find. It looks like he plays from Gary's Mod. Did you check there?

Share this post


Link to post
Share on other sites
 

Yeah, but everthing i tried, didn't work as i wanted to. Can you teach me how to do it right?  :)

 

Alright so your problem is just because of the texture. You can find the one from HL2 here :

SteamAppscommonHalf-Life 2hl2

Open with GCFScape hl2_textures_dir.vpk

 

In the glass folder, you should be able to find the textures you need ("reflectiveglass002" & "...003"). I made one from those HL2 textures with this VMT :

"lightmappedreflective"
{ 
"$basetexture" "cs_opera/miroir" 
"$translucent" 1 
"$refracttexture" "_rt_WaterRefraction" 
"$refractamount" "-0.1" 
"$refracttint" "[1 1 1]" 
"$reflecttexture" "_rt_WaterReflection" 
"$reflectamount" "0.1" 
"$reflecttint" "[1 1 1]" 
"$fresnelpower" "1" 
"$minreflectivity" "1.0" 
"$maxreflectivity" "1.0" 
"$normalmap" "cs_opera/miroir_normal" 
"$surfaceprop" "glass" 
"$bumpframe" "0" 
}

miroir.vtf is a copy/paste from reflectiveglass003.vtf

miroir_normal.vtf is a copy/paste from reflectiveglass003_normal.vtf

 

I simply modified the default refract values and few things to get a flat render, a clean mirror. I don't really know much more about this kind of texture, you should try to change some values on this vmt to see how it works.

 

Tell me if you need any more help

(the map with the mirror i made : http://steamcommunity.com/sharedfiles/filedetails/?id=262196646 )

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...