Author Topic: shader stuff  (Read 4460 times)

swamp-cecil

  • Posts: 774
  • Turrets: +80/-163
    • Tremulous
shader stuff
« on: December 14, 2010, 09:57:48 pm »
so, i want to make a texture that is transparent on white areas on the texture and can be walked through. Here is my code. Since it is my first shader coding, it would probably be wrong.
Code: [Select]
textures/sinix/warning
{
{
map textures/sinix/warning.tga
surfaceparm trans
surfaceparm nonsolid
surfaceparm nolightmap
blendfunc add
}
}

i took the display from arachnig2 and modified it. does this work?
REMEMBER: the WHITE parts MUST be transparent, not the black parts.
these are stupid suggestions, don't even waste our time.
I don't like your negative attitude.

CATAHA

  • Posts: 539
  • Turrets: +8/-18
    • Tremulous Lair
Re: shader stuff
« Reply #1 on: December 14, 2010, 10:19:03 pm »
surfaceparm section should be right after 'textures/sinix/warning {'
Check shader manual for details
Russian q3/trem mapping site: http://tremlair.krond.ru/
=[ Boxmaps suck if they have no concept ]=

Ice Trap (InstaGib)

Other maps: A.T.D*S Remake

swamp-cecil

  • Posts: 774
  • Turrets: +80/-163
    • Tremulous
Re: shader stuff
« Reply #2 on: December 14, 2010, 10:24:36 pm »
surfaceparm section should be right after 'textures/sinix/warning {'
Check shader manual for details

link to the shader manual? :S
these are stupid suggestions, don't even waste our time.
I don't like your negative attitude.

CATAHA

  • Posts: 539
  • Turrets: +8/-18
    • Tremulous Lair
Re: shader stuff
« Reply #3 on: December 14, 2010, 10:32:04 pm »
google -> shader manual? =D
Ok,ok... i know, u lazy like we all here. Try check here: http://q3map2.everyonelookbusy.net/shader_manual/
seriously... you trying mapping without shader manual knowledges? There is a lot of amazing things you can do using only shaders. Learning how shaders work take a lot of time, but totally worth it.

PS lol, my site 7th on 'shader manual' request in google! O_o

UPD: You can try shaders editor Q3ASE: http://www.bpeers.com/software/q3ase/q3asetutorial.html, but i strongly recommend read shaders manual for basic knowledges.
« Last Edit: December 14, 2010, 10:34:36 pm by CATAHA »
Russian q3/trem mapping site: http://tremlair.krond.ru/
=[ Boxmaps suck if they have no concept ]=

Ice Trap (InstaGib)

Other maps: A.T.D*S Remake

CreatureofHell

  • Posts: 2422
  • Turrets: +430/-126
    • Tremtopia
Re: shader stuff
« Reply #4 on: December 15, 2010, 03:30:23 pm »
Looked at this topic at all for the transparency?
{NoS}StalKer
Quote
<Timbo> posting on the trem forums rarely results in anything good

swamp-cecil

  • Posts: 774
  • Turrets: +80/-163
    • Tremulous
Re: shader stuff
« Reply #5 on: December 15, 2010, 08:18:37 pm »
close, but thats not what i want Creature. The graffiti is ON the wall. I want it floating like a hologram on no texture. would it still work?
these are stupid suggestions, don't even waste our time.
I don't like your negative attitude.

CreatureofHell

  • Posts: 2422
  • Turrets: +430/-126
    • Tremtopia
Re: shader stuff
« Reply #6 on: December 15, 2010, 08:39:22 pm »
Oh, try checking out Ingar's hologram textures in Vega and Procyon.
{NoS}StalKer
Quote
<Timbo> posting on the trem forums rarely results in anything good

mindriot

  • Posts: 5
  • Turrets: +0/-0
Re: shader stuff
« Reply #7 on: December 16, 2010, 08:33:50 am »
close, but thats not what i want Creature. The graffiti is ON the wall. I want it floating like a hologram on no texture. would it still work?

Yes it should still work.

- Make a detail brush.
- Completely texture with common/nodraw.
- Texture one brush face with your shader.


Possible configuration:
Code: [Select]
textures/sinix/warning
{
    qer_editorimage textures/sinix/warning.tga //image to display in radiant

    nomipmaps //prevents resolution decrease due to distance
    nopicmip //prevents resolution decrease due to distance

    surfaceparm trans
    surfaceparm nonsolid
    surfaceparm nolightmap
    surfaceparm nomarks

    deformVertexes autosprite2 //shader always faces the player

    {
        map textures/sinix/warning.tga
        blendfunc filter
    }
}