Dynamic Color question
- Sharpshooter
- Private First Class
- Posts: 181
- Joined: Tue Jun 07, 2005 1:48 am
- Location: CALIFORNIA
- Contact:
Dynamic Color question
I've never use dynamic color before, but I wanted to see if instead of a color changing into a different color, a texture could change into a different texture. I couldn't figure out how it could be possible, because the example on bzflag.org didn't have a spot to put a link to a texture. Does anyone know how t do this if it can be done?
Re: Dynamic Color question
Sharpshooter wrote:I've never use dynamic color before, but I wanted to see if instead of a color changing into a different color, a texture could change into a different texture. I couldn't figure out how it could be possible, because the example on bzflag.org didn't have a spot to put a link to a texture. Does anyone know how t do this if it can be done?
Ask LouMan, he is king of this stuff.
- optic delusion
- Special Forces
- Posts: 1054
- Joined: Sat Sep 25, 2004 2:29 pm
- Location: Planet MoFo
- Contact:
Sharps
SharpShooter was talking about textures, not colors.
I have looked at loumans burning tanks, and the butterflys, in louman's mystic valley. but I don't have any real advice for you.
The butterflys are one .png, that seems to rotate at times, giving the illusion of motion. It doesnt really change textures, but shows you different parts of the same texture, at different times.
look here http://trepan.bzflag.bz/tiles/
The moving, round transporter ring I have seen lately, might give you some clues too.
The smoke on the burning tanks is done in a different way. Much harder to do, it seems to me.
I think the answer to your question is in the butterflys somewhere... That one seems the easiest to do, at least.
Or look at the spinning globe, there's a gold mine of hints in there.
http://www.garrettsites.net/bzmaps/inde ... tail&id=96
I have looked at loumans burning tanks, and the butterflys, in louman's mystic valley. but I don't have any real advice for you.
The butterflys are one .png, that seems to rotate at times, giving the illusion of motion. It doesnt really change textures, but shows you different parts of the same texture, at different times.
look here http://trepan.bzflag.bz/tiles/
The moving, round transporter ring I have seen lately, might give you some clues too.
The smoke on the burning tanks is done in a different way. Much harder to do, it seems to me.
I think the answer to your question is in the butterflys somewhere... That one seems the easiest to do, at least.
Or look at the spinning globe, there's a gold mine of hints in there.
http://www.garrettsites.net/bzmaps/inde ... tail&id=96
Take a look at my Defender game mode concept.
Thinking is not an automatic process. A man can choose to think or to let his mind stagnate, or he can choose actively to turn against his intelligence, to evade his knowledge, to subvert his reason. If he refuses to think, he courts disaster: he cannot with impunity reject his means of perceiving reality.
Thinking is not an automatic process. A man can choose to think or to let his mind stagnate, or he can choose actively to turn against his intelligence, to evade his knowledge, to subvert his reason. If he refuses to think, he courts disaster: he cannot with impunity reject his means of perceiving reality.
- Sharpshooter
- Private First Class
- Posts: 181
- Joined: Tue Jun 07, 2005 1:48 am
- Location: CALIFORNIA
- Contact:
- optic delusion
- Special Forces
- Posts: 1054
- Joined: Sat Sep 25, 2004 2:29 pm
- Location: Planet MoFo
- Contact:
This is it.
an examples of a fading color in use, this goes red to black, to red......
first define the dynamic color,
then the actual material (you would define any texture here)
then use the material in your object (matref)
#dynamicColor for MOFO in the sky (creates the fading effect)
dynamicColor
name mofocol
red sinusoid 5 0 1
green limits 0 0
blue limits 0 0
alpha limits 1 1
end
#actual material for mofo in the sky
material
name mofomat
#addtexture http
diffuse 1 0 0 1
dyncol mofocol
end
#MOFO sky lettering mesh
mesh
name mofo
#vertices
# M
vertex -305 -100 150
vertex -325 -100 150
vertex -325 100 150
vertex -305 100 150
vertex -247.5 -100 150
vertex -267.5 -100 150
vertex -220 100 150
vertex -200 100 150
vertex -200 -100 150
vertex -220 -100 150
#M
face
vertices 0 1 2 3
matref mofomat
endface
face
vertices 2 3 4 5
matref mofomat
endface
face
vertices 4 5 6 7
matref mofomat
endface
face
vertices 6 7 8 9
matref mofomat
endface
#completely transparent material
material
name invisible
diffuse 0 0 0 0
end
first define the dynamic color,
then the actual material (you would define any texture here)
then use the material in your object (matref)
#dynamicColor for MOFO in the sky (creates the fading effect)
dynamicColor
name mofocol
red sinusoid 5 0 1
green limits 0 0
blue limits 0 0
alpha limits 1 1
end
#actual material for mofo in the sky
material
name mofomat
#addtexture http
diffuse 1 0 0 1
dyncol mofocol
end
#MOFO sky lettering mesh
mesh
name mofo
#vertices
# M
vertex -305 -100 150
vertex -325 -100 150
vertex -325 100 150
vertex -305 100 150
vertex -247.5 -100 150
vertex -267.5 -100 150
vertex -220 100 150
vertex -200 100 150
vertex -200 -100 150
vertex -220 -100 150
#M
face
vertices 0 1 2 3
matref mofomat
endface
face
vertices 2 3 4 5
matref mofomat
endface
face
vertices 4 5 6 7
matref mofomat
endface
face
vertices 6 7 8 9
matref mofomat
endface
#completely transparent material
material
name invisible
diffuse 0 0 0 0
end
Take a look at my Defender game mode concept.
Thinking is not an automatic process. A man can choose to think or to let his mind stagnate, or he can choose actively to turn against his intelligence, to evade his knowledge, to subvert his reason. If he refuses to think, he courts disaster: he cannot with impunity reject his means of perceiving reality.
Thinking is not an automatic process. A man can choose to think or to let his mind stagnate, or he can choose actively to turn against his intelligence, to evade his knowledge, to subvert his reason. If he refuses to think, he courts disaster: he cannot with impunity reject his means of perceiving reality.
- ClayOgre
- Private First Class
- Posts: 227
- Joined: Mon Apr 18, 2005 3:17 am
- Location: Southern Indiana (originally from Alaska)
This ties into an idea that I have had, but haven't had a chance to mess with. I was thinking that if you could create a custom texture with a lightning bolt with the colors carefully selected so you don't have a bunch of colors, but maybe just a couple (so it doesn't show except when your dynamic color statement tells it to). The lightning bolt would be on a transparent or black background and the colors set to rotate very fast, so the lightning bolt would appear to flash rapidly.
This effect could be used at the edge of maps on large mesh screens or even in the middle of a map. I am not sure, but it would be really cool if you could tie the color effect to the timed firing of a world weapon. The lightning would strike, and say, a shockwave would go off, or perhaps a burst of standard tank rounds contained in an inside out box with it's attributes set to drivethrough and with no texture or color. You can drive through the thing like it ain't there, you can't see it...but when the lightning goes off and the world weapon fires and the tank round bounces around on the inverted walls...look out!
This effect could be used at the edge of maps on large mesh screens or even in the middle of a map. I am not sure, but it would be really cool if you could tie the color effect to the timed firing of a world weapon. The lightning would strike, and say, a shockwave would go off, or perhaps a burst of standard tank rounds contained in an inside out box with it's attributes set to drivethrough and with no texture or color. You can drive through the thing like it ain't there, you can't see it...but when the lightning goes off and the world weapon fires and the tank round bounces around on the inverted walls...look out!
Respectfully,
I Beg to Remain,
Cordially Yours,
Regards....
I Beg to Remain,
Cordially Yours,
Regards....