-
Time remap control by a drop menu?
Hi every one! I’m stuck in a huge project. A have a bunch of precomps that will be time remapped to play different loop at different time. To avoid copy pasting keyframes, i would like to keyframe a drop menu that will loop different part of the animation. I dont know if i’m clear, but i ask chat gpt but i’m the comp stuck at 0 or play the comp normaly.
// Define the dropdown menu effect
menuEffect = effect(“Timeremap_Ctrl”)(“Menu”);
// Define the time remap ranges
ranges = {
“01”: [0, 14],
“02”: [15, 44],
“03”: [45, 104],
“04”: [105, 174],
“05”: [175, 235]
};
// Get the selected menu option
selectedOption = menuEffect.value;
// Initialize the output time remap value
outputTimeRemap = 0;
// Check the selected menu option and set the output time remap value
if (selectedOption in ranges) {
selectedRange = ranges[selectedOption];
outputTimeRemap = linear(time, selectedRange[0], selectedRange[1], 0, thisComp.duration);
}
outputTimeRemap;