View Full Version : Color/Texture Change?
Advancebo
February 22nd, 2009, 04:10 PM
How do I achieve the effect in Halo 3, where on The Pit, you have the pop up brutes that change colors when you shoot at it, and turns back to normal when not being damaged?
How would I setup the tags to do so, like if its a shader or animation function.
MetKiller Joe
February 22nd, 2009, 04:15 PM
How do I achieve the effect in Halo 3, where on The Pit, you have the pop up brutes that change colors when you shoot at it, and turns back to normal when not being damaged?
How would I setup the tags to do so, like if its a shader or animation function.
I'd imagine you could script that when hit, this texture would change to another texture (something you could set as a shader property).
I'm almost sure it could be done, but I don't know how you'd script it.
teh lag
February 22nd, 2009, 04:29 PM
No, you don't use scripts. I don't understand why everyone thinks that scripts are like magical fairies that come down from the sky and make everyting possible.
First, set one of the export to functions in the tag at the very top to "recent shield damage" (I assume that you're using shields instead of health). It doesn't have to be "a in," that's just the one that I used.
http://img440.imageshack.us/img440/6023/tutpart1.jpg (http://imageshack.us)
Then, set up a function like the one below, ensuring that the "scale function by" is set to the same value that you had "recent shield damage" as. I won't get into what all the other values do, so unless you know what you're doing don't make them different from my screenshot.
http://img14.imageshack.us/img14/4493/tutpart2.jpg (http://imageshack.us)
Then, duplicate that function, but have the "inverse" flag checked off.
Then, create two shader transparents. One should have the default bitmaps, and the other should have another set of bitmaps that you want to be used when the object is damaged.
Set up the first (default) shader like so. Set the "framebuffer fade source" to the function that has "inverse" checked off. Note that "framebuffer fade mode" does not need to be set to anything; that's just how it is in my tag. Under "extra maps", reference the other (damaged) shader.
http://img3.imageshack.us/img3/8784/tutpart3.jpg (http://imageshack.us)
Now in the second shader, set "framebuffer fade source" to the original function (without "inverse" checked off).
http://img54.imageshack.us/img54/8675/tutpart4.jpg (http://imageshack.us)
That's it.
Advancebo
February 22nd, 2009, 04:59 PM
Thanks :D
It worked
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.