Тухайн position-д харгалзах sprite sheet дэх index
int indexAt(Duration position) { return position.inSeconds ~/ intervalSec; }