I need the syntax for a shader

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

Post Reply
gmadmin
Private
Posts: 2
Joined: Tue May 28, 2013 11:49 am

I need the syntax for a shader

Post by gmadmin »

Hello all,

New here :mrgreen: Mapped along time ago,picked it up again :) Question i have is:

What is the correct syntax to fill a shader?

I have this, doesn't work:

Code: Select all

textures/lokaal
{
    qer_keyword concrete 
    qer_keyword wall 
    surfaceparm stone 
    {
        map textures/lokaal/blauw.jpg
        rgbGen identity
        depthWrite
    }
    {
        map textures/lokaal/bord.jpg
        rgbGen identity
        depthWrite
    }
    {
        map textures/lokaal/wittemuur.jpg
        rgbGen identity
        depthWrite
    }
    {
        map $lightmap
        blendFunc GL_DST_COLOR GL_ZERO
        rgbGen identity
        depthFunc equal
    }
} 
Basicially: how do i put two,or more,images in one pk3 file?

Kind regards,

CJ
Phobia
Lance Corporal
Posts: 12
Joined: Mon Sep 03, 2012 5:16 pm

Re: I need the syntax for a shader

Post by Phobia »

Hiya!

This forum is not being used much anymore.. so you'd have a better chance of getting a reply over at modtheater.
Someone could suddenly still reply here though none the less :)

Do you still have any of your old maps if I may ask?

Kind Regards,
Brian
gmadmin
Private
Posts: 2
Joined: Tue May 28, 2013 11:49 am

Re: I need the syntax for a shader

Post by gmadmin »

Good morning,

Thx for the reply. About my old map: i added a few screenshots I made back then. Hope you enjoy :)
shot0013.klein.JPG
shot0013.klein.JPG (55.72 KiB) Viewed 698 times
and
shot0010.klein.JPG
shot0010.klein.JPG (49.28 KiB) Viewed 698 times
Basically: I am a teacher. Me and my students are building our school with MOHradiant. Last day of school we have a LAN party :mrgreen:

Gr,
Phobia
Lance Corporal
Posts: 12
Joined: Mon Sep 03, 2012 5:16 pm

Re: I need the syntax for a shader

Post by Phobia »

Oh that's pretty cool! :)
Any chance you could upload that one? Or are you still working on that specific one?

Btw, here's a link to modtheater: http://www.modtheater.com/forums/allied-assault.55/

Kind Regards,
Brian
BatteryAziz
Moderator
Posts: 82
Joined: Tue Jun 15, 2010 4:44 pm

Re: I need the syntax for a shader

Post by BatteryAziz »

you have to create a new .shader file for every new texture you add (just copy and paste your code and change the names and target .jpg). you can't call multiple textures under the same shader header.

right now you have "textures/lokaal" as the first line
in your case all you need to do is split them up in
textures/lokaal/blauw
textures/lokaal/bord
textures/lokaal/wittemuur
etc. as the first line

you can put all the shader files in the same pk3 as your map (i put them in the "scripts" dir)
neillomax
Lieutenant General
Posts: 880
Joined: Thu Jun 23, 2005 6:57 am

Re: I need the syntax for a shader

Post by neillomax »

digital guns in school.................. gonna lose your job?........ as crazy as it sounds, they suspend and humiliate 5 year old's for lego guns and for a pop tart that looks like a gun..........
BatteryAziz
Moderator
Posts: 82
Joined: Tue Jun 15, 2010 4:44 pm

Re: I need the syntax for a shader

Post by BatteryAziz »

neillomax wrote:digital guns in school.................. gonna lose your job?........ as crazy as it sounds, they suspend and humiliate 5 year old's for lego guns and for a pop tart that looks like a gun..........
i'm pretty sure he's dutch. we're not as uptight about those things as they are in the UK/US. :P
Post Reply