fix(docs/hold-tap/balanced): Make balanced animations release before tapping-term-ms

This commit is contained in:
Kurtis Lew 2023-02-10 13:44:37 -08:00 committed by Kurtis Lew
parent b14de70f79
commit 9cef93af19
2 changed files with 11 additions and 9 deletions

View file

@ -26,17 +26,17 @@ export default makeScene2D(function* (view) {
yield* waitFor(0.5); yield* waitFor(0.5);
yield* any( yield* any(
hold.body.position.y(KeyTravel, 0.15), hold.body.position.y(KeyTravel, 0.15),
hold.duration.grow(1, 2, linear) hold.duration.grow(0.5, 1, linear)
); );
yield* delay( yield* delay(
1.2, 0.35,
all( all(
interrupt.body.position.y(KeyTravel, 0.15), interrupt.body.position.y(KeyTravel, 0.15),
hold.duration.fill("F21D00", 0.15) hold.duration.fill("F21D00", 0.15)
) )
); );
yield* delay( yield* delay(
1.5, 0.35,
chain( chain(
hold.body.position.y(0, 0.15), hold.body.position.y(0, 0.15),
hold.group.rotation(3, 0.03), hold.group.rotation(3, 0.03),
@ -49,4 +49,5 @@ export default makeScene2D(function* (view) {
); );
yield* waitFor(0.25); yield* waitFor(0.25);
yield* interrupt.body.position.y(0, 0.15); yield* interrupt.body.position.y(0, 0.15);
yield* waitFor(1);
}); });

View file

@ -26,29 +26,30 @@ export default makeScene2D(function* (view) {
yield* waitFor(0.5); yield* waitFor(0.5);
yield* any( yield* any(
hold.body.position.y(KeyTravel, 0.15), hold.body.position.y(KeyTravel, 0.15),
hold.duration.grow(1, 2, linear) hold.duration.grow(0.5, 1, linear)
); );
yield* delay( yield* delay(
1.2, 0.35,
all( all(
interrupt.body.position.y(KeyTravel, 0.15), interrupt.body.position.y(KeyTravel, 0.15),
hold.duration.fill("F21D00", 0.15) hold.duration.fill("F21D00", 0.15)
) )
); );
yield* delay( yield* delay(
1.5, 0.35,
chain( chain(
interrupt.body.position.y(0, 0.15), interrupt.body.position.y(0, 0.15),
hold.group.rotation(3, 0.03), hold.group.rotation(3, 0.03),
hold.group.rotation(-3, 0.06), hold.group.rotation(-3, 0.06),
hold.group.rotation(0, 0.03), hold.group.rotation(0, 0.03),
hold.duration.grow(0, 0.15),
all( all(
delay(0.15, hold_output.output.text("J", 0)), delay(0.05, hold_output.output.text("J", 0)),
hold_output.shift.fill("#969696", 0.15) hold_output.shift.fill("#969696", 0.1)
) )
) )
); );
yield* waitFor(0.25); yield* waitFor(0.25);
yield* hold.body.position.y(0, 0.15); yield* hold.body.position.y(0, 0.15);
yield* delay(0.5, hold.duration.grow(0, 0.15)); yield* waitFor(1);
}); });