rgoer Posted July 21, 2003 Share Posted July 21, 2003 And they told me it was impossible... heh. Ydnar knows best, like always. I love q3map2. Link to comment Share on other sites More sharing options...
Shotokan Posted July 21, 2003 Share Posted July 21, 2003 Wow rgoer... As a fellow mapper my respect for you has heightened dramatically. I am impressed like always rgoer. Link to comment Share on other sites More sharing options...
Kengo Posted July 21, 2003 Share Posted July 21, 2003 *Gasp* That is amazing man, looks truely excellent. Shame your character's more than ample frame blocks out most of the view Amazing the difference a good skybox can make to the look of a level, I think several maps of late like Patrick_Hs have shown that. You got this skybox in mind for a particular project? BTW, up for a fight with the RPG system? Link to comment Share on other sites More sharing options...
Patrick_H Posted July 21, 2003 Share Posted July 21, 2003 Man, that looks great. I have read a little about this in one of the EasyGen manuals. After seeing this screen, I'm dying to redo some of the exteriors of my map. Did you use EasyGen for this? Expect more pestering to come... Link to comment Share on other sites More sharing options...
rgoer Posted July 21, 2003 Author Share Posted July 21, 2003 Yes, I used EasyGen for this, but it was a little bit of a pain in the ass. Truthfully, though, the only hard part was getting past everybody that said "oh, you can't do that in JK2." Other than that, you have to remember that when people talk about the quake3 "scripts" directory, they mean the "shaders" directory in JK2, and also that there exists no common/terrain shader in JK2 by default--you have to make it yourself. Link to comment Share on other sites More sharing options...
Patrick_H Posted July 21, 2003 Share Posted July 21, 2003 Yeah I was a bit thrown by that "scripts" thing too, but looked at a few Q3 maps and realized that it was where the .shader file was kept. So this common/terrain shader exists in Quake III? Link to comment Share on other sites More sharing options...
rgoer Posted July 21, 2003 Author Share Posted July 21, 2003 Yeah. All you have to do is open up yourmap.shader in Notepad and add this to the end of it: textures/common/terrain { q3map_terrain surfaceparm nodraw surfaceparm nolightmap surfaceparm nomarks } That's all it takes. Let me know when you've got a decent metashader working in JK2 and then I'll tell you how to get it lightmapped (instead of vertex-lit), so shadows and such fall correctly onto your terrain. Link to comment Share on other sites More sharing options...
wedge2211 Posted July 21, 2003 Share Posted July 21, 2003 Hot damn. Just don't use yavin/greenblock, it has ugly lines where I think you meant to have grass. But, man, that looks nice. Where's the rest of the map to go with it???? Link to comment Share on other sites More sharing options...
Shotokan Posted July 22, 2003 Share Posted July 22, 2003 Yea wedge is right. Use the yavin moss texture thing. Well I'm assuming that you want the floor to look green because of the yavin/greenblock texture. Link to comment Share on other sites More sharing options...
rgoer Posted July 22, 2003 Author Share Posted July 22, 2003 Heh, thanks for the concern, guys. This was just a quick proof-of-concept map; the textures were chosen quasi-randomly, solely because I thought they were different enough from each other that I could see if the alpha-blending was working properly. You guys are right, though: greenblock is fugly. Link to comment Share on other sites More sharing options...
Eldritch Posted July 22, 2003 Share Posted July 22, 2003 Sweet merciful crap! I don't even have the words to describe such a screenshot - the proof-of-concept ALONE is staggeringly stupourfazing (yeah, I made that word up JUST for that terrain). Can't wait to see the rest of the map that accompanies it. Link to comment Share on other sites More sharing options...
__CKY__ Posted July 24, 2003 Share Posted July 24, 2003 That is awesome dude! Link to comment Share on other sites More sharing options...
Jorus Ardel Posted July 25, 2003 Share Posted July 25, 2003 Holy sheat! Is all I have to say. That is certainly exceptional, nice work on that man! Link to comment Share on other sites More sharing options...
<EJK>DevMapAll Posted August 16, 2003 Share Posted August 16, 2003 Screenshot........too...............big............ Nice man:thmbup1: love it I know the screentshot is in multiplayer, so is the map going to be multiplayer or SP? Link to comment Share on other sites More sharing options...
JDKnite188 Posted August 16, 2003 Share Posted August 16, 2003 Just beautiful. MAKE MORE MOUNTAINS! I wouldn't mind just walking through miles of that. Oh btw, that skybox is nice, but I can see block edges in it. Try to get a more detailed one. Link to comment Share on other sites More sharing options...
rgoer Posted August 16, 2003 Author Share Posted August 16, 2003 Originally posted by JDKnite188 ...Oh btw, that skybox is nice, but I can see block edges in it. Try to get a more detailed one... Tell it to Raven Soft--it's one of theirs. Like I said: this was just a proof-of-concept map. When I get around to using this technology in a real map, you can rest assured I'll be making my own high-res skybox. Link to comment Share on other sites More sharing options...
Shadyz Posted August 18, 2003 Share Posted August 18, 2003 Step by step tut be possible? Link to comment Share on other sites More sharing options...
rgoer Posted August 18, 2003 Author Share Posted August 18, 2003 Before we get started, class, will all students please make sure they've downloaded EasyGen for me? Thanks, that's a big help. Also, take some time to familiarize yourself with the EasyGen 3D view controls before going any further with this tutorial; they are pretty much like Radiant, but there are a few subtle differences. If you play around with it for two minutes, you'll figure it out. Some EasyGen setup guidelines: • When it asks you for the "Work mod" path, enter the path to your "gamedata/base" directory (for default install of JK2: "c:\program files\lucasarts\star wars jk ii jedi outcast\gamedata\base") • Ignore the "Bitmaps" "Export folders" path • Put the path to your "gamedata/base/textures" in for the "Bitmaps" "Import folder" (for default install of JK2: "c:\program files\lucasarts\star wars jk ii jedi outcast\gamedata\base\textures\") • Set the "Player size" to "32 32 64" • Make sure the "Texture load filter" is set to "jpg;tga"1. Create your heightmap in the bitmap-creation software of your choosing. I'm partial to Photoshop, but if that particular app is beyond your means, I'm sure any number of cheaper alternatives will give you decent results (maybe). Here are the particulars: • The heightmap needs to be 33x33 pixels (yes, that small--each pixel of this heightmap corresponds to a terrain vertex in EasyGen) • The heightmap must be an 8-bit, greyscale .bmp Bitmap file. • 50% grey is "sea level," zero elevation. Darker pixels are lower elevation, and brighter pixels are higher. Who would have guessed? • Save your heightmap into your base/textures/<yourmap>/ directorySo anyway, here's how my heightmap turned out for this little test map I started this thread for: Just a little unimpressive, yeah? Well, brace yourself: the sparks, now waking from their long winter naps, are preparing to fly. 2. Fire up EasyGen and pick, from the "File" menu, "Import -> Heightmap (.bmp)" In the next little window that pops up, hit the "Browse..." button and navigate to base/textures/<yourmap>/ (where you saved the .bmp heightmap you created in step one). After you've chosen your heightmap, notice the "Terrain height" field: it defaults to "256," which is pretty low. Set this to "1024" and hit "Ok." You should see something like this: 3. Now it's time to add textures; from the "Textures" menu in EasyGen, choose the "Add folder..." option (it's the first one): Now browse to the textures directory of your choosing; for this example map, I used the "Yavin" texture set. Loading the textures in EasyGen takes even longer than in Radiant, so be prepared to wait. You'll know it's ready when you can hit the "Alphamap" tab and things look like this: 4. Click the first black square in that color palette area and choose a non-black color. Then scroll down the texture browser (on the left) and choose what texture you want that color to represent. Now, choose "Texture" from the "View" menu and things will start looking like this: 5. Click the next black square in the palette, pick a new color and a new texture. Now we're ready to start painting. Make sure your newest color/texture is selected in the palette, then you can use ctrl+shift+leftMouse to paint that texture onto your terrain: 6. Click the next black square in the palette, pick a new color and a new texture. Paint as many different textures onto your terrain as you like, but be warned: quake will alpha-blend at most two textures on any given triangle. If you try and blend more than two textures on one triangle, it will show up as black in EasyGen, so it's easy to see the areas you need to go back and fix: When you get this, you'll need to re-paint your textures until you've only got two blends happening on any given triangle. 7. Once you've got your textures set up how you want them, it would be a good time to Save your project in EasyGen. Just in case the power goes out, you can load up your .egn file and not have lost all this work. 8. Now is the time to export the whole shebang: Then, in the next window, set your options like this (everywhere I wrote "tutorial," put whatever your project is called): Save the .pcx file into the "gamedata/base/" directory, and save the metashader into the "base/scripts/" directory. This will need to be moved into the "base/shaders/" directory in a little bit, but right now EasyGen only wants you to put it into the scripts folder. Set the remaining options up like I've got them (I assume you're using q3map2 to compile), and you're good to go. Hit "Continue >>>" and away we go--just save it as whatever.map in the "base/maps/" folder, and we're done with this part. 9. Move your .shader file from the "base/scripts/" folder to the "base/shaders" folder, and then open your .shader file in Notepad (or whatever text editor you prefer). It should look something like this: textures/tutorial/terrain_0 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/greenblock.jpg } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_1 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/rock3.jpg } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_2 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/lighturth.jpg } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_3 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/stone.jpg } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_0to1 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/greenblock.jpg } { map textures/yavin/rock3.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_0to2 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/greenblock.jpg } { map textures/yavin/lighturth.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_0to3 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/greenblock.jpg } { map textures/yavin/stone.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_1to2 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/rock3.jpg } { map textures/yavin/lighturth.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_1to3 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/rock3.jpg } { map textures/yavin/stone.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain_2to3 { q3map_lightmapsamplesize 64 q3map_lightmapaxis z q3map_texturesize 512 512 q3map_tcGen ivector ( 128 0 0 ) ( 0 128 0 ) { map textures/yavin/lighturth.jpg } { map textures/yavin/stone.jpg alphaGen vertex blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap } } textures/tutorial/terrain.vertex { { map textures/yavin/greenblock.jpg rgbGen vertex } } This is OK, and will work (sort-of), but some tweeking is needed if you want your terrain to get lightmapped. We want to change it to look like this: textures/tutorial/baseterrain { q3map_lightmapsamplesize 8 q3map_lightmapsampleoffset 8 q3map_lightmapaxis z } textures/tutorial/terrain_0 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/greenblock.jpg rgbGen identity tcMod scale 0.1 0.1 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_1 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/rock3.jpg rgbGen identity tcMod scale 0.05 0.05 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_2 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/lighturth.jpg rgbGen identity tcMod scale 0.075 0.075 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_3 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/stone.jpg rgbGen identity tcMod scale 0.1 0.1 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_0to1 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/greenblock.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/yavin/rock3.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_0to2 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/greenblock.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/yavin/lighturth.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_0to3 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/greenblock.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/yavin/stone.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_1to2 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/rock3.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 } { map textures/yavin/lighturth.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_1to3 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/rock3.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 } { map textures/yavin/stone.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/tutorial/terrain_2to3 { q3map_baseshader textures/tutorial/baseterrain { map textures/yavin/lighturth.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 } { map textures/yavin/stone.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen indentity } } textures/tutorial/terrain.vertex { { map textures/yavin/greenblock.jpg rgbGen vertex } } textures/common/terrain { q3map_terrain surfaceparm nodraw surfaceparm nolightmap surfaceparm nomarks } You'll need to twiddle with the "tcMod scale" lines to get your textures looking how you want them, exactly, but this shader file should now be good to go. I hope you can see how to apply these changes to the shader files EasyGen generates. 10. Open up the .map file you created in step eight in Radiant. Select the terrain entity (it's just a func_group, so do whatever you need to do to select all the brushes--in GtkRadiant it's ctrl+alt+click) and open the entity inspector by hitting the "n" key. Make sure you've got your terrain entity set up like this: just make sure the name of the .pcx file in the entity inspector matches the name of the .pcx file you created with EasyGen, and make sure that the "shader" line matches the name of your shader file (it should be yourmap/terrain). Finally, make sure that you didn't forget to add the "textures/common/terrain" code to yourmap.shader. Now, save this map as a prefab and import it into whatever map you're working on. 11. Compile with q3map2 and you're good to go--you might want to use the -shadeangle switch (I usually use 120) to make sure your terrain is as smooth as possible. Good luck! Link to comment Share on other sites More sharing options...
Shadyz Posted August 18, 2003 Share Posted August 18, 2003 holy crap! thanks alot. Link to comment Share on other sites More sharing options...
rgoer Posted August 18, 2003 Author Share Posted August 18, 2003 No prob; always happy to help. Link to comment Share on other sites More sharing options...
Shadyz Posted August 18, 2003 Share Posted August 18, 2003 Ok i did everything in the tutorial and i tested in game and none of my textures showed up. Here are my shaders, and yes after i edited in notepad i renamed it to tutorial.shader Origional: http://shadyz.elitegaming.net/tutorial.shader Edited: http://shadyz.elitegaming.net/tutorial2.shader Link to comment Share on other sites More sharing options...
Shadyz Posted August 18, 2003 Share Posted August 18, 2003 Ok i did everything in the tutorial and i tested in game and none of my textures showed up. Here are my shaders, and yes after i edited in notepad i renamed it to tutorial.shader Origional: http://shadyz.elitegaming.net/tutorial.shader Edited: http://shadyz.elitegaming.net/tutorial2.shader Link to comment Share on other sites More sharing options...
rgoer Posted August 18, 2003 Author Share Posted August 18, 2003 Keep in mind that "tutorial" was just the example name I used for the tutorial above. Your .shader file should be called <yourmap>.shader (or whatever naming convention you follow when mapping), where <yourmap> is the name of the project your working on. As in, when I was working on the Chapel of the Ysalamiri, the map file was chapel.map, the textures were in base/textures/chapel/ and the shader file was called chapel.shader. Now, as for your problems, it looks like you need to be using the "blackstone" name in your .shader file. The terrain meta-shader file doesn't have to be separate from your other shaders (although, if you're familiar enough with how .shader files can be organized, it doesn't hurt to keep them in separate files). Here, try this: textures/blackstoneTerrain/baseterrain { q3map_lightmapsamplesize 8 q3map_lightmapsampleoffset 8 q3map_lightmapaxis z } textures/blackstoneTerrain/terrain_0 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone6.jpg rgbGen identity tcMod scale 0.1 0.1 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_1 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone5.jpg rgbGen identity tcMod scale 0.05 0.05 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_0to1 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone12.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/blackstone/blackstone6.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_0to2 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone12.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/blackstone/blackstone5.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_1to2 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone6.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 } { map textures/blackstone/blackstone5.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain.vertex { { map textures/blackstone/blackstone12.jpg rgbGen vertex } } textures/common/terrain { q3map_terrain surfaceparm nodraw surfaceparm nolightmap surfaceparm nomarks } Save that into a .shader file called "blackstoneTerrain.shader" and make sure that both "blackstone" and "blackstoneTerrain" have been added to shaderlist.txt. Now, open your terrain .map file and inspect the terrain entity. It should look like this: You want to change the first two entries so that they now read: alphamap blackstone.pcx shader blackstoneTerrain/terrainMake sure that those match your filenames--if you saved your alphamap as "tutorial.pcx" then you need to rename it as "blackstone.pcx" instead. Now, as long as you added "blackstone" and "blackstoneTerrain" to shaderlist.txt and you do an sv_pure 0 before you devmap, you should be good to go. One important thing: make sure that the top face of all the brushes in your terrain entity are textured with common/terrain! If you missed this part of the tutorial up there, you really need to re-read it. When you choose to export your "terrain entity" from EasyGen, you have to tell it to use "common/terrain" as the "shader" for the "top" of the brushes. Otherwise, it won't work. Link to comment Share on other sites More sharing options...
rgoer Posted August 18, 2003 Author Share Posted August 18, 2003 Keep in mind that "tutorial" was just the example name I used for the tutorial above. Your .shader file should be called <yourmap>.shader (or whatever naming convention you follow when mapping), where <yourmap> is the name of the project your working on. As in, when I was working on the Chapel of the Ysalamiri, the map file was chapel.map, the textures were in base/textures/chapel/ and the shader file was called chapel.shader. Now, as for your problems, it looks like you need to be using the "blackstone" name in your .shader file. The terrain meta-shader file doesn't have to be separate from your other shaders (although, if you're familiar enough with how .shader files can be organized, it doesn't hurt to keep them in separate files). Here, try this: textures/blackstoneTerrain/baseterrain { q3map_lightmapsamplesize 8 q3map_lightmapsampleoffset 8 q3map_lightmapaxis z } textures/blackstoneTerrain/terrain_0 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone6.jpg rgbGen identity tcMod scale 0.1 0.1 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_1 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone5.jpg rgbGen identity tcMod scale 0.05 0.05 } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_0to1 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone12.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/blackstone/blackstone6.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_0to2 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone12.jpg rgbGen identity alphaGen vertex tcmod scale 0.1 0.1 } { map textures/blackstone/blackstone5.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain_1to2 { q3map_baseshader textures/blackstoneTerrain/baseterrain { map textures/blackstone/blackstone6.jpg rgbGen identity alphaGen vertex tcmod scale 0.05 0.05 } { map textures/blackstone/blackstone5.jpg rgbGen identity alphaGen vertex tcmod scale 0.075 0.075 blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA } { map $lightmap blendFunc GL_DST_COLOR GL_ZERO tcGen lightmap rgbGen identity } } textures/blackstoneTerrain/terrain.vertex { { map textures/blackstone/blackstone12.jpg rgbGen vertex } } textures/common/terrain { q3map_terrain surfaceparm nodraw surfaceparm nolightmap surfaceparm nomarks } Save that into a .shader file called "blackstoneTerrain.shader" and make sure that both "blackstone" and "blackstoneTerrain" have been added to shaderlist.txt. Now, open your terrain .map file and inspect the terrain entity. It should look like this: You want to change the first two entries so that they now read: alphamap blackstone.pcx shader blackstoneTerrain/terrainMake sure that those match your filenames--if you saved your alphamap as "tutorial.pcx" then you need to rename it as "blackstone.pcx" instead. Now, as long as you added "blackstone" and "blackstoneTerrain" to shaderlist.txt and you do an sv_pure 0 before you devmap, you should be good to go. One important thing: make sure that the top face of all the brushes in your terrain entity are textured with common/terrain! If you missed this part of the tutorial up there, you really need to re-read it. When you choose to export your "terrain entity" from EasyGen, you have to tell it to use "common/terrain" as the "shader" for the "top" of the brushes. Otherwise, it won't work. Link to comment Share on other sites More sharing options...
lukeskywalker1 Posted August 21, 2003 Share Posted August 21, 2003 sweet.... i just downloaded that, ganna check it out now Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.