I'm working on a Plymouth splash for Kubuntu. I want it to consist of a sprite centered on the screen that rotates. But no matter what I do the sprite doesn't rotate. Here's one version of the script I tested:
Code:
spiral_image = Image("Splash.png");
spiral_sprite = Sprite(spiral_image);
spiral_sprite.SetX(Window.GetWidth() /2 - spiral_image.GetWidth() /2);
spiral_sprite.SetY(WIndow.GetHeight() /2 - spiral_image.GetHeight() /2);
time = 0;
fun refresh_callback ()
{
time++;
theta = time / 100;
spiral_sprite.Rotate(Math.Sin(theta) * 200);
}
Plymouth.SetRefreshFunction (refresh_callback);
I don't know what I'm doing wrong here.