senatorjimdeath Posted February 26, 2010 Share Posted February 26, 2010 Hi folks, I think I may already know the answer to this, but I'm hoping someone knows some kind of workaround. I'm trying to shift between several EffectShaders via scripts, but doing this smoothly is very tough because of the "fade" that happens when you stop an effect shader. What happens is that the shader you want to stop shows up on the mesh, fades, and then the new shader pops back into place. What I would like is for the new shader to seamlessly replace the old one. Getting new shaders to start instantly hasn't been a problem, but handling the old ones fading out has been. For instance, if I do: target.PMS level1 and then some frames later do target.PMS level2 The shader "order" doesn't seem to be correct. It appears to work at first: level1 is instantly replaced with level2. But at some point (I think it may be when another unrelated shader plays) the level1 shader replaces the level2 shader. It's like the "stack" of shaders gets messed up. If more than one shader is playing on a mesh without a duration, do they go into some kind of stack and keep playing, even though only one can display? If instead I try for the later block: target.SMS level1target.PMS level2 I get the fading issue I discussed above, where level1 has to fade out before level2 displays correctly. I'm trying to get at weird or unintuitive behavior that these shaders might have: ways, basically, to avoid or get around the fade-out of a stopped shader. As I said, I'm unsure if this is something I'll just have to tolerate. Ideally, I'd have multiple separate shaders blending, but I don't think that's possible. Link to comment Share on other sites More sharing options...
Recommended Posts