Shader + pk3 problems


([MOS]StiloMAN.pl) #1

When I use bsp files and play in sv_pure 0 game use my shader file for my texture…

But when I try to play pk3 file, game doesn’t use shader file…
what I have to do?

This is PK3 file:


+ Maps:
   map.bsp
   map.srf
   map.prt
   map.bak
   map.script
   map.arena
   

+ Scripts:
   map.arena
   map.script
   stilo.shader

+ Textures:
   stilo_snow_64
   (other textures)

and code of stilo.sader:


// stilo.shader

textures/stilo/stilo_snow_64
{
	surfaceparm snowsteps
        surfaceparm landmine 
	implicitMap -
}

is code of stilo.shader file valid for pk3 ??
EDIT: More informative title


(duke'ku) #2

is map.shader in shaderlist.txt?


([MOS]StiloMAN.pl) #3

Well,

Write propertly structure of the files in pk3.

I have /textures/stilo_snow_64.jpg and I wanna use shader for this image in pk3 file. When I use sv_pure 0 and .bsp files I can use shader files.

Please write step by step :drink:


(hhhmmmmm) #4

I Think it should be textures/stilo/stilo_snow in your pk3 file.
IE Make the folder stilo in your texture folder then and stilo_snow… and it should work if all is correct, cant see anything wrong with your shader


(Drakir) #5

Quote from this topic: http://www.splashdamage.com/forums/viewtopic.php?t=2513


([MOS]StiloMAN.pl) #6

I still don’t know what in my pk3 is wrong :banghead:

This is my PK3:

Dir /maps

mos_kk_0_06.bsp, mos_kk_0_06.script, mos_kk_0_06_tracemap.tga

Dir /levelshots

mos_kk_0_06.tga, mos_kk_0_06_tracemap.tga

Dir /scripts

shaderlist.txt, stilo.shader, mos_kk_0_06.arena, mos_kk_0_06.script

Dir /textures

Dir /stilo {brown_wall.jpg, stilo.shader, tex_wall.jpg, stilo_snow_64.jpg, other}

I have added file shaderlist.txt:


// this file lists all the separate shader files

_unsorted
alpha
alpha_sd
assault
assault_rock
awf_props
battery
battery_wall
bbmodels_mapobjects
blimp
bunker_sd
castle_door
castle_floor
castle_window
castle_wood
chat
chat_window
chat_wood
chateau
common
decals
doors
eerie
egypt_door_sd
egypt_floor_sd
egypt_props_sd
egypt_rock_sd
egypt_trim_sd
egypt_walls_sd
egypt_windows_sd
egypt_wood_sd
factory_sd
fueldump
gfx_2d
gfx_clipboard
gfx_damage
gfx_hud
gfx_limbo
gfx_misc
goldrush
icons
levelshots
lights
liquids
liquids_sd
mapfx
metal_misc
metals_sd
miltary_door
miltary_trim
miltary_wall
models_ammo
models_foliage
models_furniture
models_mapobjects
models_multiplayer
models_players
models_shards
models_weapons2
mp_goldrush
mp_guns
mp_railgun
mp_rocket
mp_seawall
mp_siwa
mp_wurzburg
props
props_sd
radar
railgun_props
railway_sd
rock
rubble
seawall_wall
sfx
shadows
siwa_fx_sd
siwa_props_sd
siwa_skyboxes_sd
skies
skies_sd
snow
snow_sd
sprites
stone
swf
temperate_sd
terrain
textures
tobruk_wall_sd
tobruk_windows_sd
town_props
town_roof
town_wall
town_window
town_wood
tree
ui_assets
ui_assets2
villa_sd
village
wood
xlab_door
xlab_props
xlab_wall
stilo


@Drakir, in that thread I haven’t found anything about placing shaderfiles and using them in pk3 file.

I need works shaderfiles in pk3. I don’t know why this shaderfile doesn’t works in pk3 :???: :bored: :eek2: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead:


(seven_dc) #7

Ok, do these:

  1. remove shaderlist.txt from your pk3. It is bad!
  2. rename your stilo.shader into mos_kk_0_06.shader

The shader file needs to be the same name as the map. The shader file itself can contain any named shaders.

What does the mos_kk_0_06.script file do in scrits directory. It needs to be only in maps?


NEW JERSEY DISPENSARY


([MOS]StiloMAN.pl) #8

ehehehehe

v57 v57 v57 v57 v57 :clap:

Thank you seven_dc :clap: :clap: :clap:

Now all is OK
:drink:


(Drakir) #9

Perhaps this helps!


([MOS]StiloMAN.pl) #10

What does lm_0000.tga > lm_0006.tga files in pk3 ??


(Loffy) #11

Hi!
Im pretty sure they are externally stored lightmaps.
But don’t ask me more - I do not know alot about these so called lightmaps. They are used by the game to draw the environments and light these surfaces. (I think.)
My question is: are lightmaps always “created” by the compiler, or only when there are outdoor environments?
// Loffy


(hhhmmmmm) #12

I think the light maps are always in game if you complie with light , as my current map which should go to beta this weekend (v57) has them and there is no outdoors in it.


(seven_dc) #13

Are you sure the picture is correct drakir? [MOS]StiloMAN.pl had problems that the engine did not realize that the shader file “stilo.shader” has shaders for his map and did not loaded the shader file. But when he changed the shader file’s name it did work. I thought that the shader file must be same name as the map?

In your image there is your_shadername.shader it should be mapname.shader just like mapname_levelshots.shader must start with the maps name.


fat woman Webcam


(Drakir) #14

Well i am sure that the .shader file dont have to have the mapname.
In Northpole i used a shader for all my stuff that did not have the mapname.

Think of it this way, if you are using “caulk”, it comes from common.shader and that still works right!


(svenni) #15

So that is why you should never edit the original .shader files (like i.e. common.shader) but instead create your own? But what happens if someone uses the same name in a shader (i.e textures/silo/silo_wall)? Is the shader which belongs in the correct .pk3 automaticly chosen? And what happens if two different maps are named the same (i.e silo.bsp)?

Just good to know…