效果:
详细代码:
[SWF(backgroundColor=0x004890,width=550,height=400)]
var denglong:MovieClip =new MovieClip();
addChild(denglong);
denglong.x=275;
denglong.y=0;
denglong.rotation=5;
var rota:Number=0;
denglong.addEventListener(Event.ENTER_FRAME ,frame);
function frame(e) {
var xs:Number=(0-denglong.rotation)*0.01;
rota+=xs;
denglong.rotation+=rota;
}
var diaoxian:Shape =new Shape();
denglong.addChild(diaoxian);
diaoxian.graphics.lineStyle(6, 0xcc6600);
diaoxian.graphics.moveTo(0,0);
diaoxian.graphics.lineTo(0,50);
function Rect():Sprite {
var sp:Sprite =new Sprite();
sp.graphics.beginGradientFill("linear" ,[0xffbe17,0xf8fd97,0xffbe17],[1,1,1],[0,128,255]);
sp.graphics.drawRoundRect(-50,-10,100,20,15,13);
var mc:Shape=new Shape();
sp.addChild(mc);
mc.graphics.lineStyle(1.5,0x996633,1);
mc.graphics.drawRoundRect(-48,-9,96,18,13,12);
return sp;
}
for (var c:int=0; c<4; c++) {
var rect:Sprite=Rect();
denglong.addChild(rect);
c%2==0?[rect.scaleX=rect.scaleY=0.7,rect.y=50+c*107]:rect.y=c*90-23;
}
function Huxian(n:int):Shape {
var hu:Shape=new Shape();
hu.graphics.beginFill(0xffbe17,1);
hu.graphics.moveTo(0,0);
hu.graphics.curveTo(n,80,0,160);
hu.graphics.curveTo(n+5,80,0,0);
return hu;
}
var ellip:Sprite=new Sprite();
denglong.addChildAt(ellip,0);
ellip.y=158;
ellip.graphics.beginGradientFill("radial" ,[0xfea408,0xe20708],[1,1],[0,255]);
ellip.graphics.drawEllipse(-120,-85,240,170);
for (var d:int=0; d<4; d++) {
var n:int;
var huxian:Shape=Huxian(d%4==0?n=-80:d%4==1?n=-60:d%4==2?n=60:d%4==3?n=80:0);
ellip.addChild(huxian);
huxian.x=-45+d*30;
huxian.y=-80;
}
function line():Sprite {
var sp:Sprite =new Sprite();
sp.graphics.lineStyle(0.5,0xffff00,1);
sp.graphics.moveTo(0,0);
sp.graphics.lineTo(0,60);
return sp;
}
for (var a:int=0; a<15; a++) {
var mc:Sprite=line();
denglong.addChild(mc);
mc.x=a*4-28;
mc.y=270;
}
Word教程网 | Excel教程网 | Dreamweaver教程网 | Fireworks教程网 | PPT教程网 | FLASH教程网 | PS教程网 |
HTML教程网 | DIV CSS教程网 | FLASH AS教程网 | ACCESS教程网 | SQL SERVER教程网 | C语言教程网 | JAVASCRIPT教程网 |
ASP教程网 | ASP.NET教程网 | CorelDraw教程网 |