Explorar o código

[ts] center loading screen logo + spinner

badlogic %!s(int64=9) %!d(string=hai) anos
pai
achega
99a5f43aca

+ 3 - 3
spine-ts/build/spine-all.js

@@ -5340,7 +5340,7 @@ var spine;
             }
             LoadingScreen.prototype.draw = function () {
                 this.timeKeeper.update();
-                this.angle += this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
+                this.angle -= this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
                 var renderer = this.renderer;
                 var canvas = renderer.canvas;
                 var gl = renderer.gl;
@@ -5365,8 +5365,8 @@ var spine;
                 var margin = 15;
                 var height = logoHeight + margin + spinnerHeight;
                 renderer.begin();
-                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + margin / 2, logoWidth, logoHeight);
-                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - margin / 2 - spinnerHeight, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
+                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + height / 2 - logoHeight, logoWidth, logoHeight);
+                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - height / 2, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
                 renderer.end();
             };
             LoadingScreen.loaded = 0;

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
spine-ts/build/spine-all.js.map


+ 3 - 3
spine-ts/build/spine-webgl.js

@@ -4917,7 +4917,7 @@ var spine;
             }
             LoadingScreen.prototype.draw = function () {
                 this.timeKeeper.update();
-                this.angle += this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
+                this.angle -= this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
                 var renderer = this.renderer;
                 var canvas = renderer.canvas;
                 var gl = renderer.gl;
@@ -4942,8 +4942,8 @@ var spine;
                 var margin = 15;
                 var height = logoHeight + margin + spinnerHeight;
                 renderer.begin();
-                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + margin / 2, logoWidth, logoHeight);
-                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - margin / 2 - spinnerHeight, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
+                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + height / 2 - logoHeight, logoWidth, logoHeight);
+                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - height / 2, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
                 renderer.end();
             };
             LoadingScreen.loaded = 0;

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
spine-ts/build/spine-webgl.js.map


+ 3 - 3
spine-ts/build/spine-widget.js

@@ -4917,7 +4917,7 @@ var spine;
             }
             LoadingScreen.prototype.draw = function () {
                 this.timeKeeper.update();
-                this.angle += this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
+                this.angle -= this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
                 var renderer = this.renderer;
                 var canvas = renderer.canvas;
                 var gl = renderer.gl;
@@ -4942,8 +4942,8 @@ var spine;
                 var margin = 15;
                 var height = logoHeight + margin + spinnerHeight;
                 renderer.begin();
-                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + margin / 2, logoWidth, logoHeight);
-                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - margin / 2 - spinnerHeight, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
+                renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + height / 2 - logoHeight, logoWidth, logoHeight);
+                renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - height / 2, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
                 renderer.end();
             };
             LoadingScreen.loaded = 0;

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
spine-ts/build/spine-widget.js.map


+ 3 - 3
spine-ts/webgl/src/LoadingScreen.ts

@@ -43,7 +43,7 @@ module spine.webgl {
 
 		draw () {			
 			this.timeKeeper.update();
-			this.angle += this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
+			this.angle -= this.timeKeeper.delta * 360 * (0.5 + 2 * Math.abs(Math.sin(this.timeKeeper.totalTime)));
 
 			var renderer = this.renderer;
 			var canvas = renderer.canvas;
@@ -73,8 +73,8 @@ module spine.webgl {
 			var height = logoHeight + margin + spinnerHeight;			
 
 			renderer.begin();
-			renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + margin / 2, logoWidth, logoHeight);			
-			renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - margin / 2 - spinnerHeight, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
+			renderer.drawTexture(this.logo, canvas.width / 2 - logoWidth / 2, canvas.height / 2 + height / 2 - logoHeight, logoWidth, logoHeight);			
+			renderer.drawTextureRotated(this.spinner, canvas.width / 2 - spinnerWidth / 2, canvas.height / 2 - height / 2, spinnerWidth, spinnerHeight, spinnerWidth / 2, spinnerHeight / 2, this.angle);
 			renderer.end();
 		}
 	}

Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio