0 Favourites

Pick Two Different Animation Names in SAME event tree?

  • Pick only one:

    Pick Sprite where Sprite.AnimationName = "Boulder"

    --->For Each Sprite order by sprite.y ascending...

    blah blah

    it works.

    But if I want to pick two different objects in same event tree?

    Pick Sprite where Sprite.AnimationName = "Boulder"

    OR

    Pick Sprite where Sprite.AnimationName = "Diamond"

    will not work

    Pick Sprite where Sprite.AnimationName = "Boulder"

    Pick Sprite where Sprite.AnimationName = "Diamond"

    Not that either.

    Pick Sprite where (Sprite.AnimationName = "Boulder") | (Sprite.AnimationName = "Diamond")

    won't work either (only Boulder will work).

    Adding a sub event is not the solution as it will just try to search the "picked" boulders to find diamonds in them.

    Any solutions?

    Right now I have two event trees, first processing the Boulders and then the Diamonds, but I think the result is not optimal, it would be best if these 2 (animation names) are treated as one in same event tree.

    Any suggestions?

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
  • I don't know what your other events look like so this may not be a best solution.

    But it works anyway.

  • shinkan

    At first I got puzzled, I did try that, but then I realized I made it too convoluted by using System, Pick when it is enough with your method..

    It seems to be working now! Will go further on this one. Thanks.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)