How to dissolve an object?

I want to gradually dissolve an object (i.e. make it disappear) over say 5 seconds.

I was expecting to find under Transform > Transition a CoBlock for opacity. But I can’t seem to find this.

How should I dissolve an object? Thank you.

Hi @cindy,

to make a dissolve-like-effect you can do the following in CoBlocks:


1.We create a transparency variable and set its value to 100 (for 100% opacity).
2. Then, in forever-loop, we subtract 1 from this value every step and set the item’s transparency to the new value
3. At the end we check if transparency is equal to 0 (meaning: the item faded out). If the item is faded out completely, we break out of the loop to stop it from executing.

Here's the code in action!

Hope this helps!

1 Like

Thanks for your prompt reply.

Does “set opacity” not work for text? I am trying what you suggested but for some text, but the text doesn’t go away.

Hi @cindy,

text items and image-items don’t have opacity yet. If you want to hide a text-item without deleting it, you can set its text to be empty with the set Text - block.

Do you have any suggestions on how I can dissolve a text-item?

A “dissolve” or “fading out” effect is not easy to achieve on the text item or image items now, because they do not have transparency. Do you have an example in which this effect is needed?