mausverfolger.php


Quell Code


<!DOCTYPE html>
 
<html>
<head>
<meta charset="UTF-8">
<meta name="authoring-tool" content="Adobe_Animate_CC">
<title>snake</title>
<!-- write your code here -->
<style>
body {background-color: #000; margin: 0px; }
  #animation_container, #_preload_div_ {
	position:absolute;
	margin:auto;
	left:0;right:0;
	top:0;bottom:0;
  }
</style>
<script src="https://code.createjs.com/createjs-2015.11.26.min.js"></script>
<script>
  (function (cjs, an) {

var p; // shortcut to reference prototypes
var lib={};var ss={};var img={};
lib.webFontTxtInst = {}; 
var loadedTypekitCount = 0;
var loadedGoogleCount = 0;
var gFontsUpdateCacheList = [];
var tFontsUpdateCacheList = [];
lib.ssMetadata = [];



lib.updateListCache = function (cacheList) {		
	for(var i = 0; i < cacheList.length; i++) {		
		if(cacheList[i].cacheCanvas)		
			cacheList[i].updateCache();		
	}		
};		

lib.addElementsToCache = function (textInst, cacheList) {		
	var cur = textInst;		
	while(cur != null && cur != exportRoot) {		
		if(cacheList.indexOf(cur) != -1)		
			break;		
		cur = cur.parent;		
	}		
	if(cur != exportRoot) {		
		var cur2 = textInst;		
		var index = cacheList.indexOf(cur);		
		while(cur2 != null && cur2 != cur) {		
			cacheList.splice(index, 0, cur2);		
			cur2 = cur2.parent;		
			index++;		
		}		
	}		
	else {		
		cur = textInst;		
		while(cur != null && cur != exportRoot) {		
			cacheList.push(cur);		
			cur = cur.parent;		
		}		
	}		
};		

lib.gfontAvailable = function(family, totalGoogleCount) {		
	lib.properties.webfonts[family] = true;		
	var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];		
	for(var f = 0; f < txtInst.length; ++f)		
		lib.addElementsToCache(txtInst[f], gFontsUpdateCacheList);		

	loadedGoogleCount++;		
	if(loadedGoogleCount == totalGoogleCount) {		
		lib.updateListCache(gFontsUpdateCacheList);		
	}		
};		

lib.tfontAvailable = function(family, totalTypekitCount) {		
	lib.properties.webfonts[family] = true;		
	var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];		
	for(var f = 0; f < txtInst.length; ++f)		
		lib.addElementsToCache(txtInst[f], tFontsUpdateCacheList);		

	loadedTypekitCount++;		
	if(loadedTypekitCount == totalTypekitCount) {		
		lib.updateListCache(tFontsUpdateCacheList);		
	}		
};
// symbols:
// helper functions:

function mc_symbol_clone() {
	var clone = this._cloneProps(new this.constructor(this.mode, this.startPosition, this.loop));
	clone.gotoAndStop(this.currentFrame);
	clone.paused = this.paused;
	clone.framerate = this.framerate;
	return clone;
}

function getMCSymbolPrototype(symbol, nominalBounds, frameBounds) {
	var prototype = cjs.extend(symbol, cjs.MovieClip);
	prototype.clone = mc_symbol_clone;
	prototype.nominalBounds = nominalBounds;
	prototype.frameBounds = frameBounds;
	return prototype;
	}


(lib.unterkiefer = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,1,1).p("AAYCVQgSAJgLABQgQgBgPgKQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQg");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.f().s("#000000").ss(0.3,1,1).p("AB/gFQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJQgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHg");
	this.shape_1.setTransform(0.3,-1);

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.rf(["rgba(100,19,19,0.988)","rgba(163,33,33,0.988)","#000000"],[0,0.325,0.843],-0.4,11.2,0,-0.7,11.2,21.1).s().p("AgfB7QgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJg");
	this.shape_2.setTransform(0.3,-1);

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#1D9F92","#000000"],[0.494,1],0.8,4.3,0,0.8,4.3,17.9).s().p("AgkCUQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQQgSAJgLABQgQgBgPgKgAh+gNQAUAxApArQASAXATALQANAIANACQAKgBAPgJQARgMAWgWQAtgrAWgzQA8iHi9AHIAAAAQixAAAzCCg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2},{t:this.shape_1},{t:this.shape}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.unterkiefer, new cjs.Rectangle(-17.5,-16.9,35.2,33.8), null);


(lib.pupillen = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#000000").s().p("AgGARQgMgFgHgIQgEgIADgGQADgHAJgDQALgBALAFQALAFAGAIQAFAIgDAHQgDAHgKACIgEAAQgIAAgIgEg");
	this.shape.setTransform(-16.8,0);

	this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));

}).prototype = getMCSymbolPrototype(lib.pupillen, new cjs.Rectangle(-19.6,-2.1,5.6,4.3), null);


(lib.nasenloch = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 2
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#000000").s().p("AgGALQgCgEAAgHQAAgGACgFQADgEADAAQAEAAACAEQAEAFAAAGQAAAHgEAEQgCAFgEAAQgDAAgDgFg");
	this.shape.setTransform(1.1,-0.5,1.451,1.451);

	this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));

	// Ebene 1
	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["rgba(47,133,121,0.988)","#000000"],[0.694,1],0,0.4,0,0,0.4,2).s().p("AgOAUQgGgIAAgMQAAgLAGgIQAGgIAIAAQAJAAAGAIQAGAIAAALQAAAMgGAIQgGAIgJAAQgIAAgGgIg");
	this.shape_1.setTransform(1,-1.3,1.451,1.451);

	this.timeline.addTween(cjs.Tween.get(this.shape_1).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-2.1,-5.3,6.2,8.2);


(lib.kugel = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(0.1,0,0,42).p("AAmAAQAAAPgMALQgLAMgPAAQgPAAgLgMQgLgLAAgPQAAgPALgLQALgLAPAAQAPAAALALQAMALAAAPg");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-1,-1,0,-1,-1,3.9).s().p("AgaAaQgLgKAAgQQAAgOALgMQAMgLAOAAQAQAAAKALQAMAMAAAOQAAAQgMAKQgKAMgQAAQgOAAgMgMg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.kugel, new cjs.Rectangle(-4.8,-4.8,9.6,9.6), null);


(lib.Ball = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 2
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AD6AAQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhoQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABng");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#00FFCD","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#000000").ss(1,0,0,42).p("Aj5AAQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABnQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhog");

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#24FBB0","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_4 = new cjs.Shape();
	this.shape_4.graphics.rf(["#49F692","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_5 = new cjs.Shape();
	this.shape_5.graphics.rf(["#6DF275","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_6 = new cjs.Shape();
	this.shape_6.graphics.rf(["#92ED58","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_7 = new cjs.Shape();
	this.shape_7.graphics.rf(["#B6E93B","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_8 = new cjs.Shape();
	this.shape_8.graphics.rf(["#DBE41D","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_9 = new cjs.Shape();
	this.shape_9.graphics.rf(["#FFE000","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_10 = new cjs.Shape();
	this.shape_10.graphics.rf(["#FFC004","#000000","#801DC1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_11 = new cjs.Shape();
	this.shape_11.graphics.rf(["#FFA008","#000000","#6A3AB6"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_12 = new cjs.Shape();
	this.shape_12.graphics.rf(["#FF800C","#000000","#5557AC"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_13 = new cjs.Shape();
	this.shape_13.graphics.rf(["#FF6010","#000000","#4074A1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_14 = new cjs.Shape();
	this.shape_14.graphics.rf(["#FF4014","#000000","#2B9197"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_15 = new cjs.Shape();
	this.shape_15.graphics.rf(["#FF2018","#000000","#15AE8C"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_16 = new cjs.Shape();
	this.shape_16.graphics.rf(["#FF001C","#000000","#00CB82"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_17 = new cjs.Shape();
	this.shape_17.graphics.rf(["#E8172C","#000000","#0EB989"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_18 = new cjs.Shape();
	this.shape_18.graphics.rf(["#D12E3C","#000000","#1BA68F"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_19 = new cjs.Shape();
	this.shape_19.graphics.rf(["#B9464C","#000000","#299496"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_20 = new cjs.Shape();
	this.shape_20.graphics.rf(["#A25D5C","#000000","#36819D"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_21 = new cjs.Shape();
	this.shape_21.graphics.rf(["#8B746C","#000000","#446FA3"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_22 = new cjs.Shape();
	this.shape_22.graphics.rf(["#748B7D","#000000","#515CAA"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_23 = new cjs.Shape();
	this.shape_23.graphics.rf(["#5DA28D","#000000","#5F4AB0"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_24 = new cjs.Shape();
	this.shape_24.graphics.rf(["#46B99D","#000000","#6C37B7"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_25 = new cjs.Shape();
	this.shape_25.graphics.rf(["#2ED1AD","#000000","#7A25BE"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_26 = new cjs.Shape();
	this.shape_26.graphics.rf(["#17E8BD","#000000","#8712C4"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).to({state:[{t:this.shape_3},{t:this.shape_2}]},1).to({state:[{t:this.shape_4},{t:this.shape_2}]},1).to({state:[{t:this.shape_5},{t:this.shape_2}]},1).to({state:[{t:this.shape_6},{t:this.shape_2}]},1).to({state:[{t:this.shape_7},{t:this.shape_2}]},1).to({state:[{t:this.shape_8},{t:this.shape_2}]},1).to({state:[{t:this.shape_9},{t:this.shape}]},1).to({state:[{t:this.shape_10},{t:this.shape_2}]},1).to({state:[{t:this.shape_11},{t:this.shape_2}]},1).to({state:[{t:this.shape_12},{t:this.shape_2}]},1).to({state:[{t:this.shape_13},{t:this.shape_2}]},1).to({state:[{t:this.shape_14},{t:this.shape_2}]},1).to({state:[{t:this.shape_15},{t:this.shape_2}]},1).to({state:[{t:this.shape_16},{t:this.shape}]},1).to({state:[{t:this.shape_17},{t:this.shape_2}]},1).to({state:[{t:this.shape_18},{t:this.shape_2}]},1).to({state:[{t:this.shape_19},{t:this.shape_2}]},1).to({state:[{t:this.shape_20},{t:this.shape_2}]},1).to({state:[{t:this.shape_21},{t:this.shape_2}]},1).to({state:[{t:this.shape_22},{t:this.shape_2}]},1).to({state:[{t:this.shape_23},{t:this.shape_2}]},1).to({state:[{t:this.shape_24},{t:this.shape_2}]},1).to({state:[{t:this.shape_25},{t:this.shape_2}]},1).to({state:[{t:this.shape_26},{t:this.shape_2}]},1).to({state:[{t:this.shape_1},{t:this.shape}]},1).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-26,-26,52,52);


(lib.auge = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// pupillen
	this.instance = new lib.pupillen();
	this.instance.parent = this;
	this.instance.setTransform(17.1,0.7);

	this.timeline.addTween(cjs.Tween.get(this.instance).wait(1));

	// Ebene 3
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(0.4,1,1).p("ABIAfQgHARgaADQgbADgdgMQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARg");
	this.shape.setTransform(-0.4,-1.7);

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#CBFFFA","#20262E"],[0.494,1],-0.2,0.7,0,-0.2,0.7,8.9).s().p("AgWA3QgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWQgKAXggAFQgJACgJAAQgXAAgWgKgAgpgqQgaAEgIARQgHARAQAUQAQAVAdANQAdANAbgEQAagDAHgQQAHgSgPgVQgQgUgegNQgXgKgWAAIgKAAg");
	this.shape_1.setTransform(0,-2.6);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));

	// Ebene 1
	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#000000").ss(0.4,1,1).p("ABTAjQgKAXggAFQgfAGgggOQgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWg");
	this.shape_2.setTransform(0,-2.6);

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#FFFFFF","#44344A"],[0.349,1],0,0.1,0,0,0.1,8.3).s().p("AgRAqQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARQgHARgaADIgMABQgVAAgXgKg");
	this.shape_3.setTransform(-0.4,-1.7);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.auge, new cjs.Rectangle(-9.6,-10.1,19.2,15.1), null);


(lib.SnakeHead = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// kopf
	this.instance = new lib.auge();
	this.instance.parent = this;
	this.instance.setTransform(18.1,-12.4,1.251,1.251,0,0,180);

	this.instance_1 = new lib.auge();
	this.instance_1.parent = this;
	this.instance_1.setTransform(-18,-12.4,1.251,1.251);

	this.instance_2 = new lib.nasenloch("synched",0);
	this.instance_2.parent = this;
	this.instance_2.setTransform(-6.3,3.5,0.926,0.926,-30);

	this.instance_3 = new lib.nasenloch("synched",0);
	this.instance_3.parent = this;
	this.instance_3.setTransform(5.2,2.5,0.926,0.926,30);

	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AiJiqQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfQgEANgFAMQgTAtgoAcQglAZgrAOQgrAPgtAFQguAFgugHQgwgFgvgTQgtgQgkgiQgigggQgrQgBgDgBgDQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAQAEAAAEgBg");
	this.shape.setTransform(0,-7.3);

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-0.7,-1.8,0,-0.7,-1.8,33.9).s().p("AgzCzQgwgFgvgTQgtgQgkgiQgigggQgrIgCgGQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAIAIgBQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfIgJAZQgTAtgoAcQglAZgrAOQgrAPgtAFQgTACgTAAQgbAAgbgEg");
	this.shape_1.setTransform(0,-7.3);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape},{t:this.instance_3},{t:this.instance_2},{t:this.instance_1},{t:this.instance}]}).wait(1));

	// Ebene 5
	this.instance_4 = new lib.kugel();
	this.instance_4.parent = this;
	this.instance_4.setTransform(59.9,-71.7,1,1,0,0,180);

	this.instance_5 = new lib.kugel();
	this.instance_5.parent = this;
	this.instance_5.setTransform(-55.2,-71.7);

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#666666").ss(1,0,0,42).p("ABtEEQgbiZB4iRQB7iUDahFAhsEEQAbiZh4iRQh7iUjahF");
	this.shape_2.setTransform(2.3,-44.9);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_2},{t:this.instance_5},{t:this.instance_4}]}).wait(1));

	// maul
	this.instance_6 = new lib.unterkiefer();
	this.instance_6.parent = this;
	this.instance_6.setTransform(0,9.9);

	this.timeline.addTween(cjs.Tween.get(this.instance_6).wait(1));

}).prototype = getMCSymbolPrototype(lib.SnakeHead, new cjs.Rectangle(-59.1,-75.5,122.8,101.9), null);


// stage content:
(lib.snake = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// timeline functions:
	this.frame_0 = function() {
		var anzahl = 30;
		var abstand = 15;
		var ball = new Object();
		ball[0] = new lib.SnakeHead();
		ball[0].x = 500;
		ball[0].y = 50;
		this.addChild(ball[0]);
		
		
		
		for(i = 1; i < anzahl; i++)
			{
				ball[i] = new lib.Ball();
				ball[i].x = ball[i-1].x - abstand;
				ball[i].y = 50;
				ball[i].scaleX = 1 - i / anzahl;
				ball[i].scaleY =  1 - i / anzahl;
				ball[i].gotoAndPlay(i);
				this.addChild(ball[i]);
			}
		//die zweite Schleife dient dazu die Stapelreihenfolge umzukehren
		for(i = anzahl; i >= 0; i--)
			{
				this.addChild(ball[i]);
			}
			
		this.addEventListener("tick",mover.bind(this));
			
		function mover() 
		{
			 
			var p = this.globalToLocal(this.stage.mouseX, this.stage.mouseY);
			ball[0].x = ball[0].x + (p.x - ball[0].x) / 15;
			 ball[0].y = ball[0].y + (p.y - ball[0].y) / 15;
			
			   for (i = 1; i < anzahl; i++)
		    {
		        //horizontaler Abstand zum vorigen Element,
		         distX = ball[i - 1].x - ball[i].x;
		        //vertikaler Abstand zum vorigen Element
		         distY = ball[i - 1].y - ball[i].y;
		        //Abstand zum vorigen Element (Satz des Pythagoras a² * b² = c²)
		         dist = Math.sqrt(distX * distX + distY * distY);
		        //Verhältnis horizontaler Abstand zum wirklichen Abstand
				
		         cx = distX / dist; 
		         cy = distY / dist;
		        //der gewünschte Abstand ist "abstand", der momentane Abstand ist "dist"
		        //Das Verhältnis horizontaler Abstand zu momenten Abstand ist "cx"
		        //Nun kann man anhand des Verhältnis cx den gewünschten X-Abstand ausrechnen
		         distX_new = cx * (abstand/(i*0.7)+5);
		        //auf gleiche Weise wird auch der gewünschte Y-Abstand errechnet
		         distY_new = cy * (abstand / ( i* 0.7)+5);
		        //Die neue Position wird gesetzt, der errechnete Abstand wird von der Position
		        //des vorigen Elementes abgezogen
				ball[i].x = ball[i - 1].x - distX_new;
		        ball[i].y = ball[i - 1].y - distY_new;
		      
		    }
			
		}
	}

	// actions tween:
	this.timeline.addTween(cjs.Tween.get(this).call(this.frame_0).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = null;
// library properties:
lib.properties = {
	id: 'A159DC6E08C1F34A8C922AA70F875570',
	width: 800,
	height: 800,
	fps: 24,
	color: "#000000",
	opacity: 1.00,
	webfonts: {},
	manifest: [],
	preloads: []
};



// bootstrap callback support:

(lib.Stage = function(canvas) {
	createjs.Stage.call(this, canvas);
}).prototype = p = new createjs.Stage();

p.setAutoPlay = function(autoPlay) {
	this.tickEnabled = autoPlay;
}
p.play = function() { this.tickEnabled = true; this.getChildAt(0).gotoAndPlay(this.getTimelinePosition()) }
p.stop = function(ms) { if(ms) this.seek(ms); this.tickEnabled = false; }
p.seek = function(ms) { this.tickEnabled = true; this.getChildAt(0).gotoAndStop(lib.properties.fps * ms / 1000); }
p.getDuration = function() { return this.getChildAt(0).totalFrames / lib.properties.fps * 1000; }

p.getTimelinePosition = function() { return this.getChildAt(0).currentFrame / lib.properties.fps * 1000; }

an.bootcompsLoaded = an.bootcompsLoaded || [];
if(!an.bootstrapListeners) {
	an.bootstrapListeners=[];
}

an.bootstrapCallback=function(fnCallback) {
	an.bootstrapListeners.push(fnCallback);
	if(an.bootcompsLoaded.length > 0) {
		for(var i=0; i<an.bootcompsLoaded.length; ++i) {
			fnCallback(an.bootcompsLoaded[i]);
		}
	}
};

an.compositions = an.compositions || {};
an.compositions['A159DC6E08C1F34A8C922AA70F875570'] = {
	getStage: function() { return exportRoot.getStage(); },
	getLibrary: function() { return lib; },
	getSpriteSheet: function() { return ss; },
	getImages: function() { return img; }
};

an.compositionLoaded = function(id) {
	an.bootcompsLoaded.push(id);
	for(var j=0; j<an.bootstrapListeners.length; j++) {
		an.bootstrapListeners[j](id);
	}
}

an.getComposition = function(id) {
	return an.compositions[id];
}



})(createjs = createjs||{}, AdobeAn = AdobeAn||{});
var createjs, AdobeAn;
  </script>
<script>
var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation;
function init() {
	canvas = document.getElementById("canvas");
	anim_container = document.getElementById("animation_container");
	dom_overlay_container = document.getElementById("dom_overlay_container");
	var comp=AdobeAn.getComposition("A159DC6E08C1F34A8C922AA70F875570");
	var lib=comp.getLibrary();
	handleComplete({},comp);
}
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();
	var preloaderDiv = document.getElementById("_preload_div_");
	preloaderDiv.style.display = 'none';
	canvas.style.display = 'block';
	exportRoot = new lib.snake();
	stage = new lib.Stage(canvas);
	stage.addChild(exportRoot);	
 
	fnStartAnimation = function() {
		createjs.Ticker.setFPS(lib.properties.fps);
		createjs.Ticker.addEventListener("tick", stage);
	}	    
	//Code to support hidpi screens and responsive scaling.
	function makeResponsive(isResp, respDim, isScale, scaleType) {		
		var lastW, lastH, lastS=1;		
		window.addEventListener('resize', resizeCanvas);		
		resizeCanvas();		
		function resizeCanvas() {			
			var w = lib.properties.width, h = lib.properties.height;			
			var iw = window.innerWidth, ih=window.innerHeight;			
			var pRatio = window.devicePixelRatio || 1, xRatio=iw/w, yRatio=ih/h, sRatio=1;			
			if(isResp) {                
				if((respDim=='width'&&lastW==iw) || (respDim=='height'&&lastH==ih)) {                    
					sRatio = lastS;                
				}				
				else if(!isScale) {					
					if(iw<w || ih<h)						
						sRatio = Math.min(xRatio, yRatio);				
				}				
				else if(scaleType==1) {					
					sRatio = Math.min(xRatio, yRatio);				
				}				
				else if(scaleType==2) {					
					sRatio = Math.max(xRatio, yRatio);				
				}			
			}			
			canvas.width = w*pRatio*sRatio;			
			canvas.height = h*pRatio*sRatio;
			canvas.style.width = anim_container.style.width = dom_overlay_container.style.width = preloaderDiv.style.width = w*sRatio+'px';				
			canvas.style.height = anim_container.style.height = dom_overlay_container.style.height = preloaderDiv.style.height = h*sRatio+'px';
			stage.scaleX = pRatio*sRatio;			
			stage.scaleY = pRatio*sRatio;			
			lastW = iw; lastH = ih; lastS = sRatio;		
		}
	}
	makeResponsive(true,'both',true,1);	
	AdobeAn.compositionLoaded(lib.properties.id);
	fnStartAnimation();
}
</script>
<!-- write your code here -->
</head>
<body onload="init();" style="margin:0px;">
	<div id="animation_container" style="background-color:rgba(0, 0, 0, 1.00); width:800px; height:800px">
		<canvas id="canvas" width="800" height="800" style="position: absolute; display: none; background-color:rgba(0, 0, 0, 1.00);"></canvas>
		<div id="dom_overlay_container" style="pointer-events:none; overflow:hidden; width:800px; height:800px; position: absolute; left: 0px; top: 0px; display: none;">
		</div>
	</div>
    <div id='_preload_div_' style='display: inline-block; height:800px; width: 800px; vertical-align=middle;position:absolute;left:0px;top:0px;text-align: center;'>	<span style='display: inline-block; height: 100%; vertical-align: middle;'></span>	<img src=https://on-design.de/html5/snake/images/_preloader.gif style='vertical-align: middle; max-height: 100%'/></div>
</body>
</html>
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="authoring-tool" content="Adobe_Animate_CC">
  6. <title>snake</title>
  7. <!-- write your code here -->
  8. <style>
  9. body {background-color: #000; margin: 0px; }
  10. #animation_container, #_preload_div_ {
  11. position:absolute;
  12. margin:auto;
  13. left:0;right:0;
  14. top:0;bottom:0;
  15. }
  16. </style>
  17. <script src="https://code.createjs.com/createjs-2015.11.26.min.js"></script>
  18. <script>
  19. (function (cjs, an) {
  20. var p; // shortcut to reference prototypes
  21. var lib={};var ss={};var img={};
  22. lib.webFontTxtInst = {};
  23. var loadedTypekitCount = 0;
  24. var loadedGoogleCount = 0;
  25. var gFontsUpdateCacheList = [];
  26. var tFontsUpdateCacheList = [];
  27. lib.ssMetadata = [];
  28. lib.updateListCache = function (cacheList) {
  29. for(var i = 0; i < cacheList.length; i++) {
  30. if(cacheList[i].cacheCanvas)
  31. cacheList[i].updateCache();
  32. }
  33. };
  34. lib.addElementsToCache = function (textInst, cacheList) {
  35. var cur = textInst;
  36. while(cur != null && cur != exportRoot) {
  37. if(cacheList.indexOf(cur) != -1)
  38. break;
  39. cur = cur.parent;
  40. }
  41. if(cur != exportRoot) {
  42. var cur2 = textInst;
  43. var index = cacheList.indexOf(cur);
  44. while(cur2 != null && cur2 != cur) {
  45. cacheList.splice(index, 0, cur2);
  46. cur2 = cur2.parent;
  47. index++;
  48. }
  49. }
  50. else {
  51. cur = textInst;
  52. while(cur != null && cur != exportRoot) {
  53. cacheList.push(cur);
  54. cur = cur.parent;
  55. }
  56. }
  57. };
  58. lib.gfontAvailable = function(family, totalGoogleCount) {
  59. lib.properties.webfonts[family] = true;
  60. var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];
  61. for(var f = 0; f < txtInst.length; ++f)
  62. lib.addElementsToCache(txtInst[f], gFontsUpdateCacheList);
  63. loadedGoogleCount++;
  64. if(loadedGoogleCount == totalGoogleCount) {
  65. lib.updateListCache(gFontsUpdateCacheList);
  66. }
  67. };
  68. lib.tfontAvailable = function(family, totalTypekitCount) {
  69. lib.properties.webfonts[family] = true;
  70. var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];
  71. for(var f = 0; f < txtInst.length; ++f)
  72. lib.addElementsToCache(txtInst[f], tFontsUpdateCacheList);
  73. loadedTypekitCount++;
  74. if(loadedTypekitCount == totalTypekitCount) {
  75. lib.updateListCache(tFontsUpdateCacheList);
  76. }
  77. };
  78. // symbols:
  79. // helper functions:
  80. function mc_symbol_clone() {
  81. var clone = this._cloneProps(new this.constructor(this.mode, this.startPosition, this.loop));
  82. clone.gotoAndStop(this.currentFrame);
  83. clone.paused = this.paused;
  84. clone.framerate = this.framerate;
  85. return clone;
  86. }
  87. function getMCSymbolPrototype(symbol, nominalBounds, frameBounds) {
  88. var prototype = cjs.extend(symbol, cjs.MovieClip);
  89. prototype.clone = mc_symbol_clone;
  90. prototype.nominalBounds = nominalBounds;
  91. prototype.frameBounds = frameBounds;
  92. return prototype;
  93. }
  94. (lib.unterkiefer = function(mode,startPosition,loop) {
  95. this.initialize(mode,startPosition,loop,{});
  96. // Ebene 1
  97. this.shape = new cjs.Shape();
  98. this.shape.graphics.f().s("#000000").ss(1,1,1).p("AAYCVQgSAJgLABQgQgBgPgKQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQg");
  99. this.shape_1 = new cjs.Shape();
  100. this.shape_1.graphics.f().s("#000000").ss(0.3,1,1).p("AB/gFQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJQgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHg");
  101. this.shape_1.setTransform(0.3,-1);
  102. this.shape_2 = new cjs.Shape();
  103. this.shape_2.graphics.rf(["rgba(100,19,19,0.988)","rgba(163,33,33,0.988)","#000000"],[0,0.325,0.843],-0.4,11.2,0,-0.7,11.2,21.1).s().p("AgfB7QgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJg");
  104. this.shape_2.setTransform(0.3,-1);
  105. this.shape_3 = new cjs.Shape();
  106. this.shape_3.graphics.rf(["#1D9F92","#000000"],[0.494,1],0.8,4.3,0,0.8,4.3,17.9).s().p("AgkCUQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQQgSAJgLABQgQgBgPgKgAh+gNQAUAxApArQASAXATALQANAIANACQAKgBAPgJQARgMAWgWQAtgrAWgzQA8iHi9AHIAAAAQixAAAzCCg");
  107. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2},{t:this.shape_1},{t:this.shape}]}).wait(1));
  108. }).prototype = getMCSymbolPrototype(lib.unterkiefer, new cjs.Rectangle(-17.5,-16.9,35.2,33.8), null);
  109. (lib.pupillen = function(mode,startPosition,loop) {
  110. this.initialize(mode,startPosition,loop,{});
  111. // Ebene 1
  112. this.shape = new cjs.Shape();
  113. this.shape.graphics.f("#000000").s().p("AgGARQgMgFgHgIQgEgIADgGQADgHAJgDQALgBALAFQALAFAGAIQAFAIgDAHQgDAHgKACIgEAAQgIAAgIgEg");
  114. this.shape.setTransform(-16.8,0);
  115. this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
  116. }).prototype = getMCSymbolPrototype(lib.pupillen, new cjs.Rectangle(-19.6,-2.1,5.6,4.3), null);
  117. (lib.nasenloch = function(mode,startPosition,loop) {
  118. this.initialize(mode,startPosition,loop,{});
  119. // Ebene 2
  120. this.shape = new cjs.Shape();
  121. this.shape.graphics.f("#000000").s().p("AgGALQgCgEAAgHQAAgGACgFQADgEADAAQAEAAACAEQAEAFAAAGQAAAHgEAEQgCAFgEAAQgDAAgDgFg");
  122. this.shape.setTransform(1.1,-0.5,1.451,1.451);
  123. this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
  124. // Ebene 1
  125. this.shape_1 = new cjs.Shape();
  126. this.shape_1.graphics.rf(["rgba(47,133,121,0.988)","#000000"],[0.694,1],0,0.4,0,0,0.4,2).s().p("AgOAUQgGgIAAgMQAAgLAGgIQAGgIAIAAQAJAAAGAIQAGAIAAALQAAAMgGAIQgGAIgJAAQgIAAgGgIg");
  127. this.shape_1.setTransform(1,-1.3,1.451,1.451);
  128. this.timeline.addTween(cjs.Tween.get(this.shape_1).wait(1));
  129. }).prototype = p = new cjs.MovieClip();
  130. p.nominalBounds = new cjs.Rectangle(-2.1,-5.3,6.2,8.2);
  131. (lib.kugel = function(mode,startPosition,loop) {
  132. this.initialize(mode,startPosition,loop,{});
  133. // Ebene 1
  134. this.shape = new cjs.Shape();
  135. this.shape.graphics.f().s("#000000").ss(0.1,0,0,42).p("AAmAAQAAAPgMALQgLAMgPAAQgPAAgLgMQgLgLAAgPQAAgPALgLQALgLAPAAQAPAAALALQAMALAAAPg");
  136. this.shape_1 = new cjs.Shape();
  137. this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-1,-1,0,-1,-1,3.9).s().p("AgaAaQgLgKAAgQQAAgOALgMQAMgLAOAAQAQAAAKALQAMAMAAAOQAAAQgMAKQgKAMgQAAQgOAAgMgMg");
  138. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));
  139. }).prototype = getMCSymbolPrototype(lib.kugel, new cjs.Rectangle(-4.8,-4.8,9.6,9.6), null);
  140. (lib.Ball = function(mode,startPosition,loop) {
  141. this.initialize(mode,startPosition,loop,{});
  142. // Ebene 2
  143. this.shape = new cjs.Shape();
  144. this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AD6AAQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhoQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABng");
  145. this.shape_1 = new cjs.Shape();
  146. this.shape_1.graphics.rf(["#00FFCD","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  147. this.shape_2 = new cjs.Shape();
  148. this.shape_2.graphics.f().s("#000000").ss(1,0,0,42).p("Aj5AAQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABnQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhog");
  149. this.shape_3 = new cjs.Shape();
  150. this.shape_3.graphics.rf(["#24FBB0","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  151. this.shape_4 = new cjs.Shape();
  152. this.shape_4.graphics.rf(["#49F692","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  153. this.shape_5 = new cjs.Shape();
  154. this.shape_5.graphics.rf(["#6DF275","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  155. this.shape_6 = new cjs.Shape();
  156. this.shape_6.graphics.rf(["#92ED58","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  157. this.shape_7 = new cjs.Shape();
  158. this.shape_7.graphics.rf(["#B6E93B","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  159. this.shape_8 = new cjs.Shape();
  160. this.shape_8.graphics.rf(["#DBE41D","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  161. this.shape_9 = new cjs.Shape();
  162. this.shape_9.graphics.rf(["#FFE000","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  163. this.shape_10 = new cjs.Shape();
  164. this.shape_10.graphics.rf(["#FFC004","#000000","#801DC1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  165. this.shape_11 = new cjs.Shape();
  166. this.shape_11.graphics.rf(["#FFA008","#000000","#6A3AB6"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  167. this.shape_12 = new cjs.Shape();
  168. this.shape_12.graphics.rf(["#FF800C","#000000","#5557AC"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  169. this.shape_13 = new cjs.Shape();
  170. this.shape_13.graphics.rf(["#FF6010","#000000","#4074A1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  171. this.shape_14 = new cjs.Shape();
  172. this.shape_14.graphics.rf(["#FF4014","#000000","#2B9197"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  173. this.shape_15 = new cjs.Shape();
  174. this.shape_15.graphics.rf(["#FF2018","#000000","#15AE8C"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  175. this.shape_16 = new cjs.Shape();
  176. this.shape_16.graphics.rf(["#FF001C","#000000","#00CB82"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  177. this.shape_17 = new cjs.Shape();
  178. this.shape_17.graphics.rf(["#E8172C","#000000","#0EB989"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  179. this.shape_18 = new cjs.Shape();
  180. this.shape_18.graphics.rf(["#D12E3C","#000000","#1BA68F"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  181. this.shape_19 = new cjs.Shape();
  182. this.shape_19.graphics.rf(["#B9464C","#000000","#299496"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  183. this.shape_20 = new cjs.Shape();
  184. this.shape_20.graphics.rf(["#A25D5C","#000000","#36819D"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  185. this.shape_21 = new cjs.Shape();
  186. this.shape_21.graphics.rf(["#8B746C","#000000","#446FA3"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  187. this.shape_22 = new cjs.Shape();
  188. this.shape_22.graphics.rf(["#748B7D","#000000","#515CAA"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  189. this.shape_23 = new cjs.Shape();
  190. this.shape_23.graphics.rf(["#5DA28D","#000000","#5F4AB0"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  191. this.shape_24 = new cjs.Shape();
  192. this.shape_24.graphics.rf(["#46B99D","#000000","#6C37B7"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  193. this.shape_25 = new cjs.Shape();
  194. this.shape_25.graphics.rf(["#2ED1AD","#000000","#7A25BE"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  195. this.shape_26 = new cjs.Shape();
  196. this.shape_26.graphics.rf(["#17E8BD","#000000","#8712C4"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");
  197. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).to({state:[{t:this.shape_3},{t:this.shape_2}]},1).to({state:[{t:this.shape_4},{t:this.shape_2}]},1).to({state:[{t:this.shape_5},{t:this.shape_2}]},1).to({state:[{t:this.shape_6},{t:this.shape_2}]},1).to({state:[{t:this.shape_7},{t:this.shape_2}]},1).to({state:[{t:this.shape_8},{t:this.shape_2}]},1).to({state:[{t:this.shape_9},{t:this.shape}]},1).to({state:[{t:this.shape_10},{t:this.shape_2}]},1).to({state:[{t:this.shape_11},{t:this.shape_2}]},1).to({state:[{t:this.shape_12},{t:this.shape_2}]},1).to({state:[{t:this.shape_13},{t:this.shape_2}]},1).to({state:[{t:this.shape_14},{t:this.shape_2}]},1).to({state:[{t:this.shape_15},{t:this.shape_2}]},1).to({state:[{t:this.shape_16},{t:this.shape}]},1).to({state:[{t:this.shape_17},{t:this.shape_2}]},1).to({state:[{t:this.shape_18},{t:this.shape_2}]},1).to({state:[{t:this.shape_19},{t:this.shape_2}]},1).to({state:[{t:this.shape_20},{t:this.shape_2}]},1).to({state:[{t:this.shape_21},{t:this.shape_2}]},1).to({state:[{t:this.shape_22},{t:this.shape_2}]},1).to({state:[{t:this.shape_23},{t:this.shape_2}]},1).to({state:[{t:this.shape_24},{t:this.shape_2}]},1).to({state:[{t:this.shape_25},{t:this.shape_2}]},1).to({state:[{t:this.shape_26},{t:this.shape_2}]},1).to({state:[{t:this.shape_1},{t:this.shape}]},1).wait(1));
  198. }).prototype = p = new cjs.MovieClip();
  199. p.nominalBounds = new cjs.Rectangle(-26,-26,52,52);
  200. (lib.auge = function(mode,startPosition,loop) {
  201. this.initialize(mode,startPosition,loop,{});
  202. // pupillen
  203. this.instance = new lib.pupillen();
  204. this.instance.parent = this;
  205. this.instance.setTransform(17.1,0.7);
  206. this.timeline.addTween(cjs.Tween.get(this.instance).wait(1));
  207. // Ebene 3
  208. this.shape = new cjs.Shape();
  209. this.shape.graphics.f().s("#000000").ss(0.4,1,1).p("ABIAfQgHARgaADQgbADgdgMQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARg");
  210. this.shape.setTransform(-0.4,-1.7);
  211. this.shape_1 = new cjs.Shape();
  212. this.shape_1.graphics.rf(["#CBFFFA","#20262E"],[0.494,1],-0.2,0.7,0,-0.2,0.7,8.9).s().p("AgWA3QgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWQgKAXggAFQgJACgJAAQgXAAgWgKgAgpgqQgaAEgIARQgHARAQAUQAQAVAdANQAdANAbgEQAagDAHgQQAHgSgPgVQgQgUgegNQgXgKgWAAIgKAAg");
  213. this.shape_1.setTransform(0,-2.6);
  214. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));
  215. // Ebene 1
  216. this.shape_2 = new cjs.Shape();
  217. this.shape_2.graphics.f().s("#000000").ss(0.4,1,1).p("ABTAjQgKAXggAFQgfAGgggOQgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWg");
  218. this.shape_2.setTransform(0,-2.6);
  219. this.shape_3 = new cjs.Shape();
  220. this.shape_3.graphics.rf(["#FFFFFF","#44344A"],[0.349,1],0,0.1,0,0,0.1,8.3).s().p("AgRAqQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARQgHARgaADIgMABQgVAAgXgKg");
  221. this.shape_3.setTransform(-0.4,-1.7);
  222. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2}]}).wait(1));
  223. }).prototype = getMCSymbolPrototype(lib.auge, new cjs.Rectangle(-9.6,-10.1,19.2,15.1), null);
  224. (lib.SnakeHead = function(mode,startPosition,loop) {
  225. this.initialize(mode,startPosition,loop,{});
  226. // kopf
  227. this.instance = new lib.auge();
  228. this.instance.parent = this;
  229. this.instance.setTransform(18.1,-12.4,1.251,1.251,0,0,180);
  230. this.instance_1 = new lib.auge();
  231. this.instance_1.parent = this;
  232. this.instance_1.setTransform(-18,-12.4,1.251,1.251);
  233. this.instance_2 = new lib.nasenloch("synched",0);
  234. this.instance_2.parent = this;
  235. this.instance_2.setTransform(-6.3,3.5,0.926,0.926,-30);
  236. this.instance_3 = new lib.nasenloch("synched",0);
  237. this.instance_3.parent = this;
  238. this.instance_3.setTransform(5.2,2.5,0.926,0.926,30);
  239. this.shape = new cjs.Shape();
  240. this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AiJiqQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfQgEANgFAMQgTAtgoAcQglAZgrAOQgrAPgtAFQguAFgugHQgwgFgvgTQgtgQgkgiQgigggQgrQgBgDgBgDQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAQAEAAAEgBg");
  241. this.shape.setTransform(0,-7.3);
  242. this.shape_1 = new cjs.Shape();
  243. this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-0.7,-1.8,0,-0.7,-1.8,33.9).s().p("AgzCzQgwgFgvgTQgtgQgkgiQgigggQgrIgCgGQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAIAIgBQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfIgJAZQgTAtgoAcQglAZgrAOQgrAPgtAFQgTACgTAAQgbAAgbgEg");
  244. this.shape_1.setTransform(0,-7.3);
  245. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape},{t:this.instance_3},{t:this.instance_2},{t:this.instance_1},{t:this.instance}]}).wait(1));
  246. // Ebene 5
  247. this.instance_4 = new lib.kugel();
  248. this.instance_4.parent = this;
  249. this.instance_4.setTransform(59.9,-71.7,1,1,0,0,180);
  250. this.instance_5 = new lib.kugel();
  251. this.instance_5.parent = this;
  252. this.instance_5.setTransform(-55.2,-71.7);
  253. this.shape_2 = new cjs.Shape();
  254. this.shape_2.graphics.f().s("#666666").ss(1,0,0,42).p("ABtEEQgbiZB4iRQB7iUDahFAhsEEQAbiZh4iRQh7iUjahF");
  255. this.shape_2.setTransform(2.3,-44.9);
  256. this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_2},{t:this.instance_5},{t:this.instance_4}]}).wait(1));
  257. // maul
  258. this.instance_6 = new lib.unterkiefer();
  259. this.instance_6.parent = this;
  260. this.instance_6.setTransform(0,9.9);
  261. this.timeline.addTween(cjs.Tween.get(this.instance_6).wait(1));
  262. }).prototype = getMCSymbolPrototype(lib.SnakeHead, new cjs.Rectangle(-59.1,-75.5,122.8,101.9), null);
  263. // stage content:
  264. (lib.snake = function(mode,startPosition,loop) {
  265. this.initialize(mode,startPosition,loop,{});
  266. // timeline functions:
  267. this.frame_0 = function() {
  268. var anzahl = 30;
  269. var abstand = 15;
  270. var ball = new Object();
  271. ball[0] = new lib.SnakeHead();
  272. ball[0].x = 500;
  273. ball[0].y = 50;
  274. this.addChild(ball[0]);
  275. for(i = 1; i < anzahl; i++)
  276. {
  277. ball[i] = new lib.Ball();
  278. ball[i].x = ball[i-1].x - abstand;
  279. ball[i].y = 50;
  280. ball[i].scaleX = 1 - i / anzahl;
  281. ball[i].scaleY = 1 - i / anzahl;
  282. ball[i].gotoAndPlay(i);
  283. this.addChild(ball[i]);
  284. }
  285. //die zweite Schleife dient dazu die Stapelreihenfolge umzukehren
  286. for(i = anzahl; i >= 0; i--)
  287. {
  288. this.addChild(ball[i]);
  289. }
  290. this.addEventListener("tick",mover.bind(this));
  291. function mover()
  292. {
  293. var p = this.globalToLocal(this.stage.mouseX, this.stage.mouseY);
  294. ball[0].x = ball[0].x + (p.x - ball[0].x) / 15;
  295. ball[0].y = ball[0].y + (p.y - ball[0].y) / 15;
  296. for (i = 1; i < anzahl; i++)
  297. {
  298. //horizontaler Abstand zum vorigen Element,
  299. distX = ball[i - 1].x - ball[i].x;
  300. //vertikaler Abstand zum vorigen Element
  301. distY = ball[i - 1].y - ball[i].y;
  302. //Abstand zum vorigen Element (Satz des Pythagoras a² * b² = c²)
  303. dist = Math.sqrt(distX * distX + distY * distY);
  304. //Verhältnis horizontaler Abstand zum wirklichen Abstand
  305. cx = distX / dist;
  306. cy = distY / dist;
  307. //der gewünschte Abstand ist "abstand", der momentane Abstand ist "dist"
  308. //Das Verhältnis horizontaler Abstand zu momenten Abstand ist "cx"
  309. //Nun kann man anhand des Verhältnis cx den gewünschten X-Abstand ausrechnen
  310. distX_new = cx * (abstand/(i*0.7)+5);
  311. //auf gleiche Weise wird auch der gewünschte Y-Abstand errechnet
  312. distY_new = cy * (abstand / ( i* 0.7)+5);
  313. //Die neue Position wird gesetzt, der errechnete Abstand wird von der Position
  314. //des vorigen Elementes abgezogen
  315. ball[i].x = ball[i - 1].x - distX_new;
  316. ball[i].y = ball[i - 1].y - distY_new;
  317. }
  318. }
  319. }
  320. // actions tween:
  321. this.timeline.addTween(cjs.Tween.get(this).call(this.frame_0).wait(1));
  322. }).prototype = p = new cjs.MovieClip();
  323. p.nominalBounds = null;
  324. // library properties:
  325. lib.properties = {
  326. id: 'A159DC6E08C1F34A8C922AA70F875570',
  327. width: 800,
  328. height: 800,
  329. fps: 24,
  330. color: "#000000",
  331. opacity: 1.00,
  332. webfonts: {},
  333. manifest: [],
  334. preloads: []
  335. };
  336. // bootstrap callback support:
  337. (lib.Stage = function(canvas) {
  338. createjs.Stage.call(this, canvas);
  339. }).prototype = p = new createjs.Stage();
  340. p.setAutoPlay = function(autoPlay) {
  341. this.tickEnabled = autoPlay;
  342. }
  343. p.play = function() { this.tickEnabled = true; this.getChildAt(0).gotoAndPlay(this.getTimelinePosition()) }
  344. p.stop = function(ms) { if(ms) this.seek(ms); this.tickEnabled = false; }
  345. p.seek = function(ms) { this.tickEnabled = true; this.getChildAt(0).gotoAndStop(lib.properties.fps * ms / 1000); }
  346. p.getDuration = function() { return this.getChildAt(0).totalFrames / lib.properties.fps * 1000; }
  347. p.getTimelinePosition = function() { return this.getChildAt(0).currentFrame / lib.properties.fps * 1000; }
  348. an.bootcompsLoaded = an.bootcompsLoaded || [];
  349. if(!an.bootstrapListeners) {
  350. an.bootstrapListeners=[];
  351. }
  352. an.bootstrapCallback=function(fnCallback) {
  353. an.bootstrapListeners.push(fnCallback);
  354. if(an.bootcompsLoaded.length > 0) {
  355. for(var i=0; i<an.bootcompsLoaded.length; ++i) {
  356. fnCallback(an.bootcompsLoaded[i]);
  357. }
  358. }
  359. };
  360. an.compositions = an.compositions || {};
  361. an.compositions['A159DC6E08C1F34A8C922AA70F875570'] = {
  362. getStage: function() { return exportRoot.getStage(); },
  363. getLibrary: function() { return lib; },
  364. getSpriteSheet: function() { return ss; },
  365. getImages: function() { return img; }
  366. };
  367. an.compositionLoaded = function(id) {
  368. an.bootcompsLoaded.push(id);
  369. for(var j=0; j<an.bootstrapListeners.length; j++) {
  370. an.bootstrapListeners[j](id);
  371. }
  372. }
  373. an.getComposition = function(id) {
  374. return an.compositions[id];
  375. }
  376. })(createjs = createjs||{}, AdobeAn = AdobeAn||{});
  377. var createjs, AdobeAn;
  378. </script>
  379. <script>
  380. var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation;
  381. function init() {
  382. canvas = document.getElementById("canvas");
  383. anim_container = document.getElementById("animation_container");
  384. dom_overlay_container = document.getElementById("dom_overlay_container");
  385. var comp=AdobeAn.getComposition("A159DC6E08C1F34A8C922AA70F875570");
  386. var lib=comp.getLibrary();
  387. handleComplete({},comp);
  388. }
  389. function handleComplete(evt,comp) {
  390. //This function is always called, irrespective of the content. You can use the variable "stage" after it is created in token create_stage.
  391. var lib=comp.getLibrary();
  392. var ss=comp.getSpriteSheet();
  393. var preloaderDiv = document.getElementById("_preload_div_");
  394. preloaderDiv.style.display = 'none';
  395. canvas.style.display = 'block';
  396. exportRoot = new lib.snake();
  397. stage = new lib.Stage(canvas);
  398. stage.addChild(exportRoot);
  399. fnStartAnimation = function() {
  400. createjs.Ticker.setFPS(lib.properties.fps);
  401. createjs.Ticker.addEventListener("tick", stage);
  402. }
  403. //Code to support hidpi screens and responsive scaling.
  404. function makeResponsive(isResp, respDim, isScale, scaleType) {
  405. var lastW, lastH, lastS=1;
  406. window.addEventListener('resize', resizeCanvas);
  407. resizeCanvas();
  408. function resizeCanvas() {
  409. var w = lib.properties.width, h = lib.properties.height;
  410. var iw = window.innerWidth, ih=window.innerHeight;
  411. var pRatio = window.devicePixelRatio || 1, xRatio=iw/w, yRatio=ih/h, sRatio=1;
  412. if(isResp) {
  413. if((respDim=='width'&&lastW==iw) || (respDim=='height'&&lastH==ih)) {
  414. sRatio = lastS;
  415. }
  416. else if(!isScale) {
  417. if(iw<w || ih<h)
  418. sRatio = Math.min(xRatio, yRatio);
  419. }
  420. else if(scaleType==1) {
  421. sRatio = Math.min(xRatio, yRatio);
  422. }
  423. else if(scaleType==2) {
  424. sRatio = Math.max(xRatio, yRatio);
  425. }
  426. }
  427. canvas.width = w*pRatio*sRatio;
  428. canvas.height = h*pRatio*sRatio;
  429. canvas.style.width = anim_container.style.width = dom_overlay_container.style.width = preloaderDiv.style.width = w*sRatio+'px';
  430. canvas.style.height = anim_container.style.height = dom_overlay_container.style.height = preloaderDiv.style.height = h*sRatio+'px';
  431. stage.scaleX = pRatio*sRatio;
  432. stage.scaleY = pRatio*sRatio;
  433. lastW = iw; lastH = ih; lastS = sRatio;
  434. }
  435. }
  436. makeResponsive(true,'both',true,1);
  437. AdobeAn.compositionLoaded(lib.properties.id);
  438. fnStartAnimation();
  439. }
  440. </script>
  441. <!-- write your code here -->
  442. </head>
  443. <body onload="init();" style="margin:0px;">
  444. <div id="animation_container" style="background-color:rgba(0, 0, 0, 1.00); width:800px; height:800px">
  445. <canvas id="canvas" width="800" height="800" style="position: absolute; display: none; background-color:rgba(0, 0, 0, 1.00);"></canvas>
  446. <div id="dom_overlay_container" style="pointer-events:none; overflow:hidden; width:800px; height:800px; position: absolute; left: 0px; top: 0px; display: none;">
  447. </div>
  448. </div>
  449. <div id='_preload_div_' style='display: inline-block; height:800px; width: 800px; vertical-align=middle;position:absolute;left:0px;top:0px;text-align: center;'> <span style='display: inline-block; height: 100%; vertical-align: middle;'></span> <img src=https://on-design.de/html5/snake/images/_preloader.gif style='vertical-align: middle; max-height: 100%'/></div>
  450. </body>
  451. </html>
<!DOCTYPE html>
 
<html>
<head>
<meta charset="UTF-8">
<meta name="authoring-tool" content="Adobe_Animate_CC">
<title>snake</title>
<!-- write your code here -->
<style>
body {background-color: #000; margin: 0px; }
  #animation_container, #_preload_div_ {
	position:absolute;
	margin:auto;
	left:0;right:0;
	top:0;bottom:0;
  }
</style>
<script src="https://code.createjs.com/createjs-2015.11.26.min.js"></script>
<script>
  (function (cjs, an) {

var p; // shortcut to reference prototypes
var lib={};var ss={};var img={};
lib.webFontTxtInst = {}; 
var loadedTypekitCount = 0;
var loadedGoogleCount = 0;
var gFontsUpdateCacheList = [];
var tFontsUpdateCacheList = [];
lib.ssMetadata = [];



lib.updateListCache = function (cacheList) {		
	for(var i = 0; i < cacheList.length; i++) {		
		if(cacheList[i].cacheCanvas)		
			cacheList[i].updateCache();		
	}		
};		

lib.addElementsToCache = function (textInst, cacheList) {		
	var cur = textInst;		
	while(cur != null && cur != exportRoot) {		
		if(cacheList.indexOf(cur) != -1)		
			break;		
		cur = cur.parent;		
	}		
	if(cur != exportRoot) {		
		var cur2 = textInst;		
		var index = cacheList.indexOf(cur);		
		while(cur2 != null && cur2 != cur) {		
			cacheList.splice(index, 0, cur2);		
			cur2 = cur2.parent;		
			index++;		
		}		
	}		
	else {		
		cur = textInst;		
		while(cur != null && cur != exportRoot) {		
			cacheList.push(cur);		
			cur = cur.parent;		
		}		
	}		
};		

lib.gfontAvailable = function(family, totalGoogleCount) {		
	lib.properties.webfonts[family] = true;		
	var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];		
	for(var f = 0; f < txtInst.length; ++f)		
		lib.addElementsToCache(txtInst[f], gFontsUpdateCacheList);		

	loadedGoogleCount++;		
	if(loadedGoogleCount == totalGoogleCount) {		
		lib.updateListCache(gFontsUpdateCacheList);		
	}		
};		

lib.tfontAvailable = function(family, totalTypekitCount) {		
	lib.properties.webfonts[family] = true;		
	var txtInst = lib.webFontTxtInst && lib.webFontTxtInst[family] || [];		
	for(var f = 0; f < txtInst.length; ++f)		
		lib.addElementsToCache(txtInst[f], tFontsUpdateCacheList);		

	loadedTypekitCount++;		
	if(loadedTypekitCount == totalTypekitCount) {		
		lib.updateListCache(tFontsUpdateCacheList);		
	}		
};
// symbols:
// helper functions:

function mc_symbol_clone() {
	var clone = this._cloneProps(new this.constructor(this.mode, this.startPosition, this.loop));
	clone.gotoAndStop(this.currentFrame);
	clone.paused = this.paused;
	clone.framerate = this.framerate;
	return clone;
}

function getMCSymbolPrototype(symbol, nominalBounds, frameBounds) {
	var prototype = cjs.extend(symbol, cjs.MovieClip);
	prototype.clone = mc_symbol_clone;
	prototype.nominalBounds = nominalBounds;
	prototype.frameBounds = frameBounds;
	return prototype;
	}


(lib.unterkiefer = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,1,1).p("AAYCVQgSAJgLABQgQgBgPgKQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQg");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.f().s("#000000").ss(0.3,1,1).p("AB/gFQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJQgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHg");
	this.shape_1.setTransform(0.3,-1);

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.rf(["rgba(100,19,19,0.988)","rgba(163,33,33,0.988)","#000000"],[0,0.325,0.843],-0.4,11.2,0,-0.7,11.2,21.1).s().p("AgfB7QgSgLgTgXQgogrgUgxQgziCCyABQC7gIg7CHQgXAzgtArQgWAXgRAMQgOAIgLABQgNgBgNgJg");
	this.shape_2.setTransform(0.3,-1);

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#1D9F92","#000000"],[0.494,1],0.8,4.3,0,0.8,4.3,17.9).s().p("AgkCUQgWgOgWgbQgwgzgXg7Qg9ibDSAAQDdgJhGCiQgaA9g2AzQgaAagTAQQgSAJgLABQgQgBgPgKgAh+gNQAUAxApArQASAXATALQANAIANACQAKgBAPgJQARgMAWgWQAtgrAWgzQA8iHi9AHIAAAAQixAAAzCCg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2},{t:this.shape_1},{t:this.shape}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.unterkiefer, new cjs.Rectangle(-17.5,-16.9,35.2,33.8), null);


(lib.pupillen = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#000000").s().p("AgGARQgMgFgHgIQgEgIADgGQADgHAJgDQALgBALAFQALAFAGAIQAFAIgDAHQgDAHgKACIgEAAQgIAAgIgEg");
	this.shape.setTransform(-16.8,0);

	this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));

}).prototype = getMCSymbolPrototype(lib.pupillen, new cjs.Rectangle(-19.6,-2.1,5.6,4.3), null);


(lib.nasenloch = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 2
	this.shape = new cjs.Shape();
	this.shape.graphics.f("#000000").s().p("AgGALQgCgEAAgHQAAgGACgFQADgEADAAQAEAAACAEQAEAFAAAGQAAAHgEAEQgCAFgEAAQgDAAgDgFg");
	this.shape.setTransform(1.1,-0.5,1.451,1.451);

	this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));

	// Ebene 1
	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["rgba(47,133,121,0.988)","#000000"],[0.694,1],0,0.4,0,0,0.4,2).s().p("AgOAUQgGgIAAgMQAAgLAGgIQAGgIAIAAQAJAAAGAIQAGAIAAALQAAAMgGAIQgGAIgJAAQgIAAgGgIg");
	this.shape_1.setTransform(1,-1.3,1.451,1.451);

	this.timeline.addTween(cjs.Tween.get(this.shape_1).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-2.1,-5.3,6.2,8.2);


(lib.kugel = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 1
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(0.1,0,0,42).p("AAmAAQAAAPgMALQgLAMgPAAQgPAAgLgMQgLgLAAgPQAAgPALgLQALgLAPAAQAPAAALALQAMALAAAPg");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-1,-1,0,-1,-1,3.9).s().p("AgaAaQgLgKAAgQQAAgOALgMQAMgLAOAAQAQAAAKALQAMAMAAAOQAAAQgMAKQgKAMgQAAQgOAAgMgMg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.kugel, new cjs.Rectangle(-4.8,-4.8,9.6,9.6), null);


(lib.Ball = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// Ebene 2
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AD6AAQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhoQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABng");

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#00FFCD","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#000000").ss(1,0,0,42).p("Aj5AAQAAhnBJhJQBJhJBnAAQBoAABJBJQBJBJAABnQAABohJBJQhJBJhoAAQhnAAhJhJQhJhJAAhog");

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#24FBB0","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_4 = new cjs.Shape();
	this.shape_4.graphics.rf(["#49F692","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_5 = new cjs.Shape();
	this.shape_5.graphics.rf(["#6DF275","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_6 = new cjs.Shape();
	this.shape_6.graphics.rf(["#92ED58","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_7 = new cjs.Shape();
	this.shape_7.graphics.rf(["#B6E93B","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_8 = new cjs.Shape();
	this.shape_8.graphics.rf(["#DBE41D","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_9 = new cjs.Shape();
	this.shape_9.graphics.rf(["#FFE000","#000000","#9500CB"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_10 = new cjs.Shape();
	this.shape_10.graphics.rf(["#FFC004","#000000","#801DC1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_11 = new cjs.Shape();
	this.shape_11.graphics.rf(["#FFA008","#000000","#6A3AB6"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_12 = new cjs.Shape();
	this.shape_12.graphics.rf(["#FF800C","#000000","#5557AC"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_13 = new cjs.Shape();
	this.shape_13.graphics.rf(["#FF6010","#000000","#4074A1"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_14 = new cjs.Shape();
	this.shape_14.graphics.rf(["#FF4014","#000000","#2B9197"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_15 = new cjs.Shape();
	this.shape_15.graphics.rf(["#FF2018","#000000","#15AE8C"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_16 = new cjs.Shape();
	this.shape_16.graphics.rf(["#FF001C","#000000","#00CB82"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_17 = new cjs.Shape();
	this.shape_17.graphics.rf(["#E8172C","#000000","#0EB989"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_18 = new cjs.Shape();
	this.shape_18.graphics.rf(["#D12E3C","#000000","#1BA68F"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_19 = new cjs.Shape();
	this.shape_19.graphics.rf(["#B9464C","#000000","#299496"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_20 = new cjs.Shape();
	this.shape_20.graphics.rf(["#A25D5C","#000000","#36819D"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_21 = new cjs.Shape();
	this.shape_21.graphics.rf(["#8B746C","#000000","#446FA3"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_22 = new cjs.Shape();
	this.shape_22.graphics.rf(["#748B7D","#000000","#515CAA"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_23 = new cjs.Shape();
	this.shape_23.graphics.rf(["#5DA28D","#000000","#5F4AB0"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_24 = new cjs.Shape();
	this.shape_24.graphics.rf(["#46B99D","#000000","#6C37B7"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_25 = new cjs.Shape();
	this.shape_25.graphics.rf(["#2ED1AD","#000000","#7A25BE"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.shape_26 = new cjs.Shape();
	this.shape_26.graphics.rf(["#17E8BD","#000000","#8712C4"],[0,0.89,1],-2.2,-1.8,0,-2.2,-1.8,25.3).s().p("AivCwQhKhIAAhoQAAhnBKhIQBIhKBnAAQBoAABIBKQBKBIAABnQAABohKBIQhIBKhoAAQhnAAhIhKg");

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).to({state:[{t:this.shape_3},{t:this.shape_2}]},1).to({state:[{t:this.shape_4},{t:this.shape_2}]},1).to({state:[{t:this.shape_5},{t:this.shape_2}]},1).to({state:[{t:this.shape_6},{t:this.shape_2}]},1).to({state:[{t:this.shape_7},{t:this.shape_2}]},1).to({state:[{t:this.shape_8},{t:this.shape_2}]},1).to({state:[{t:this.shape_9},{t:this.shape}]},1).to({state:[{t:this.shape_10},{t:this.shape_2}]},1).to({state:[{t:this.shape_11},{t:this.shape_2}]},1).to({state:[{t:this.shape_12},{t:this.shape_2}]},1).to({state:[{t:this.shape_13},{t:this.shape_2}]},1).to({state:[{t:this.shape_14},{t:this.shape_2}]},1).to({state:[{t:this.shape_15},{t:this.shape_2}]},1).to({state:[{t:this.shape_16},{t:this.shape}]},1).to({state:[{t:this.shape_17},{t:this.shape_2}]},1).to({state:[{t:this.shape_18},{t:this.shape_2}]},1).to({state:[{t:this.shape_19},{t:this.shape_2}]},1).to({state:[{t:this.shape_20},{t:this.shape_2}]},1).to({state:[{t:this.shape_21},{t:this.shape_2}]},1).to({state:[{t:this.shape_22},{t:this.shape_2}]},1).to({state:[{t:this.shape_23},{t:this.shape_2}]},1).to({state:[{t:this.shape_24},{t:this.shape_2}]},1).to({state:[{t:this.shape_25},{t:this.shape_2}]},1).to({state:[{t:this.shape_26},{t:this.shape_2}]},1).to({state:[{t:this.shape_1},{t:this.shape}]},1).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-26,-26,52,52);


(lib.auge = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// pupillen
	this.instance = new lib.pupillen();
	this.instance.parent = this;
	this.instance.setTransform(17.1,0.7);

	this.timeline.addTween(cjs.Tween.get(this.instance).wait(1));

	// Ebene 3
	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(0.4,1,1).p("ABIAfQgHARgaADQgbADgdgMQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARg");
	this.shape.setTransform(-0.4,-1.7);

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#CBFFFA","#20262E"],[0.494,1],-0.2,0.7,0,-0.2,0.7,8.9).s().p("AgWA3QgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWQgKAXggAFQgJACgJAAQgXAAgWgKgAgpgqQgaAEgIARQgHARAQAUQAQAVAdANQAdANAbgEQAagDAHgQQAHgSgPgVQgQgUgegNQgXgKgWAAIgKAAg");
	this.shape_1.setTransform(0,-2.6);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape}]}).wait(1));

	// Ebene 1
	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#000000").ss(0.4,1,1).p("ABTAjQgKAXggAFQgfAGgggOQgigPgRgaQgSgaAKgXQAJgWAggGQAfgFAhAOQAhAPARAaQASAagJAWg");
	this.shape_2.setTransform(0,-2.6);

	this.shape_3 = new cjs.Shape();
	this.shape_3.graphics.rf(["#FFFFFF","#44344A"],[0.349,1],0,0.1,0,0,0.1,8.3).s().p("AgRAqQgdgNgQgWQgQgUAHgQQAIgSAagDQAagDAdANQAeAMAQAVQAPAVgHARQgHARgaADIgMABQgVAAgXgKg");
	this.shape_3.setTransform(-0.4,-1.7);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_3},{t:this.shape_2}]}).wait(1));

}).prototype = getMCSymbolPrototype(lib.auge, new cjs.Rectangle(-9.6,-10.1,19.2,15.1), null);


(lib.SnakeHead = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// kopf
	this.instance = new lib.auge();
	this.instance.parent = this;
	this.instance.setTransform(18.1,-12.4,1.251,1.251,0,0,180);

	this.instance_1 = new lib.auge();
	this.instance_1.parent = this;
	this.instance_1.setTransform(-18,-12.4,1.251,1.251);

	this.instance_2 = new lib.nasenloch("synched",0);
	this.instance_2.parent = this;
	this.instance_2.setTransform(-6.3,3.5,0.926,0.926,-30);

	this.instance_3 = new lib.nasenloch("synched",0);
	this.instance_3.parent = this;
	this.instance_3.setTransform(5.2,2.5,0.926,0.926,30);

	this.shape = new cjs.Shape();
	this.shape.graphics.f().s("#000000").ss(1,0,0,42).p("AiJiqQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfQgEANgFAMQgTAtgoAcQglAZgrAOQgrAPgtAFQguAFgugHQgwgFgvgTQgtgQgkgiQgigggQgrQgBgDgBgDQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAQAEAAAEgBg");
	this.shape.setTransform(0,-7.3);

	this.shape_1 = new cjs.Shape();
	this.shape_1.graphics.rf(["#0CBFBF","#000000","#2F1038"],[0,0.784,0.914],-0.7,-1.8,0,-0.7,-1.8,33.9).s().p("AgzCzQgwgFgvgTQgtgQgkgiQgigggQgrIgCgGQgNgmgDgqQgCgrANgqQAJgfAhgDQAxAGAwAAIAIgBQAsgHAsgDQAsgDArACQAtADArAKQAvALAzgIQAJgCAKABQAgAEALAgQAPArgIAuQgFAigLAfIgJAZQgTAtgoAcQglAZgrAOQgrAPgtAFQgTACgTAAQgbAAgbgEg");
	this.shape_1.setTransform(0,-7.3);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_1},{t:this.shape},{t:this.instance_3},{t:this.instance_2},{t:this.instance_1},{t:this.instance}]}).wait(1));

	// Ebene 5
	this.instance_4 = new lib.kugel();
	this.instance_4.parent = this;
	this.instance_4.setTransform(59.9,-71.7,1,1,0,0,180);

	this.instance_5 = new lib.kugel();
	this.instance_5.parent = this;
	this.instance_5.setTransform(-55.2,-71.7);

	this.shape_2 = new cjs.Shape();
	this.shape_2.graphics.f().s("#666666").ss(1,0,0,42).p("ABtEEQgbiZB4iRQB7iUDahFAhsEEQAbiZh4iRQh7iUjahF");
	this.shape_2.setTransform(2.3,-44.9);

	this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_2},{t:this.instance_5},{t:this.instance_4}]}).wait(1));

	// maul
	this.instance_6 = new lib.unterkiefer();
	this.instance_6.parent = this;
	this.instance_6.setTransform(0,9.9);

	this.timeline.addTween(cjs.Tween.get(this.instance_6).wait(1));

}).prototype = getMCSymbolPrototype(lib.SnakeHead, new cjs.Rectangle(-59.1,-75.5,122.8,101.9), null);


// stage content:
(lib.snake = function(mode,startPosition,loop) {
	this.initialize(mode,startPosition,loop,{});

	// timeline functions:
	this.frame_0 = function() {
		var anzahl = 30;
		var abstand = 15;
		var ball = new Object();
		ball[0] = new lib.SnakeHead();
		ball[0].x = 500;
		ball[0].y = 50;
		this.addChild(ball[0]);
		
		
		
		for(i = 1; i < anzahl; i++)
			{
				ball[i] = new lib.Ball();
				ball[i].x = ball[i-1].x - abstand;
				ball[i].y = 50;
				ball[i].scaleX = 1 - i / anzahl;
				ball[i].scaleY =  1 - i / anzahl;
				ball[i].gotoAndPlay(i);
				this.addChild(ball[i]);
			}
		//die zweite Schleife dient dazu die Stapelreihenfolge umzukehren
		for(i = anzahl; i >= 0; i--)
			{
				this.addChild(ball[i]);
			}
			
		this.addEventListener("tick",mover.bind(this));
			
		function mover() 
		{
			 
			var p = this.globalToLocal(this.stage.mouseX, this.stage.mouseY);
			ball[0].x = ball[0].x + (p.x - ball[0].x) / 15;
			 ball[0].y = ball[0].y + (p.y - ball[0].y) / 15;
			
			   for (i = 1; i < anzahl; i++)
		    {
		        //horizontaler Abstand zum vorigen Element,
		         distX = ball[i - 1].x - ball[i].x;
		        //vertikaler Abstand zum vorigen Element
		         distY = ball[i - 1].y - ball[i].y;
		        //Abstand zum vorigen Element (Satz des Pythagoras a² * b² = c²)
		         dist = Math.sqrt(distX * distX + distY * distY);
		        //Verhältnis horizontaler Abstand zum wirklichen Abstand
				
		         cx = distX / dist; 
		         cy = distY / dist;
		        //der gewünschte Abstand ist "abstand", der momentane Abstand ist "dist"
		        //Das Verhältnis horizontaler Abstand zu momenten Abstand ist "cx"
		        //Nun kann man anhand des Verhältnis cx den gewünschten X-Abstand ausrechnen
		         distX_new = cx * (abstand/(i*0.7)+5);
		        //auf gleiche Weise wird auch der gewünschte Y-Abstand errechnet
		         distY_new = cy * (abstand / ( i* 0.7)+5);
		        //Die neue Position wird gesetzt, der errechnete Abstand wird von der Position
		        //des vorigen Elementes abgezogen
				ball[i].x = ball[i - 1].x - distX_new;
		        ball[i].y = ball[i - 1].y - distY_new;
		      
		    }
			
		}
	}

	// actions tween:
	this.timeline.addTween(cjs.Tween.get(this).call(this.frame_0).wait(1));

}).prototype = p = new cjs.MovieClip();
p.nominalBounds = null;
// library properties:
lib.properties = {
	id: 'A159DC6E08C1F34A8C922AA70F875570',
	width: 800,
	height: 800,
	fps: 24,
	color: "#000000",
	opacity: 1.00,
	webfonts: {},
	manifest: [],
	preloads: []
};



// bootstrap callback support:

(lib.Stage = function(canvas) {
	createjs.Stage.call(this, canvas);
}).prototype = p = new createjs.Stage();

p.setAutoPlay = function(autoPlay) {
	this.tickEnabled = autoPlay;
}
p.play = function() { this.tickEnabled = true; this.getChildAt(0).gotoAndPlay(this.getTimelinePosition()) }
p.stop = function(ms) { if(ms) this.seek(ms); this.tickEnabled = false; }
p.seek = function(ms) { this.tickEnabled = true; this.getChildAt(0).gotoAndStop(lib.properties.fps * ms / 1000); }
p.getDuration = function() { return this.getChildAt(0).totalFrames / lib.properties.fps * 1000; }

p.getTimelinePosition = function() { return this.getChildAt(0).currentFrame / lib.properties.fps * 1000; }

an.bootcompsLoaded = an.bootcompsLoaded || [];
if(!an.bootstrapListeners) {
	an.bootstrapListeners=[];
}

an.bootstrapCallback=function(fnCallback) {
	an.bootstrapListeners.push(fnCallback);
	if(an.bootcompsLoaded.length > 0) {
		for(var i=0; i<an.bootcompsLoaded.length; ++i) {
			fnCallback(an.bootcompsLoaded[i]);
		}
	}
};

an.compositions = an.compositions || {};
an.compositions['A159DC6E08C1F34A8C922AA70F875570'] = {
	getStage: function() { return exportRoot.getStage(); },
	getLibrary: function() { return lib; },
	getSpriteSheet: function() { return ss; },
	getImages: function() { return img; }
};

an.compositionLoaded = function(id) {
	an.bootcompsLoaded.push(id);
	for(var j=0; j<an.bootstrapListeners.length; j++) {
		an.bootstrapListeners[j](id);
	}
}

an.getComposition = function(id) {
	return an.compositions[id];
}



})(createjs = createjs||{}, AdobeAn = AdobeAn||{});
var createjs, AdobeAn;
  </script>
<script>
var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation;
function init() {
	canvas = document.getElementById("canvas");
	anim_container = document.getElementById("animation_container");
	dom_overlay_container = document.getElementById("dom_overlay_container");
	var comp=AdobeAn.getComposition("A159DC6E08C1F34A8C922AA70F875570");
	var lib=comp.getLibrary();
	handleComplete({},comp);
}
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();
	var preloaderDiv = document.getElementById("_preload_div_");
	preloaderDiv.style.display = 'none';
	canvas.style.display = 'block';
	exportRoot = new lib.snake();
	stage = new lib.Stage(canvas);
	stage.addChild(exportRoot);	
 
	fnStartAnimation = function() {
		createjs.Ticker.setFPS(lib.properties.fps);
		createjs.Ticker.addEventListener("tick", stage);
	}	    
	//Code to support hidpi screens and responsive scaling.
	function makeResponsive(isResp, respDim, isScale, scaleType) {		
		var lastW, lastH, lastS=1;		
		window.addEventListener('resize', resizeCanvas);		
		resizeCanvas();		
		function resizeCanvas() {			
			var w = lib.properties.width, h = lib.properties.height;			
			var iw = window.innerWidth, ih=window.innerHeight;			
			var pRatio = window.devicePixelRatio || 1, xRatio=iw/w, yRatio=ih/h, sRatio=1;			
			if(isResp) {                
				if((respDim=='width'&&lastW==iw) || (respDim=='height'&&lastH==ih)) {                    
					sRatio = lastS;                
				}				
				else if(!isScale) {					
					if(iw<w || ih<h)						
						sRatio = Math.min(xRatio, yRatio);				
				}				
				else if(scaleType==1) {					
					sRatio = Math.min(xRatio, yRatio);				
				}				
				else if(scaleType==2) {					
					sRatio = Math.max(xRatio, yRatio);				
				}			
			}			
			canvas.width = w*pRatio*sRatio;			
			canvas.height = h*pRatio*sRatio;
			canvas.style.width = anim_container.style.width = dom_overlay_container.style.width = preloaderDiv.style.width = w*sRatio+'px';				
			canvas.style.height = anim_container.style.height = dom_overlay_container.style.height = preloaderDiv.style.height = h*sRatio+'px';
			stage.scaleX = pRatio*sRatio;			
			stage.scaleY = pRatio*sRatio;			
			lastW = iw; lastH = ih; lastS = sRatio;		
		}
	}
	makeResponsive(true,'both',true,1);	
	AdobeAn.compositionLoaded(lib.properties.id);
	fnStartAnimation();
}
</script>
<!-- write your code here -->
</head>
<body onload="init();" style="margin:0px;">
	<div id="animation_container" style="background-color:rgba(0, 0, 0, 1.00); width:800px; height:800px">
		<canvas id="canvas" width="800" height="800" style="position: absolute; display: none; background-color:rgba(0, 0, 0, 1.00);"></canvas>
		<div id="dom_overlay_container" style="pointer-events:none; overflow:hidden; width:800px; height:800px; position: absolute; left: 0px; top: 0px; display: none;">
		</div>
	</div>
    <div id='_preload_div_' style='display: inline-block; height:800px; width: 800px; vertical-align=middle;position:absolute;left:0px;top:0px;text-align: center;'>	<span style='display: inline-block; height: 100%; vertical-align: middle;'></span>	<img src=https://on-design.de/html5/snake/images/_preloader.gif style='vertical-align: middle; max-height: 100%'/></div>
</body>
</html>

vConsole
09:27:06
Uncaught TypeError: Cannot read properties of null (reading 'style')
/Kurze-Scripte-und-Codeschnipsel/index.php?name=mausverfolger.php&ordner=Kurze-Scripte-und-Codeschnipsel:2751:53
09:27:09
500
09:27:06
WeChatLib: 0 (xxxx.xx.xx)
09:27:09
System: Unknown
09:27:09
Protocol: HTTPS
09:27:09
UA: Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
09:27:09
navigationStart: 1744018018783
09:27:09
navigation: 5ms
09:27:09
dns: 117ms
09:27:09
tcp (ssl): 409ms (300ms)
09:27:09
request: 7281ms
09:27:09
response: 282ms
09:27:09
domComplete (domLoaded): 2810ms (2341ms)
09:27:09
loadEvent: 39ms
09:27:09
total (DOM): 10664ms (10625ms)