method
Tween.number
Tween.number(from, to, t) -> fixed
Interpolates two fixed values: from + (to - from) * t. Feed it an eased t from Tween.ease to tween any fractional quantity — an alpha, a scale, a fixed-point position.
Parameters
fromthe value at t = 0 (a fixed)tothe value at t = 1 (a fixed)tthe blend amount (a fixed, usually 0..1)Example
program Demo {
handler Run phase Update {
let t = Tween.progress(fixed(1), fixed(2))
let scale = Tween.number(fixed(1), fixed(2), Tween.ease(t, 2))
print(scale)
}
}