Multiple conditionals possible?

I found some years old threads discussing this but nothing recent. Apparently a couple of years ago this was not possible in Facer, maybe now it is? Is there a Facer equivalent of something like this?:

{dh23} < 1 and 0 or {dh23} >12 and 0 or 100

Basically this means from 1-12 opacity is 0 else 100.

Thanks!

$#Ds#>=1&&#Ds#<12?0:100$
1 Like

@lucky.andrei

Thanks! great to get a quick reply so I can keep the project going!

This is what I ended up with modifying your script to get what I needed:

$#DH#>=0&&#DH#<12?100:0$

Just be aware that “complicated” conditional expressions are still bugy on Facer, and don’t always work as expected on WearOS watches although it does work in Creator and on Tizen.

I suspect what you have now for this use case should be OK, but can’t be sure…

If I don’t have a choice because this is the task, I’d rather do it than do nothing. And let the Facer improve further :wink:

this one seems to be working perfectly on the watch :slight_smile:

3 Likes

The other option when multiple conditions don’t want to work, is to either use more layers or to spread the conditions over multiple fields, e.g. the opacity field can be used with one condition to display a layer or not as well as the x & y positions; just move the layer off screen with x or y or both when it should not display.

Of course it does depend on the required effect you want to achieve. May not always be possible.

1 Like