//#include<stdafx.h>
#include<graphics.h>
#include<stdio.h>
#include<math.h>
#include<conio.h>
#define x0 300
#define h 100
#define y0 200
#define b 50
#define R 50
COLORREF backcolor=RGB(255,192,203);
COLORREF car_color=RGB(153,53,0);
COLORREF wheel_color=RGB(0,0,255);
void drawcar()
{
setcolor(car_color); //set the color of pen
moveto(x0-h,y0-h);
lineto(x0-h-b,y0);
lineto(x0-2*h,y0);
lineto(x0-2*h-b,y0);
lineto(x0-2*h-b,y0+h);
lineto(x0+2*h+b,y0+h);
lineto(x0+2*h+b,y0);
lineto(x0+h+b,y0);
lineto(x0+h,y0-h);
lineto(x0-h,y0-h);
}
void drawwheel()
{
本内容试读结束,登录后可阅读更多
下载后可阅读完整内容,剩余3页未读,立即下载