From a10f053e32a5ae070f87624e38d7b73f6e837946 Mon Sep 17 00:00:00 2001 From: Lennart Hase Date: Fri, 27 Mar 2020 23:46:57 +0000 Subject: [PATCH 1/2] Including Window Origin in centering animation --- pack_1/cuts_alt/cuts_alt.script | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pack_1/cuts_alt/cuts_alt.script b/pack_1/cuts_alt/cuts_alt.script index 6436a9dc..44ebe3ec 100755 --- a/pack_1/cuts_alt/cuts_alt.script +++ b/pack_1/cuts_alt/cuts_alt.script @@ -12,8 +12,8 @@ for (i = 0; i < 41; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 41]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); From ef4a5f28b5cd9db0ba36024f6204aa8998ea57e3 Mon Sep 17 00:00:00 2001 From: Lennart Hase Date: Fri, 27 Mar 2020 23:49:53 +0000 Subject: [PATCH 2/2] Added fix to other animations --- pack_1/abstract_ring/abstract_ring.script | 6 +++--- pack_1/abstract_ring_alt/abstract_ring_alt.script | 6 +++--- pack_1/alienware/alienware.script | 6 +++--- pack_1/angular/angular.script | 6 +++--- pack_1/angular_alt/angular_alt.script | 6 +++--- pack_1/black_hud/black_hud.script | 7 +++---- pack_1/blockchain/blockchain.script | 6 +++--- pack_1/circle/circle.script | 6 +++--- pack_1/circle_alt/circle_alt.script | 6 +++--- pack_1/circle_flow/circle_flow.script | 6 +++--- pack_1/circle_hud/circle_hud.script | 6 +++--- pack_1/circuit/circuit.script | 6 +++--- pack_1/colorful/colorful.script | 6 +++--- pack_1/colorful_loop/colorful_loop.script | 6 +++--- pack_1/colorful_sliced/colorful_sliced.script | 6 +++--- pack_1/connect/connect.script | 6 +++--- pack_1/cross_hud/cross_hud.script | 6 +++--- pack_1/cubes/cubes.script | 6 +++--- pack_1/cuts/cuts.script | 4 ++-- template/template.script | 6 +++--- 20 files changed, 59 insertions(+), 60 deletions(-) diff --git a/pack_1/abstract_ring/abstract_ring.script b/pack_1/abstract_ring/abstract_ring.script index 6436a9dc..44ebe3ec 100755 --- a/pack_1/abstract_ring/abstract_ring.script +++ b/pack_1/abstract_ring/abstract_ring.script @@ -12,8 +12,8 @@ for (i = 0; i < 41; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 41]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/abstract_ring_alt/abstract_ring_alt.script b/pack_1/abstract_ring_alt/abstract_ring_alt.script index 8991c5ec..57292865 100755 --- a/pack_1/abstract_ring_alt/abstract_ring_alt.script +++ b/pack_1/abstract_ring_alt/abstract_ring_alt.script @@ -12,8 +12,8 @@ for (i = 0; i < 76; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 76]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/alienware/alienware.script b/pack_1/alienware/alienware.script index fe1e1537..92c9d186 100755 --- a/pack_1/alienware/alienware.script +++ b/pack_1/alienware/alienware.script @@ -12,8 +12,8 @@ for (i = 0; i < 24; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 3) % 24]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/angular/angular.script b/pack_1/angular/angular.script index a67df0aa..7216d282 100755 --- a/pack_1/angular/angular.script +++ b/pack_1/angular/angular.script @@ -12,8 +12,8 @@ for (i = 0; i < 30; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 30]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/angular_alt/angular_alt.script b/pack_1/angular_alt/angular_alt.script index 16456bf6..ce6f5ea3 100755 --- a/pack_1/angular_alt/angular_alt.script +++ b/pack_1/angular_alt/angular_alt.script @@ -12,8 +12,8 @@ for (i = 0; i < 61; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 61]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/black_hud/black_hud.script b/pack_1/black_hud/black_hud.script index 91d9d2fb..991f9b98 100755 --- a/pack_1/black_hud/black_hud.script +++ b/pack_1/black_hud/black_hud.script @@ -12,9 +12,8 @@ for (i = 0; i < 164; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); - +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; fun refresh_callback () @@ -22,5 +21,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 164]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/blockchain/blockchain.script b/pack_1/blockchain/blockchain.script index 6fee3b98..89ee9d57 100755 --- a/pack_1/blockchain/blockchain.script +++ b/pack_1/blockchain/blockchain.script @@ -12,8 +12,8 @@ for (i = 0; i < 68; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 68]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/circle/circle.script b/pack_1/circle/circle.script index 94099da5..dd0c7568 100755 --- a/pack_1/circle/circle.script +++ b/pack_1/circle/circle.script @@ -12,8 +12,8 @@ for (i = 0; i < 101; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 101]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/circle_alt/circle_alt.script b/pack_1/circle_alt/circle_alt.script index ea3c54ea..801839a5 100755 --- a/pack_1/circle_alt/circle_alt.script +++ b/pack_1/circle_alt/circle_alt.script @@ -12,8 +12,8 @@ for (i = 0; i < 48; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 48]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/circle_flow/circle_flow.script b/pack_1/circle_flow/circle_flow.script index d704f62f..4132a972 100755 --- a/pack_1/circle_flow/circle_flow.script +++ b/pack_1/circle_flow/circle_flow.script @@ -12,8 +12,8 @@ for (i = 0; i < 72; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 72]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/circle_hud/circle_hud.script b/pack_1/circle_hud/circle_hud.script index ed84253c..2ac1d010 100755 --- a/pack_1/circle_hud/circle_hud.script +++ b/pack_1/circle_hud/circle_hud.script @@ -12,8 +12,8 @@ for (i = 0; i < 156; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 156]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/circuit/circuit.script b/pack_1/circuit/circuit.script index adb0473f..5c807b90 100755 --- a/pack_1/circuit/circuit.script +++ b/pack_1/circuit/circuit.script @@ -12,8 +12,8 @@ for (i = 0; i < 96; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 96]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/colorful/colorful.script b/pack_1/colorful/colorful.script index 879fa67d..71480c8f 100755 --- a/pack_1/colorful/colorful.script +++ b/pack_1/colorful/colorful.script @@ -12,8 +12,8 @@ for (i = 0; i < 375; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 375]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/colorful_loop/colorful_loop.script b/pack_1/colorful_loop/colorful_loop.script index 25ae39b4..28f7426b 100755 --- a/pack_1/colorful_loop/colorful_loop.script +++ b/pack_1/colorful_loop/colorful_loop.script @@ -12,8 +12,8 @@ for (i = 0; i < 89; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 89]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/colorful_sliced/colorful_sliced.script b/pack_1/colorful_sliced/colorful_sliced.script index 67297926..e8c066d6 100755 --- a/pack_1/colorful_sliced/colorful_sliced.script +++ b/pack_1/colorful_sliced/colorful_sliced.script @@ -12,8 +12,8 @@ for (i = 0; i < 120; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 120]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/connect/connect.script b/pack_1/connect/connect.script index 67297926..e8c066d6 100755 --- a/pack_1/connect/connect.script +++ b/pack_1/connect/connect.script @@ -12,8 +12,8 @@ for (i = 0; i < 120; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 120]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/cross_hud/cross_hud.script b/pack_1/cross_hud/cross_hud.script index 2c7f1764..326f8c13 100755 --- a/pack_1/cross_hud/cross_hud.script +++ b/pack_1/cross_hud/cross_hud.script @@ -12,8 +12,8 @@ for (i = 0; i < 210; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 210]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/cubes/cubes.script b/pack_1/cubes/cubes.script index f075d7cf..fc2d14df 100755 --- a/pack_1/cubes/cubes.script +++ b/pack_1/cubes/cubes.script @@ -12,8 +12,8 @@ for (i = 0; i < 81; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / 2) % 81]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback); diff --git a/pack_1/cuts/cuts.script b/pack_1/cuts/cuts.script index a9f47cec..cce0413f 100755 --- a/pack_1/cuts/cuts.script +++ b/pack_1/cuts/cuts.script @@ -12,8 +12,8 @@ for (i = 0; i < 62; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; diff --git a/template/template.script b/template/template.script index 4caee3ba..4ea6c828 100755 --- a/template/template.script +++ b/template/template.script @@ -12,8 +12,8 @@ for (i = 0; i < NUM; i++) flyingman_sprite = Sprite(); # set image position -flyingman_sprite.SetX(Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2); # Place images in the center -flyingman_sprite.SetY(Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2); +flyingman_sprite.SetX(Window.GetX() + (Window.GetWidth() / 2 - flyingman_image[0].GetWidth() / 2)); # Place images in the center +flyingman_sprite.SetY(Window.GetY() + (Window.GetHeight() / 2 - flyingman_image[0].GetHeight() / 2)); progress = 0; @@ -22,5 +22,5 @@ fun refresh_callback () flyingman_sprite.SetImage(flyingman_image[Math.Int(progress / SPEED) % NUM]); progress++; } - + Plymouth.SetRefreshFunction (refresh_callback);