program chickenwings;
{$MODE OBJFPC}{$H+}
uses
Graph;
procedure Toxi(XPos, YPos: Word);
const
h = 100;
w = 100;
var
Hx, Hy : smallInt;
Fx, Fy : smallint;
LW : Array of PointType;
RW : Array of PointType;
Bk : Array of PointType;
begin
Hx := Xpos + w div 2;
Hy := Ypos + h div 2;
Fx := Hx;
Fy := Hy + 40;
SetLength(LW, 3);
LW[0].x := Hx; LW[0].y := Hy - 40;
LW[1].x := Hx - 70; LW[1].y := Hy + 15;
LW[2].x := Hx; LW[2].y := hy + 40;
SetLength(RW, 3);
RW[0].x := Hx; RW[0].y := hy - 40;
RW[1].x := Hx + 70; RW[1].y := Hy + 10;
RW[2].x := Hx; RW[2].y := hy + 50;
Setlength(Bk, 3);
Bk[0].x := Hx; Bk[0].y := hy + 25;
Bk[1].x := Hx - 17; Bk[1].y := Hy - 5 + 2;
Bk[2].x := Hx + 17; Bk[2].y := Hy - 5 - 2;
// feet
setColor(yellow);
setBkColor(yellow);
setfillstyle(1, yellow);
FillEllipse(Fx - 20, Fy, w div 5, h div 6);
FillEllipse(Fx + 20, Fy, w div 5, h div 6);
// body
setColor(black);
setBkColor(black);
setfillstyle(1, black);
FillEllipse(Hx, Hy, w div 2, h div 2);
// wings
setColor(black);
setBkColor(black);
setfillstyle(1, black);
FillPoly(Length(LW), LW[0]);
FillPoly(Length(RW), RW[0]);
// belly
setColor(white);
setBkColor(white);
setfillstyle(1, white);
FillEllipse(Hx, Hy + 30, w div 4, h div 7);
// face
setColor(darkgray);
setBkColor(darkGray);
setfillstyle(1, Darkgray);
FillEllipse(Hx, Hy - 20, w div 3, h div 4);
// eyes
setColor(white);
setBkColor(white);
setfillstyle(1, white);
FillEllipse(Hx - 10, Hy - 20, w div 8, h div 8);
FillEllipse(Hx + 15, Hy - 20, w div 10, h div 10);
// pupils
setColor(black);
setBkColor(black);
setfillstyle(1, black);
FillEllipse(Hx - 10 + 4, Hy - 20 + 3, w div 15, h div 15);
FillEllipse(Hx + 15 - 3, Hy - 17 + 1, w div 18, h div 18);
// beak
setColor(yellow);
setBkColor(yellow);
setfillstyle(1, yellow);
FillPoly(Length(Bk), Bk[0]);
end;
var
draiveris,x,y,r, tips: SmallInt;
begin
Draiveris:=detect;
initgraph(draiveris,tips,' ');
writeln(GetMaxX,' ',GetMaxY);
SetBkColor(white);
ClearDevice;
Toxi(100,100);
readln;
closegraph;
end.