Quantcast
Channel: Adobe Community : All Content - Adobe Animate CC - General
Viewing all articles
Browse latest Browse all 13519

Two animations on the same page html5 - toolkit for createjs

$
0
0

Hello, I'm trying to do two animations on the same page and I can not, I'm a designer and I am looking for a guide to resolve this.

 

thanks.

 

This is my code:

 

<!DOCTYPE html>

<html>

<head>

<meta charset="UTF-8">

<title>CreateJS export from hola</title>

 

 

<script src="easeljs-0.6.0.min.js"></script>

<script src="tweenjs-0.4.0.min.js"></script>

<script src="movieclip-0.6.0.min.js"></script>

<script src="hola.js"></script>

<script src="cloud gc.js"></script>

<script>

var canvas, stage, exportRoot;

 

 

function init() {

          canvas = document.getElementById("canvas");

 

          exportRoot = new lib.hola();

 

 

          stage = new createjs.Stage(canvas);

 

          stage.addChild(exportRoot);

          stage.update();

 

 

          createjs.Ticker.setFPS(30);

          createjs.Ticker.addEventListener("tick", stage);

}

 

 

var canvas, stage, exportRoot;

 

 

function init() {

          canvas = document.getElementById("cloud");

 

          exportRoot = new lib.cloudgc();

 

 

          stage = new createjs.Stage(cloud);

 

          stage.addChild(exportRoot);

          stage.update();

 

 

          createjs.Ticker.setFPS(10);

          createjs.Ticker.addEventListener("tick", stage);

}

 

 

</script>

 

 

</head>

 

 

<body onload="init();" style="background-color:#D4D4D4">

          <canvas id="canvas" width="550" height="400" style="background-color:#ffffff"></canvas>

    <canvas id="cloud" width="550" height="400" style="background-color:#ffffff"></canvas>

</body>

</html>


 

 

 

 

 

 


Viewing all articles
Browse latest Browse all 13519

Trending Articles