# Example code by the developer
void PlayRepeatingAnimation() {
if (!_Animation.IsActive()) {
_Animation = transform.DOLocalMoveY(2, 0.5f)
.SetLoops(-1, LoopType.Yoyo);
}
}
IEnumerator StopAtInitialPosCoroutine() {
int completedLoops = _Animation.CompletedLoops();
int loopsTilInitialPos = completedLoops % 2 == 0 ? 2 : 1;
yield return _Animation.WaitForElapsedLoops(
completedLoops + loopsTilInitialPos
);
_Animation.Kill();
}
# Example code by the developer
[SerializeField] TweenAnimation _jumpAnimation =
new TweenAnimation {
cycles = -1,
animations = new List<TweenAnimation.Data> {
new TweenAnimation.Data {
tweenType = TweenAnimation.TweenType.LocalPositionY,
duration = 0.5f,
cycles = 2,
cycleMode = CycleMode.Rewind
}
}
};
void Update() {
if (Input.GetKeyDown(KeyCode.A)) {
_jumpAnimation.state = true;
}
if (Input.GetKeyDown(KeyCode.D)) {
_jumpAnimation.state = false;
}
}
Interesting fact: Most of the technical artists hired in the game industry know Python, C# (or C++) and HLSL. 👀
— Jettelly Inc. (@jettelly) December 5, 2025
And The Unity Shaders Bible can definitely help you get there. ✨
🔗 https://t.co/fw4pna2vUj#gamedev #unity3d #madewithunity #indiedev pic.twitter.com/nnMiBdXhJm