1. Help us improve the editor usability and artist workflows. Join our discussion to provide your feedback.
    Dismiss Notice
  2. We're looking for feedback on Unity Starter Kits! Let us know what you’d like.
    Dismiss Notice
  3. We’re giving 2017.1 beta testers a chance to win t-shirts and a Nintendo Switch. Read more on the blog.
    Dismiss Notice
  4. We want to know how you learned Unity! Help us by taking this quick survey and have a chance at a $25 gift card
    Dismiss Notice
  5. Are you an artist or level designer going to Unite Europe? Join our roundtables there to discuss artist features.
    Dismiss Notice
  6. Unity 5.6 is now released.
    Dismiss Notice
  7. Check out all the fixes for 5.6 on the patch releases page.
    Dismiss Notice

Dynamic color change in visual effects/particles

Discussion in 'Animation' started by mcredifine, Jun 19, 2017.

  1. mcredifine


    Jun 19, 2017
    Can anyone provide a short tutorial on how to develop those dynamic functionalities in the top left corner of the screen as seen in this video?

    Is that a script that lets you modify the color on the go or does Unity already has something like this implemented and that I don't know about?

    Thank you!
  2. Krucho


    Jul 23, 2014
    He uses a handmade custom script for this UI yes.

    Looking at his effects he uses Glow and Dissolve shaders a lot, so his script simply updates the effect color parameter of those shaders.
    You can see at 8:55 the lightning color starts purple and ends pink, and he doesn't tweak the color for some reason (which is very strange because if there is one thing that looks awesome in any color it is lightning). Thats because his shaders use a gradient map (purple => pink) instead of a single color for this effect. So his tool simply doesn't work on this effect, which is why he didn't show it in different colors.

    The recolor script has to adapted to the kind of effects you have, it is not a "1 solution for everything" kind of thing, for example he could have had an option to change the white of all those effects into black and it would have looked awesome too, really depends on what you have and what you want.
    Last edited: Jun 20, 2017 at 8:02 PM