Can someone link me to an extension that changes the colors of an active ocject based on what the player picks. Example: Player picks red, block is red. Player picks blue, block turns blue. The block also has multiple animations that also turn blue in those.
I take it his point is to not have separate actives, and saving space, also it saves a lot of time. I don't understand what people have against extensions, unless you're doing a flash runtime, you shouldn't worry about it.
There was a thread about this not too long ago where I gave an answer to this question, although it wasn't the best, I don't think anyone else answered the question, and my answer still used a separate active, albeit would save from having several different actives for simple color changes.
/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/-=?=-/
That Really Hot Chick
now on the Xbox Live Marketplace!
MMF's color replacer changes any instance of any color in the whole active object with one line. Every animation in that active in one fell swoop. The only thing I've noticed is a SLIGHT half second lag when it first changes the color, and then you're all set for the rest of the time your guy (or whatever) is on that frame.
What you could do is make a group of events at the start of each frame / game level / what have you and tie it to a global like this:
Start of Frame
+If (global value BLOCKCOLOR) = 1 then Replace color (whichever of active object "block") to (red)
Start of Frame
+If (global value BLOCKCOLOR) = 2 then Replace color (whichever of active object "block") to (blue)
Start of Frame
+If (global value BLOCKCOLOR) = 3 then Replace color (whichever of active object "block") to (green)
This way whenever the frame loaded it'd change your block to whichever current color it's supposed to be. Just remember that if you pick up the color changer during the level you'd need to do a ONE TIME ONLY color change or else it'll keep replacing the color and it'll be as slow as shit. I usually use a flag in that case and set it to ON once the color is change mid-frame.
--
"Del Duio has received 0 trophies. Click here to see them all."
"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"
DXF Games, coming next: Hasslevania 2- This Space for Rent!