Quake3World.com Forums
     Level Editing & Modeling
        help with custom sky shader


Post new topicReply to topic
Login | Profile | | FAQ | Search | IRC




Print view Previous topic | Next topic 
Topic Starter Topic: help with custom sky shader

Recruit
Recruit
Joined: 10 Dec 2016
Posts: 2
PostPosted: 12-10-2016 03:53 AM           Profile Send private message  E-mail  Edit post Reply with quote


I have a problem.

I have a map in radiant. If i assign a standard QL sky shader to the sky-brush, the map is correctly illuminated (skybox will illuminate map textures)

Now, if i simply copy that shader (from QL pak00 scripts/skies.shader) to my custom mapname.shader file, and assign that shader to my skybrush, there is no illumination of the map textures. The skybox itself looks fine.

This is so weird, since it's a 1to1 copy.

It's like q3map_surfacelight 200 is simply ignored, while texture definitions, skyparms, tcMod scroll ... is all working.

So in wolfcam baseq3 i have a textures and a scripts folder for my map. I added mapname.shader to the shaderlist.txt (which is also in scripts folder). This is all set up correctly. Radiant shows all custom textures and shaders.

But no illumination when i use the direct copy of the sky shader. Illumination only for default shaders.

Any ideas? Thanks much!




Top
                 

The hell good boy
The hell good boy
Joined: 22 Jun 2011
Posts: 1922
PostPosted: 12-10-2016 04:44 AM           Profile   Send private message  E-mail  Edit post Reply with quote


Sky shaders should not use q3map_surfacelight (which is intended for light fixtures), but q3map_sky or q3map_skyExt to generate sun brightness, direction (where is East or West in your map) and elevation (is it high noon or it's sunset or sunrise?), that should correspond to used skybox (if any is used). skyExt also implements some additional parameters to smooth out cast shadows produced by sunlight and make light refraction simulation in your map. You should not copy any assets from Steam Workshop as stated in rules for level designers, unless you have permission to do that (e.g. told in readme or online discussed with original author). If you want to use standard QL sky shader, why don't you just use that? It will work even in your own map. You don't need to copy anything, that's what Workshop strength is in. You can use standard textures and shaders from basic installation in your map without need to include it in your map and if you want to use texturepacks (like Evil Lair's or Sock's texturesets), you don't need to include it in your map for QL like it was required in Q3 to make your map running correctly. You just make some custom shaders for your own variations, that's it.

I don't map for QL, so I just post my thoughs, but it should be like that said. Important thing for you: Don't copy anything in standard QL packs, it's considered stealing and such like that is punished by banning your account...



_________________
[ Websites | Facebook | Twitter | YouTube | Instagram ]
When you feel the worst, turn to the sun and all the shadows will fall behind you.” - John Lennon


Top
                 

Recruit
Recruit
Joined: 10 Dec 2016
Posts: 2
PostPosted: 12-10-2016 05:28 AM           Profile Send private message  E-mail  Edit post Reply with quote


I'm trying to make a custom sky shader. But if even a direct copy don't work (doesn't matter which standard sky shader i copy) i can't go further customizing it.

This is weird, since i followed exactly the gtk radiant manual. And the shaders do work principally, except for the illumination of my map.




Top
                 

The hell good boy
The hell good boy
Joined: 22 Jun 2011
Posts: 1922
PostPosted: 12-10-2016 05:49 AM           Profile   Send private message  E-mail  Edit post Reply with quote


What shader did you want to test copied? Post original here (in code tag). Sky shader does not use q3map_surfacelight as this directive illuminates nearest around the shader surface, which doesn't work for sky. Sky shaders use q3map_sun (apologised for the incorrect q3map_sky) to create sunlight (or moonlight, it depends on sun light settings). You set light color, light intensity, light direction angle <0;360> and elevation angle <0;90>... Not surface light...



_________________
[ Websites | Facebook | Twitter | YouTube | Instagram ]
When you feel the worst, turn to the sun and all the shadows will fall behind you.” - John Lennon


Top
                 

Insane Quaker
Insane Quaker
Joined: 15 Feb 2010
Posts: 298
PostPosted: 12-10-2016 08:34 AM           Profile Send private message  E-mail  Edit post Reply with quote


CZghost wrote:
Sky shader does not use q3map_surfacelight...

Sorry, that's wrong!

@Gelenkbusfahrer:
Off course you can use q3map_surfacelight! Most of the original sky shader use this key for diffuse (non directional) lighting.

Check your shaderlist.txt again. Do not include the ".shader" suffix. Only "mapname".
Also check the listed shader files during compiling. Does your shader show up like this: "entering scripts/mapname.shader" ?



_________________
Q3A Maps - by sst13
Quake Live Workshop


Top
                 

The hell good boy
The hell good boy
Joined: 22 Jun 2011
Posts: 1922
PostPosted: 12-10-2016 09:03 AM           Profile   Send private message  E-mail  Edit post Reply with quote


Well I did not see sky texture with q3map_surfacelight. So apologise for misinformation :D



_________________
[ Websites | Facebook | Twitter | YouTube | Instagram ]
When you feel the worst, turn to the sun and all the shadows will fall behind you.” - John Lennon


Top
                 

Mercenary
Mercenary
Joined: 28 May 2010
Posts: 210
PostPosted: 02-13-2017 11:20 AM           Profile Send private message  E-mail  Edit post Reply with quote


From your nickname I assume you are German. I've written an in-depth tutorial about creating custom sky shaders. As CZghost said, q3map_surfacelight is the old and deprecated method for skybox lighting, because it will illuminate surfaces closer to the sky more than those farther away from it. Use q3map_sunExt for the direct sunlight and q3map_skylight for the indirect sky light for best results. I've explained both parameters in the tutorial.



_________________
Portfolio - My Quake 3 mapping tutorials - My Quake 3 maps


Top
                 
Quake3World.com | Forum Index | Level Editing & Modeling


Post new topic Reply to topic


cron
Quake3World.com
© ZeniMax. Zenimax, QUAKE III ARENA, Id Software and associated trademarks are trademarks of the ZeniMax group of companies. All rights reserved.
This is an unofficial fan website without any affiliation with or endorsement by ZeniMax.
All views and opinions expressed are those of the author.