• Добрый день,помогите с паскалем
    Нужно размножить снежинку и чтобы она появлялась в рандомных местах
    Uses GraphABC;
    var y, i, x: integer;
    begin
    moveto(0,320);
    lineto(2000,320);
    Line(120,100,80,140);
    Line(120,100,160,140);
    Line(120,160,80,200);
    Line(120,160,160,200);
    Line(120,220,80,260);
    Line(120,220,160,260);
    Line(120,100,120,320);


    Rectangle(260,180,400,320);
    Line(260,180,340,100);
    line(340,100,400,180);
    Rectangle(300,220,340,260);
    Line(300,240,340,240);
    line(320,220,320,260);
    Rectangle(300,280,340,320);








    for i := 1 to 10 do begin
    x := random (1024);
    y := random (200);





    line(440,60,480,100);
    line(440,80,480,80);
    line(480,60,440,100);
    Line(460,60,460,100);

    Rectangle(460,200,500,320);
    Line(460,220,500,220);
    Line(460,240,500,240);
    Line(460,260,500,260);
    Line(460,280,500,280);
    Line(460,300,500,300);
    Line(500,200,560,200);
    line(560,200,640,320);
    line(500,320,640,320);

    Circle(760,280,40);
    Circle(760,220,20);
    Circle(760,190,10);


    Line(500,120,540,120);
    line(600,20,600,60);
    Line(600,180,600,220);
    Line(660,120,700,120);
    Circle(600,120,40);

    FloodFill(140,440,clSkyBlue);
    FloodFill(160,380,clSkyBlue);
    FloodFill(160,350,clSkyBlue);
    FloodFill(320,200,clGray);
    FloodFill(310,230,clYellow);
    FloodFill(330,230,clYellow);
    FloodFill(310,250,clYellow);
    FloodFill(330,250,clYellow);
    FloodFill(302,20,clSilver);
    FloodFill(600,140,clYellow);
    FloodFill(320,300,clBrown);
    FloodFill(320,160,clRed);
    FloodFill(540,250,clTeal);
    FloodFill(480,210,clMaroon);
    FloodFill(480,230,clMaroon);
    FloodFill(480,250,clMaroon);
    FloodFill(480,270,clMaroon);
    FloodFill(480,290,clMaroon);
    FloodFill(480,310,clMaroon);


    end;
    end.

Ответы 1

  • Uses GraphABC;var y, i, x, j, x1, y1: integer;beginmoveto(0,320);lineto(2000,320);Line(120,100,80,140);Line(120,100,160,140);Line(120,160,80,200);Line(120,160,160,200);Line(120,220,80,260);Line(120,220,160,260);Line(120,100,120,320);Rectangle(260,180,400,320);Line(260,180,340,100);line(340,100,400,180);Rectangle(300,220,340,260);Line(300,240,340,240);line(320,220,320,260);Rectangle(300,280,340,320);for i := 1 to 10 do beginx := random (1024);y := random (200);for j:=1 to 3 dobeginx1:=random(800);y1:=random(100);line(x1,y1,x1+40,y1+40);line(x1,y1+20,x1+40,y1+20);line(x1+40,y1,x1,y1+40);Line(x1+20,y1,x1+20,y1+40);end;Rectangle(460,200,500,320);Line(460,220,500,220);Line(460,240,500,240);Line(460,260,500,260);Line(460,280,500,280);Line(460,300,500,300);Line(500,200,560,200);line(560,200,640,320);line(500,320,640,320);Circle(760,280,40);Circle(760,220,20);Circle(760,190,10);Line(500,120,540,120);line(600,20,600,60);Line(600,180,600,220);Line(660,120,700,120);Circle(600,120,40);FloodFill(140,440,clSkyBlue);FloodFill(160,380,clSkyBlue);FloodFill(160,350,clSkyBlue);FloodFill(320,200,clGray);FloodFill(310,230,clYellow);FloodFill(330,230,clYellow);FloodFill(310,250,clYellow);FloodFill(330,250,clYellow);FloodFill(302,20,clSilver);FloodFill(600,140,clYellow);FloodFill(320,300,clBrown);FloodFill(320,160,clRed);FloodFill(540,250,clTeal);FloodFill(480,210,clMaroon);FloodFill(480,230,clMaroon);FloodFill(480,250,clMaroon);FloodFill(480,270,clMaroon);FloodFill(480,290,clMaroon);FloodFill(480,310,clMaroon);end;end.
    • Автор:

      elisek0f1
    • 6 лет назад
    • 0
  • Добавить свой ответ

Войти через Google

или

Забыли пароль?

У меня нет аккаунта, я хочу Зарегистрироваться

How much to ban the user?
1 hour 1 day 100 years