Gifu/rensyuu
From 2014.igem.org
(Difference between revisions)
Line 99: | Line 99: | ||
}; | }; | ||
+ | function spinleft(){ | ||
+ | BBB=setINterval(function(){ | ||
+ | if(rad==0){rad=360;} | ||
+ | else{rad-=2}; | ||
+ | x=r*Math.cos(Math.PI/180*rad); | ||
+ | y=r*Math.sin(Math.PI/180*rad); | ||
+ | circle.style.top=y+180+"px"; | ||
+ | circle.style.left=x+390+"px"; | ||
+ | |||
+ | k-=2; | ||
+ | if(rad==0){k=90}; | ||
+ | circle.style.transform="rotate("+k+"deg)"; | ||
+ | },7); | ||
+ | }; | ||
$(document).ready(function () { | $(document).ready(function () { | ||
- | + | spinleft() | |
}); | }); | ||
Revision as of 07:43, 5 September 2015