[原创]想玩吗?别错过
#include<graphics.h>#include<alloc.h>
main()
{
int i=1,j=1,k,m=0,a=1;
int graphdriver=DETECT,graphmode;
unsigned s;
void *buf;
initgraph(&graphdriver,&graphmode,"");
cleardevice();
setactivepage(0);
setvisualpage(0);
do
{
a++;
setfillstyle(1,4);
rectangle(0,0,634,475);
setcolor(14);
line(60,340,0,360);
line(100,340,0,400);
line(180,340,30,480);
line(220,340,100,480);
line(240,380,180,480);
line(286,380,260,480);
line(344,380,360,480);
line(400,380,440,480);
line(448,380,520,480);
line(500,380,590,480);
line(500,340,640,450);
line(540,340,640,400);
line(680,340,640,360);
line(30,350,240,350);
line(500,350,610,350);
line(0,370,240,370);
line(500,370,640,370);
line(0,400,640,400);
line(0,434,640,434);
settextstyle(4,1,5);
settextstyle(3,0,4);
outtextxy(10,440,"* * * * ** * *");
outtextxy(20,400,"* * * * * * * *");
outtextxy(15,370,"* * * * * * * *");
outtextxy(20,345,"* * * * * * * *");
s=imagesize(60,20,140,140);
buf=malloc(s);
setcolor(a);
ellipse(100,80,0,360,40,30);
ellipse(100,80,0,360,30,30);
arc(90,80,280,80,30);
arc(110,80,105,260,30);
arc(120,80,110,250, 30);
arc(80,80,290,70,30);
ellipse(100,110,0,360,10,5);
arc(100,50,355,185,10);
line(100,20,100,40);
line(110,110,110,140);
line(90,110,90,140);
line(90,110,90,140);
line(100,105,100,135);
line(100,5,100,25);
getimage(60,20,140,140,buf);
for(k=20;k<480;k+=120)
putimage(60,k,buf,COPY_PUT);
free(buf);
moveto(240,120);
lineto(280,120);
lineto(280,100);
lineto(320,100);
lineto(320,120);
lineto(420,120);
lineto(420,100);
lineto(460,100);
lineto(460,120);
lineto(500,120);
lineto(500,140);
lineto(460,140);
lineto(460,160);
lineto(500,160);
lineto(500,180);
lineto(240,180);
lineto(240,160);
lineto(280,160);
lineto(280,140);
lineto(240,140);
lineto(240,120);
lineto(280,160);
lineto(280,140);
lineto(240,140);
lineto(240,120);
moveto(240,200);
lineto(360,200);
lineto(360,260);
lineto(320,260);
lineto(320,280);
lineto(420,280);
lineto(420,260);
lineto(380,260);
lineto(280,200);
lineto(500,200);
lineto(500,260);
lineto(460,260);
lineto(460,280);
lineto(500,280);
lineto(500,300);
lineto(460,300);
lineto(460,320);
lineto(500,320);
lineto(500,380);
lineto(380,380);
lineto(380,320);
lineto(420,320);
lineto(420,300);
lineto(320,300);
lineto(320,320);
lineto(360,320);
lineto(360,380);
lineto(240,380);
lineto(240,320);
lineto(280,320);
lineto(280,300);
lineto(240,300);
lineto(240,280);
lineto(280,280);
lineto(280,260);
lineto(240,260);
lineto(240,200);
moveto(320,140);
lineto(420,140);
lineto(420,160);
lineto(320,160);
lineto(320,140);
moveto(260,220);
lineto(340,220);
lineto(340,240);
lineto(260,240);
lineto(260,220);
moveto(400,220);
lineto(480,220);
lineto(480,240);
lineto(400,240);
lineto(400,220);
moveto(260,340);
lineto(340,340);
lineto(260,260);
lineto(260,340);
moveto(400,340);
lineto(480,340);
lineto(480,360);
lineto(400,360);
lineto(400,340);
/*setfillstyle(1,14);
floodfill(440,290,14);
floodfill(244,360,14);
floodfill(300,140,14); */
do
{
j++;
for(m=0;m<4;m++)
{
i++;
setcolor(i);
ellipse(370,240,315+m,225-m,185+m*5,185+m*5);
}
}while(j<50);
}while(a<50);
getch();
closegraph();
}