Page 1 of 1
What is the best method of adding tree shadows?
Posted: Thu Feb 26, 2004 10:09 pm
by Stevo
I can't find the answer. I've found a few single-tree masked textures that cast some nice tree shadows for the tree entities, but grenades bounce off of them and that is extremely odd. What is the best method for adding shadows to trees? Is it possible for a fence texture to cast a shadow and yet be non-solid? I want a tree shadow that doesn't hinder grenade lobbing, please!
Thanks.
Posted: Thu Feb 26, 2004 11:44 pm
by K.I.A.
I dont know much about, but did u try making a brush out of 'light clip' under 'common' textures. Just an idea.
Hmm
Posted: Fri Feb 27, 2004 12:46 am
by Stevo
Well I couldn't find light_clip but I found a texture just called light. It affected lighting, of course, but it's also visible and solid. Arg.
Posted: Fri Feb 27, 2004 12:57 am
by K.I.A.
another idea... did u try sunblock? i know its not solid, i just dont know if it casts a shadow.
Posted: Fri Feb 27, 2004 1:23 am
by wacko
common/caulkshadow is invisible and is casting shadows. but it's solid...
Posted: Fri Feb 27, 2004 1:24 am
by hogleg
Its real easy man, Just make a circle brush like a plate.
Apply shadow clip to it!
Put it in the middle of your tree, like 3/4 towards the top.
Poof you will have your shadow from your tree.
O, my bad, I didn't know shadow clip was solid, can you check nonsolid?
or put regulare clip on the sides?
or just raise it so high that nothing will hit it. But you'll still get your shadow.
A Solution!
Posted: Fri Feb 27, 2004 4:37 am
by Stevo
Awesome. Thanks for all the help.
Here's what I've come up with:
My goal was to make a shadow that looks like a tree, but is also non solid and invisible. I couldn't find any textures like this in MOHAA so I made my own using one of the tree pictures.
Code: Select all
textures/steve/treeshadowyeah
{
qer_editorimage textures/models/natural/tree4_3.tga
surfaceparm nodraw
surfaceparm nonsolid
surfaceparm castshadow
surfaceparm alphashadow
cull none
{
map textures/models/natural/tree4_3.tga
depthWrite
alphafunc GE128
nextbundle
map $lightmap
}
}
This does EXACTLY what I want it to do!! Now I can have trees casting their rightful shadows and still have grenades fly through the treetops. I haven't exhaustively searched the MOHAA textures yet, so there MAY be a texture like this already, but as far as I know there isn't. Woohoo! This will make maps look so much better. The only trick is, since it is a flat texture, making the texture face the sunlight in the right direction to cast the appropriate shadow in the map. BY THE WAY - This texture uses nodraw. You know how all fences use nodraw? Well, this texture counts as a fence. So, only one side has the texture, and the rest have nodraw.
Awesome!
Posted: Fri Feb 27, 2004 4:54 am
by Stevo
Oh yeah. The "cull none", of course, isn't necessary.