Search Unity

  1. Check out the Unite LA keynote for updates on the Visual Effect Editor, the FPS Sample, ECS, Unity for Film and more! Watch it now!
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Improved Prefab workflow (includes Nested Prefabs!), 2D isometric Tilemap and more! Get the 2018.3 Beta now.
    Dismiss Notice
  4. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice
  5. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Could we have blendtree switch by integer?

Discussion in 'Animation' started by Thaina, Sep 12, 2018.

  1. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    107
    While animation could take integer parameter, the blendtree could only take float value. I wish we could allow blendtree to take interger as switching, not blending, between multiple motion without creating state

    We could emulate by change interger parameter to float parameter and just let it blend the only one value. but I think I would like to have the value still be interger for other places

    Is it possible?
     
  2. sxnorthrop

    sxnorthrop

    Joined:
    Sep 29, 2014
    Posts:
    14
    That sounds kind of redundant. You can use the float as if it's an integer by only assigning integer values to it. Or maybe I'm misunderstanding the question.
     
  3. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    107
    @sxnorthrop It's the problem that we might have declare that parameter as integer from the start and use it as state for other statemachine and having other system read it as int. But when we want to use it as blendtree switch we need to change it to float everywhere

    It also possible to optimize the blendtree to not blend from multiple motion but just switch in these scenario