Page 1 of 1

transparent blocks

Posted: Sat Jul 14, 2007 7:39 am
by DeathFire
how do you make transparent blocks just like the ones in missile war?

Posted: Sat Jul 14, 2007 8:03 am
by ts
I'm suggesting you to read http://my.bzflag.org/w/ as it's pretty good. Look for the material property.

Posted: Sat Jul 14, 2007 8:04 am
by DeathFire
ts wrote:I'm suggesting you to read http://my.bzflag.org/w/ as it's pretty good. Look for the material property.
i searched for transparent and blocks but cant find anything

Posted: Sat Jul 14, 2007 12:31 pm
by the_j0k3r
The wiki has an index which if you follow, within 1 link you can find an index of everything you will need to make transparent blocks.

I found the required pages to learn this in about 2 minutes, so you could've just done it yourself, you don't have to ask about everything.

You need to know 2 things for a transparent box/wall - How to make a meshbox, how to apply a material to a meshbox. Its really not hard.

Use http://my.bzflag.org/w/Material as ts said to find out how to make a material, and use http://my.bzflag.org/w/Color%28BZW%29 to find out the use of the color property, so you can make the material a transparent one.

Then use http://my.bzflag.org/w/Meshbox to find out how to make a meshbox, and apply your transparent material to that meshbox.

Now you have a transparent block. And to think all that information was in the same index on the 'Map making' section of the wiki...

Posted: Sat Jul 14, 2007 12:33 pm
by DeathFire
the_j0k3r wrote:The wiki has an index which if you follow, within 1 link you can find an index of everything you will need to make transparent blocks.

I found the required pages to learn this in about 2 minutes, so you could've just done it yourself, you don't have to ask about everything.

You need to know 2 things for a transparent box/wall - How to make a meshbox, how to apply a material to a meshbox. Its really not hard.

Use http://my.bzflag.org/w/Material as ts said to find out how to make a material, and use http://my.bzflag.org/w/Color%28BZW%29 to find out the use of the color property, so you can make the material a transparent one.

Then use http://my.bzflag.org/w/Meshbox to find out how to make a meshbox, and apply your transparent material to that meshbox.

Now you have a transparent block. And to think all that information was in the same index on the 'Map making' section of the wiki...
sorry i forgot to say that i already found it sorry

Posted: Sun Jul 15, 2007 4:10 pm
by flight
i know you said you already found it, but if you want all around help on editing by hand, materials physics, and complex shapes and all that this is a great site!!! :P

http://my.bzflag.org/w/Editing_by_Hand

give that a good read and you'll learn a lot. or if you want to short cut you can just search for materials or what ever it is you want to read.

good luck.

Posted: Sun Jul 15, 2007 5:06 pm
by Ratatosk
i know how to make an invisible object.
all you have to do is put this material into your file

material
name (insert name here)
color 0 0 0 0
diffuse 0 0 0 0
end

now put a matref into any object that supports materials like a mesh, meshbox, meshpyr, cone, arc etc

like this
meshbox
size 1 2 3
position 1 2 3
matref (same name as material)
end

Posted: Sun Jul 15, 2007 5:30 pm
by CannonBallGuy
Murtagh wrote: color 0 0 0 0
diffuse 0 0 0 0
Those two lines do exactly the same thing. You don't need both.

Posted: Sun Jul 15, 2007 9:50 pm
by Ratatosk
still its the basic idea, its still a clear object

Posted: Sun Jul 15, 2007 11:24 pm
by joevano
Murtagh wrote:still its the basic idea, its still a clear object
He was just stating it for clarification, which is relevant when someone besides you is looking at it. You only need one or the other, and I had the question when looking at it as to why both were there. CBG clarified the question I was thinking, and he was sure others would have about your post, with the information he provided. We all agree that the block is transparent, just redundantly so.

Posted: Sun Jul 15, 2007 11:53 pm
by Ratatosk
i guess ill work on makeing everything easier for everyone else

Posted: Mon Aug 06, 2007 4:50 am
by optic delusion
Sorry missed this one last week..
If this is for the new glass map, this might be important.
It's better to use a transparent texture than a decimal alpha, if you are looking through multiple transparent blocks.
When you use alpha-transparency, the client draws all six sides of a block, and there is no occlusion. With one or two blocks, you won't notice it, but with if you are looking thru multiple transparent blocks, framerate drops signifigantly.

http://my.bzflag.org/bb/viewtopic.php?t ... ansparency

heres the textures I originally used to test with.
http://images.bzflag.org/pmatous/transparent/

Posted: Mon Aug 06, 2007 8:58 pm
by SkillDude
One question, I tried to make a transparent texture, and I used white and saved as a png image file, but I still saw the white. Do I have to use a program (I have Paint.NET and the GIMP) to set an alpha value for the white or something to make it transparent?

Posted: Mon Aug 06, 2007 9:48 pm
by CannonBallGuy
White is a colour, hence, not transparent.
Try creating a new image in GIMP. You can probably set the backgroud as transparent... Just don't add anything to the image.

Posted: Mon Aug 06, 2007 10:36 pm
by optic delusion