|
马上注册,结交更多好友,享用更多功能^_^
您需要 登录 才可以下载或查看,没有账号?立即注册
x
本帖最后由 soldier 于 2011-4-23 10:05 编辑
#include "graphics.h"
#include "stdio.h"
#include "stdlib.h"
#include "conio.h"
#include <dos.h>
void main()
{
void *w;
int i,b;
int driver=DETECT,gmode;
initgraph(&driver,&gmode," ");
cleardevice();
setbkcolor(9);
setcolor(1);
rectangle(500,200,560,202);\*顶部矩形*\
rectangle(500,202,560,220);\*中间矩形*\
rectangle(500,202,520,220);
rectangle(520,202,540,220);
rectangle(540,202,560,220);\*中间小矩形*\
line(500,200,480,220);
rectangle(480,220,560,250);\*下面的大矩形*\
circle(510,250,5);
circle(540,250,5);\*轮子*\
line((501,221,503,221);
line(503,221,503,223);
line(503,223,505,223);
line(505,223,505,225);
line(505,225,503,225);
line(503,225,503,227);
line(503,227,501,227);
line(501,227,501,225);
line(501,225,501,223);
line(501,223,409,223);
line(409,223,409,221);
line(409,221,501,221);\*十字架*\
rectangle(510,198,514,200);
arc(512,198,0,180,2);\*警灯*\
line(510,196,510,192);
line(505,197,502,193);
line(515,197,518,193);
w= malloc(imagesize(490,190,600,300));
getimage(490,190,600,300,w);
for(i=490;i>0;i--)
{
putimage(i-1,190,w,COPY_PUT);
line(2,250,630,250);
delay(20);
}
getch();
closegraph();
}
出现以下错误:
car1.c
E:\work1\car1.c(16) : error C2017: illegal escape sequence
E:\work1\car1.c(16) : error C2018: unknown character '0xb6'
E:\work1\car1.c(16) : error C2018: unknown character '0xa5'
E:\work1\car1.c(16) : error C2018: unknown character '0xb2'
E:\work1\car1.c(16) : error C2018: unknown character '0xbf'
E:\work1\car1.c(16) : error C2018: unknown character '0xbe'
E:\work1\car1.c(16) : error C2018: unknown character '0xd8'
E:\work1\car1.c(16) : error C2018: unknown character '0xd0'
E:\work1\car1.c(16) : error C2018: unknown character '0xce'
E:\work1\car1.c(16) : error C2017: illegal escape sequence
E:\work1\car1.c(17) : error C2100: illegal indirection
E:\work1\car1.c(17) : error C2100: illegal indirection
E:\work1\car1.c(17) : error C2017: illegal escape sequence
E:\work1\car1.c(17) : error C2018: unknown character '0xd6'
E:\work1\car1.c(17) : error C2018: unknown character '0xd0'
E:\work1\car1.c(17) : error C2018: unknown character '0xbc'
E:\work1\car1.c(17) : error C2018: unknown character '0xe4'
E:\work1\car1.c(17) : error C2018: unknown character '0xbe'
E:\work1\car1.c(17) : error C2018: unknown character '0xd8'
E:\work1\car1.c(17) : error C2018: unknown character '0xd0'
E:\work1\car1.c(17) : error C2018: unknown character '0xce'
E:\work1\car1.c(18) : error C2100: illegal indirection
E:\work1\car1.c(18) : error C2100: illegal indirection
E:\work1\car1.c(20) : error C2017: illegal escape sequence
E:\work1\car1.c(20) : error C2018: unknown character '0xd6'
E:\work1\car1.c(20) : error C2018: unknown character '0xd0'
E:\work1\car1.c(20) : error C2018: unknown character '0xbc'
E:\work1\car1.c(20) : error C2018: unknown character '0xe4'
E:\work1\car1.c(20) : error C2018: unknown character '0xd0'
E:\work1\car1.c(20) : error C2018: unknown character '0xa1'
E:\work1\car1.c(20) : error C2018: unknown character '0xbe'
E:\work1\car1.c(20) : error C2018: unknown character '0xd8'
E:\work1\car1.c(20) : error C2018: unknown character '0xd0'
E:\work1\car1.c(20) : error C2018: unknown character '0xce'
E:\work1\car1.c(21) : error C2100: illegal indirection
E:\work1\car1.c(21) : error C2100: illegal indirection
E:\work1\car1.c(22) : error C2017: illegal escape sequence
E:\work1\car1.c(22) : error C2018: unknown character '0xcf'
E:\work1\car1.c(22) : error C2018: unknown character '0xc2'
E:\work1\car1.c(22) : error C2018: unknown character '0xc3'
E:\work1\car1.c(22) : error C2018: unknown character '0xe6'
E:\work1\car1.c(22) : error C2018: unknown character '0xb5'
E:\work1\car1.c(22) : error C2018: unknown character '0xc4'
E:\work1\car1.c(22) : error C2018: unknown character '0xb4'
E:\work1\car1.c(22) : error C2018: unknown character '0xf3'
E:\work1\car1.c(22) : error C2018: unknown character '0xbe'
E:\work1\car1.c(22) : error C2018: unknown character '0xd8'
E:\work1\car1.c(22) : error C2018: unknown character '0xd0'
E:\work1\car1.c(22) : error C2018: unknown character '0xce'
E:\work1\car1.c(23) : error C2100: illegal indirection
E:\work1\car1.c(23) : error C2100: illegal indirection
E:\work1\car1.c(24) : error C2017: illegal escape sequence
E:\work1\car1.c(24) : error C2018: unknown character '0xc2'
E:\work1\car1.c(24) : error C2018: unknown character '0xd6'
E:\work1\car1.c(24) : error C2018: unknown character '0xd7'
E:\work1\car1.c(24) : error C2018: unknown character '0xd3'
E:\work1\car1.c(25) : error C2143: syntax error : missing ')' before ';'
E:\work1\car1.c(25) : error C2198: 'line' : too few actual parameters
E:\work1\car1.c(25) : error C2100: illegal indirection
E:\work1\car1.c(25) : error C2100: illegal indirection
E:\work1\car1.c(36) : error C2017: illegal escape sequence
E:\work1\car1.c(36) : error C2018: unknown character '0xca'
E:\work1\car1.c(36) : error C2018: unknown character '0xae'
E:\work1\car1.c(36) : error C2018: unknown character '0xd7'
E:\work1\car1.c(36) : error C2018: unknown character '0xd6'
E:\work1\car1.c(36) : error C2018: unknown character '0xbc'
E:\work1\car1.c(36) : error C2018: unknown character '0xdc'
E:\work1\car1.c(37) : error C2100: illegal indirection
E:\work1\car1.c(37) : error C2100: illegal indirection
E:\work1\car1.c(38) : error C2017: illegal escape sequence
E:\work1\car1.c(38) : error C2018: unknown character '0xbe'
E:\work1\car1.c(38) : error C2018: unknown character '0xaf'
E:\work1\car1.c(38) : error C2018: unknown character '0xb5'
E:\work1\car1.c(38) : error C2018: unknown character '0xc6'
E:\work1\car1.c(39) : error C2100: illegal indirection
E:\work1\car1.c(39) : error C2100: illegal indirection
执行 cl.exe 时出错.
car1.obj - 1 error(s), 0 warning(s) |
|