Start delay of repeat fade in/out sequence

I found some code that repeats a fade in/fade out on 2 objects twice and then stays on the first object.

1st object:

$#DWE#>12?(100+(interpAccel(#DWE#,2,3,1)*100)):((cos((#DWE#/2+19)*2))*100+0)$

2nd object:

$#DWE#>12?0:((cos((#DWE#/2+8)*2))*100+0)$

Is it possible to delay the start of the fade in/out on both objects by 2 seconds so that the 1st object stays longer before the sequence starts? Right now the first object starts to fade out right away on wake.

Quick setup is here:

Any help is greatly appreciated…

1 Like

I hope some one can help . I can not untangle that quickly .

Yes, delays can be done with a condition #DWE#>2, but usually you want DWE to start at 0, so you have to subtract 2 within the formulas, otherwise you may see a jump.

Here is a sample of my little robot flying around. The animations are in sequence using DWE:

for fade in/out, you could use something like:
$#DWE#>=2&&#DWE#<5?(50*(sin(((#DWE#-2)*pi)))):100$

2 Likes

Nice one Tom. I think the ItnerpAccel complicates things unduly. Keep it simple. To have the Altenate lit just change sin for cos or vice versa.

1 Like

Hi Russel and Tom - thanks so much for the hints. Let me see if I can untangle this one!

2 Likes

Get back if you get stuck . There are plenty way to arrange these Bones . People have their own styles for doing stuff.

Hi Russel - thanks for getting back to me.

This somehow is a hard nut to crack. I tried nested statements - someting like:

1st object:
$#DWE#<=2?100:$$#DWE#>12?(100+(interpAccel(#DWE#,2,3,1)*100))?:((cos((#DWE#/2+19)*2))*100-0)$

2nd object:
$#DWE#<=2?0:$$#DWE#>12?0?:((cos((#DWE#/2+8)*2))*100+0)$

but this did not get me far…

1 Like

OK . is is easy to get in a pickle . This is getting very complex . As mentioned before I would dump the interpAccel .

So noting happens before 2 seconds are up . Then 1 and 2 cycle 2 twice and 1 three times for a duration of 2 seconds . Then 1 shows permanently after that ?

Hi Russel,

thanks for following up - please see details below:

Text 1 should show static for 2 seconds

Then Text 1 should fade out to Text 2 and start the 2 times going back & forth between Text 1/Text 2 cycle

After the last cycle is complete only Text 1 should stay static

Thanks again…

1 Like

OK is the 2 seconds cycle super critical .

Well, the static Text 1 at the beginning should just stay long enough to read a 4-5 digit number comfortably…

1 Like

I am working on it . Sin DWE is a strange beast .

Thanks Russel :wink: !

1 Like

Here is a test . But it is no better than what you did , The crossover is a bit of a mess . I would cut your losses and use 5 separate layers switching on and off with the conditionals.

Hi Russel - thanks for all your efforts and help! Yes, a ‘manual’ solution looks like the best fallback here…

1 Like

My Brain is not working very well today . Things are often easier if I have slept on it .

Hi Russel, yes - same here - sometimes it is good to put things away and then look at it again with fresh eyes and if a pinch of luck is combined with persistence a path oftentimes reveals itself…

1 Like

I have something on the Bench that is a bit neater .
But this is a good stand in for the time being . You can get on with the rest of the Face.
We could look at interpAccelDecel again . I think at the end of the day for our skills it is going to be more than a two line solution .

Thank you so much Russel - this is a great starting point and I think I can get fiddling with the interpAccel from here since this then is more or less a manual tweaking of the timings between the layers.

Thanks a zillion for always being helpful and insightful!

1 Like

@timeasart . If you are still there have a look at this . I have used cos as it is easier to see the Start of the cycle . Obviously we can tweak this but I wanted to keep it simple for now . I think by now you know what the bits are doing . It was important to me to get it synced with the Real Time Clock .
I know the time to the first complete dim is longer than you originally wanted . I should think we can change that .

1 Like