I'm struggling with something really simple... I have buttons that appear on hover with a crop (from left to right), and I want them to disappear from left to right too. The effect I want looks like a swoosh or how a trail appears then disappears from a shooting star.
Problem is, I can't get my head around doing this. I've tried adding "-" to the crop numbers and adjusting them all kinds of ways, but I can't get it to behave how I want. The numbers are set up to show the cropped image, not the empty space they leave behind. I don't think there's an inverse crop, but maybe there's another way I can achieve this effect?
Here's my current code. On show works, but on hide doesn't no matter what numbers I try:
Code: Select all
transform choicehover: on show: crop_relative True alpha 0 crop (0,0, 0.0, 1.0) linear 0.15 crop (0,0, 0.3, 1.0) linear 0.25 alpha 1.0 crop(0,0, 1.0, 1.0 ) on hide: crop_relative True alpha 1.0 crop (0,0, 1.0, 1.0) linear 0.25 crop (0,0, 0.6, 1.0) linear 0.15 alpha 0.0 crop(0,0, 0.0, 1.0 )