90 lines
3.9 KiB
HTML
90 lines
3.9 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="authoring-tool" content="Adobe_Animate_CC">
|
|
<title>speedboard</title>
|
|
<link href="/shells/tennis_wtt_2020_speedboard/assets/fonts.css" rel="stylesheet" type="text/css">
|
|
<div class="font_preload" style="opacity: 0">
|
|
<span style="font-family: 'Sharp Sans Display No1 Bold'"></span>
|
|
<span style="font-family: 'Sharp Sans Display No1 Medium'"></span>
|
|
<span style="font-family: 'Sharp Sans Display No1 Semi-Bold'"></span>
|
|
</div>
|
|
<script src='/shells/createjs/createjs-2018.03.15-V2.combined.js'></script>
|
|
<!-- write your code here -->
|
|
<script src="speedboard.js"></script>
|
|
<script>
|
|
// Global Scripts
|
|
var currentTimestamp = 0;
|
|
function KPHtoMPH(ms) {
|
|
return Math.floor(Number(ms || 0) * 0.62);
|
|
}
|
|
//const EasingFunctions = {
|
|
// // no easing, no acceleration
|
|
// linear: function (t) { return t },
|
|
// // accelerating from zero velocity
|
|
// easeInQuad: function (t) { return t*t },
|
|
// // decelerating to zero velocity
|
|
// easeOutQuad: function (t) { return t*(2-t) },
|
|
// // acceleration until halfway, then deceleration
|
|
// easeInOutQuad: function (t) { return t<.5 ? 2*t*t : -1+(4-2*t)*t },
|
|
// // accelerating from zero velocity
|
|
// easeInCubic: function (t) { return t*t*t },
|
|
// // decelerating to zero velocity
|
|
// easeOutCubic: function (t) { return (--t)*t*t+1 },
|
|
// // acceleration until halfway, then deceleration
|
|
// easeInOutCubic: function (t) { return t<.5 ? 4*t*t*t : (t-1)*(2*t-2)*(2*t-2)+1 },
|
|
// // accelerating from zero velocity
|
|
// easeInQuart: function (t) { return t*t*t*t },
|
|
// // decelerating to zero velocity
|
|
// easeOutQuart: function (t) { return 1-(--t)*t*t*t },
|
|
// // acceleration until halfway, then deceleration
|
|
// easeInOutQuart: function (t) { return t<.5 ? 8*t*t*t*t : 1-8*(--t)*t*t*t },
|
|
// // accelerating from zero velocity
|
|
// easeInQuint: function (t) { return t*t*t*t*t },
|
|
// // decelerating to zero velocity
|
|
// easeOutQuint: function (t) { return 1+(--t)*t*t*t*t },
|
|
// // acceleration until halfway, then deceleration
|
|
// easeInOutQuint: function (t) { return t<.5 ? 16*t*t*t*t*t : 1+16*(--t)*t*t*t*t }
|
|
//}</script>
|
|
<script>
|
|
var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation, loader_handle;
|
|
function init() {
|
|
canvas = document.getElementById("canvas");
|
|
anim_container = document.getElementById("animation_container");
|
|
dom_overlay_container = document.getElementById("dom_overlay_container");
|
|
var comp=AdobeAn.getComposition("36D6E8BDDCB50B4D9681420AF6CA779E");
|
|
var lib=comp.getLibrary();
|
|
handleComplete({},comp);
|
|
if(typeof loader != "undefined") loader_handle = loader;
|
|
}
|
|
function handleComplete(evt,comp) {
|
|
//This function is always called, irrespective of the content. You can use the variable "stage" after it is created in token create_stage.
|
|
var lib=comp.getLibrary();
|
|
var ss=comp.getSpriteSheet();
|
|
exportRoot = new lib.speedboard();
|
|
stage = new lib.Stage(canvas);
|
|
//Registers the "tick" event listener.
|
|
fnStartAnimation = function() {
|
|
stage.addChild(exportRoot);
|
|
createjs.Ticker.framerate = lib.properties.fps;
|
|
createjs.Ticker.addEventListener("tick", stage);
|
|
}
|
|
//Code to support hidpi screens and responsive scaling.
|
|
AdobeAn.makeResponsive(false,'both',false,1,[canvas,anim_container,dom_overlay_container]);
|
|
AdobeAn.compositionLoaded(lib.properties.id);
|
|
fnStartAnimation();
|
|
}
|
|
</script>
|
|
<!-- write your code here -->
|
|
<script src="/lib/SMARTGraphicsLinkAnimate.js"></script>
|
|
<script src="/shells/createjs/linefix.js"></script>
|
|
</head>
|
|
<body onload="init();" style="margin:0px;">
|
|
<div id="animation_container" style="background-color:rgba(50, 50, 50, 0.00); width:1920px; height:1080px">
|
|
<canvas id="canvas" width="1920" height="1080" style="position: absolute; display: block; background-color:rgba(50, 50, 50, 0.00);"></canvas>
|
|
<div id="dom_overlay_container" style="pointer-events:none; overflow:hidden; width:1920px; height:1080px; position: absolute; left: 0px; top: 0px; display: block;">
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html> |