Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only. On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live. Read our full announcement for more information and let us know if you have any questions.

Question Can the animation control custom material property?

Discussion in 'Animation' started by suppertbw, Sep 15, 2023.

  1. suppertbw

    suppertbw

    Joined:
    Mar 16, 2016
    Posts:
    36
    I have a custom material property which is controlling a function turning on/off, so my shader is written like
    Code (CSharp):
    1.  
    2. [Toggle(Use thing)] _UseThing("Use Thing", Float) = 0
    3.  
    4. #pragma multi_compile _ _UseThing
    5.  
    Our artist try to use animation to control this property but failed, actually the function is never activated via the animation.

    So the animation can't control a custom material property?

    PS. for some reasons we don't want to use script to control it turning on/off